JAVA/CORBA クラス


例:addUserProfile メソッド
次のエージェントは、セットアッププロフィール「Ordinary User」を Annette LeBlanc のユーザー文書に追加します。

import lotus.domino.*;

public class JavaAgent extends AgentBase {

 public void NotesMain() {

   try {
     Session session = getSession();
     AgentContext agentContext = session.getAgentContext();

     // (Your code goes here)
     Registration reg = session.createRegistration();
     reg.setRegistrationServer("AceOne");
     reg.addUserProfile(
       "Annette LeBlanc", // user name
       "Ordinary User"); // profile name

   } catch(NotesException e) {
     System.out.println(e.id + " " + e.text);
     e.printStackTrace();
   }
 }
}

関連項目