JAVA/CORBA クラス
例:getEnvironmentString メソッド
1. 次のアプリケーションは、$EnvLoc 環境変数の値を取得します。
import lotus.domino.*;
class getenvstring extends NotesThread
{
public static void main(String argv[])
{
getenvstring t = new getenvstring();
t.start();
}
public void runNotes()
{
try
{
Session s = NotesFactory.createSession();
String envloc = s.getEnvironmentString("EnvLoc",
false);
if (envloc == null)
System.out.println("No $EnvLoc");
else
System.out.println("$EnvLoc = " + envloc);
}
catch (Exception e)
{
e.printStackTrace();
}
}
}
2. 次のアプリケーションは、MailServer システム環境変数の値を取得します。
import lotus.domino.*;
class getenvstring2 extends NotesThread
{
public static void main(String argv[])
{
getenvstring2 t = new getenvstring2();
t.start();
}
public void runNotes()
{
try
{
Session s = NotesFactory.createSession();
String ms = s.getEnvironmentString("MailServer",
true);
if (ms == null)
System.out.println("No MailServer");
else
System.out.println("MailServer = " + ms);
}
catch (Exception e)
{
e.printStackTrace();
}
}
}
関連項目
getEnvironmentString メソッド
用語集
フィードバック
ヘルプ
または
プロダクトユーザビリティ
ヘルプの使い方
すべてのヘルプ項目
用語集