コード例 #1
0
 @Override
 public List<Object> write(Transaction transaction) throws IllegalStateException {
   //
   // Decide if feature values is allowed to be updated from backing store
   //
   if (!isDetached()) {
     throw new IllegalStateException(
         "ESimpleFeature " + getType().getTypeName() + " is not detached");
   }
   //
   // Get properties
   //
   List<EFeaturePropertyDelegate<?, ? extends Property, ? extends EStructuralFeature>> eList =
       eInternal.getProperties();
   //
   // Prepare to read values from properties
   //
   List<Object> eValues = new ArrayList<Object>(eList.size());
   //
   // Loop over all properties
   //
   for (EFeatureProperty<?, ? extends Property> it : eList) {
     eValues.add(it.write(eInternal().eTx));
   }
   //
   // Finished
   //
   return eValues;
 }
コード例 #2
0
 @Override
 public Property getProperty(String eName) {
   // Get instance, returns null if not found
   //
   EFeatureProperty<?, ? extends Property> eProperty = eInternal.getPropertyMap().get(eName);
   //
   // Get property instance, return null if not found
   //
   return (eProperty != null ? eProperty.getData() : null);
 }
コード例 #3
0
 @Override
 public List<Property> getProperties() {
   // Initialize
   //
   List<Property> eList = new ArrayList<Property>();
   //
   // Loop over all EFeatureProperty instances,
   // collecting current Property instances.
   //
   for (EFeatureProperty<?, ? extends Property> it : eInternal.getProperties()) {
     eList.add(it.getData());
   }
   // Finished
   //
   return Collections.unmodifiableList(eList);
 }
コード例 #4
0
 @Override
 public List<Object> read(Transaction transaction) throws IllegalStateException {
   //
   // Get properties
   //
   List<EFeaturePropertyDelegate<?, ? extends Property, ? extends EStructuralFeature>> eList =
       eInternal.getProperties();
   //
   // Prepare to read values from properties
   //
   List<Object> eValues = new ArrayList<Object>(eList.size());
   //
   // Loop over all properties
   //
   for (EFeatureProperty<?, ? extends Property> it : eList) {
     eValues.add(it.read(eInternal().eTx));
   }
   //
   // Finished
   //
   return eValues;
 }