JAVA/CORBA クラス


例:getURLHeaderInfo メソッド
次のエージェントは、エージェントコメントで指定された URL の「Last-modified」ヘッダー文字列を取得します。

import lotus.domino.*;
public class JavaAgent extends AgentBase {
 public void NotesMain() {
   try {
     Session session = getSession();
     AgentContext agentContext =
         session.getAgentContext();
     // (Your code goes here)
     Database db = agentContext.getCurrentDatabase();
     String hinfo = db.getURLHeaderInfo
       ("http://www.lotus.com",
        "Last-modified", null, null, null, null);
     System.out.println
       ("www.lotus.com was last modified on " + hinfo);
   } catch(Exception e) {
     e.printStackTrace();
   }
 }
}

関連項目