public enum StandardFormaUserParamKey extends java.lang.Enum<StandardFormaUserParamKey> implements FormaUserParamKey
修飾子とタイプ | メソッドと説明 |
---|---|
static StandardFormaUserParamKey |
valueOf(java.lang.String name)
指定した名前を持つこの型の列挙型定数を返します。
|
static StandardFormaUserParamKey[] |
values()
この列挙型の定数を含む配列を宣言されている順序で返します。
|
public static final StandardFormaUserParamKey ITEMS
各アイテムの登録情報は、Map
<
String
,
Object
>
の形式でパラメータ値を設定してください。
アイテムのデータ型に応じて、以下の形式で設定してください。
String
型で文字列を指定してください。Number
のサブクラス型で数値を指定してください。Date
型で 日付を指定してください。Date
型で タイムスタンプを指定してください。String
型で 文字列を指定してください。List
<
Map
<
String
,
Object
>>
型で指定してください。List
内の Map
<
String
,
Object
>
には、上述の「文字列」、「数値」、「日付」、「タイムスタンプ」と同様に指定してください。
final Map<FormaUserParamKey, Object> formaUserParam = new HashMap<>(); final Map<String, Object> items = new HashMap<>(); // 文字列 items.put("textbox1", "文字列"); // 数値 items.put("number1", 12345); // 日付 items.put("date1", new Date()); // タイムスタンプ items.put("timestamp1", new Date()); // バイナリ(※リッチテキストボックス) items.put("richtextbox1", "<span style=\"color:red;font-size:100px\">リッチテキストボックス</span>"); formaUserParam.put(StandardFormaUserParamKey.ITEMS, items);
final Map<FormaUserParamKey, Object> formaUserParam = new HashMap<>(); final Map<String, Object> items = new HashMap<>(); final List<Map<String, Object>> details = new ArrayList<>(); // 明細1行目 Map<String, Object> detail1 = new HashMap<>(); detail1.put("tb1_textbox1", "1行目"); detail1.put("tb1_textbox2", 1); detail1.put("tb1_date1", new Date()); detail1.put("tb1_timestamp1", new Date()); details.add(detail1); // 明細2行目 Map<String, Object> detail2 = new HashMap<>(); detail2.put("tb1_textbox1", "2行目"); detail2.put("tb1_textbox2", 2); detail2.put("tb1_date1", new Date()); detail2.put("tb1_timestamp1", new Date()); details.add(detail2); items.put("tb1", details); formaUserParam.put(StandardFormaUserParamKey.ITEMS, items);
public static final StandardFormaUserParamKey FILES
FormaFileUpload
[]
の形式でパラメータ値を設定してください。 final Map<FormaUserParamKey, Object> formaUserParam = new HashMap<>(); // 添付ファイル1個目 final FormaFileUpload file1 = new FormaFileUpload(); file1.setFile(new FileInputStream(new File("c:/spam.png"))); file1.setItemId("attach_fileupload_item1"); file1.setNotes("これはスパムの画像です。"); // 添付ファイル2個目 final FormaFileUpload file2 = new FormaFileUpload(); file2.setFile(new FileInputStream(new File("c:/ham.png"))); file2.setItemId("attach_fileupload_item1"); file2.setNotes("これはハムの画像です。"); // 添付ファイル3個目 final FormaFileUpload file3 = new FormaFileUpload(); file3.setFile(new FileInputStream(new File("c:/eggs.png"))); file3.setItemId("attach_fileupload_item1"); file3.setNotes("これは卵の画像です。"); final FormaFileUpload[] files = new FormaFileUpload[] { file1, file2, file3 }; formaUserParam.put(StandardFormaUserParamKey.FILES, files);
FormaFileUpload
public static StandardFormaUserParamKey[] values()
for(StandardFormaUserParamKey c: StandardFormaUserParamKey.values()) System.out.println(c);
public static StandardFormaUserParamKey valueOf(java.lang.String name)
name
- 返される列挙型定数の名前。java.lang.IllegalArgumentException
- この列挙型に、指定した名前の定数がない場合java.lang.NullPointerException
- 引数がnullの場合Copyright (c) 2013 NTT DATA INTRAMART CORPORATION.