30日間の無料評価版をお試しいただけます。

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

Anchor
top
top

 

コンバータープラグインにユーザー固有設定や構成を含めるためには、構成UIを提供しなくてはいけません。これは、「UserInputParameters API」を通して実行されます。コンバーター抽象classはUserInputParametersも拡張するため、このAPIをUserInputParamertersのインスタンスとして使用することができます。詳細な情報と、APIの例については、こちらを参照してください。

 

 

コンバーターのUIを作成し、構成値を使用する方法の簡単な例は、以下の通りです。

Code Block
languagejava
@Override
protected void setupParameters() {
   Parameter p = new Parameter();
   p.setUniqueKey("DENOMINATOR");
   p.setDisplayName("Denominator");
   p.setDataType(TYPE_NUMERIC);
   p.setDisplayType(DISPLAY_TEXT_MEDLONG);
   addParameter(p);
}
 
@Override
public Object convertObject(Object data) throws Exception {
   if (data == null) return null;
       
   Number d = (Number)getParameterValue("DENOMINATOR");
   if (d == null) return data;
       
   ...
}

 

 

 

Section
Column
width40%

前項:データ変換の追加

Column
width30%

 

Column
width30%

後項:コンバーターのパッケージ化

 

horizontalrule
Styleclass
ClasstopLink

ページトップ