Sun N1 Service Provisioning System 5.2 プラグイン開発ガイド

始める前に

コマンド行 API を使用するには、CommandManagerBuilder から CommandManager を取得する必要があります。次のコード例に、CommandManager を取得する方法を示します。

public class CommandManagerBuilder {

  /**
    *  Set the directory for the CLI installation directory
    */
    public setHomeDirectory(File cliHomeDir){ ... }

  /**
    *  Build a command manager with the properties set in this class
    *  @throws ConfigurationException incorrect properties 
    *  specified for a valid CommandManager
    */
    public CommandManager build() throws ConfigurationException {...}

}

注 –

構築メソッドの呼び出しは、負荷が大きい処理です。したがって、コマンドを実行する CommandManager は 1 つだけ作成するようにします。