コード例 #1
0
 @Override
 public PropertiesType marshal(TypedProperties tp) throws Exception {
   PropertiesType pxml = new PropertiesType();
   Property[] pa = new Property[tp.size()];
   Set<Entry<Object, Object>> set = tp.entrySet();
   int index = 0;
   for (Entry<Object, Object> entry : set) {
     pa[index] = new Property();
     pa[index].name = (String) entry.getKey();
     pa[index].value = (String) entry.getValue();
     index++;
   }
   pxml.properties = pa;
   return pxml;
 }