public void init(String fid) { // mark as new according to the fid newFeature = fid == null; // clear values for (int i = 0; i < values.length; i++) { values[i] = null; dirty[i] = false; } this.fid = SimpleFeatureBuilder.createDefaultFeatureIdentifier(fid); }
public void init(String fid) { // mark as new according to the fid newFeature = fid == null; //clear values for (int i = 0; i < values.length; i++) { values[i] = null; dirty[i] = false; } this.fid = SimpleFeatureBuilder.createDefaultFeatureIdentifier(fid); }
public void init(String fid) { // mark as new according to the fid newFeature = fid == null; //clear values for (int i = 0; i < values.length; i++) { values[i] = null; dirty[i] = false; } this.fid = SimpleFeatureBuilder.createDefaultFeatureIdentifier(fid); }
public DefaultFeature(List/*<Attribute>*/ attributes,DefaultFeatureType schema, String id ) { super( attributes, schema, SimpleFeatureBuilder.createDefaultFeatureIdentifier(id) ); } /**
assertTrue( fids.contains( SimpleFeatureBuilder.createDefaultFeatureIdentifier(typeName + ".30"))); assertTrue( fids.contains( SimpleFeatureBuilder.createDefaultFeatureIdentifier(typeName + ".40"))); assertTrue( fids.contains( SimpleFeatureBuilder.createDefaultFeatureIdentifier(typeName + ".50")));
/** * Creates a new instance of flat feature, which must take a flat feature * type schema and all attributes as arguments. * * @param schema Feature type schema for this flat feature. * @param attributes Initial attributes for this feature. * @param featureID The unique ID for this feature. * * @throws IllegalAttributeException Attribtues do not conform to feature * type schema. * @throws NullPointerException if schema is null. */ protected DefaultFeature(DefaultFeatureType schema, Object[] attributes, String featureID) throws IllegalAttributeException, NullPointerException { //super( Arrays.asList(attributes), schema, featureID ); super(wrapValues(attributes,schema), schema, SimpleFeatureBuilder.createDefaultFeatureIdentifier(featureID) ); if (schema == null) { throw new NullPointerException("schema"); } // this.schema = schema; // this.featureId = (featureID == null) ? defaultID() : featureID; // this.attributes = new Object[schema.getAttributeCount()]; // // setAttributes(attributes); }
/** * Creates a new instance of flat feature, which must take a flat feature * type schema and all attributes as arguments. * * @param schema Feature type schema for this flat feature. * @param attributes Initial attributes for this feature. * @param featureID The unique ID for this feature. * * @throws IllegalAttributeException Attribtues do not conform to feature * type schema. * @throws NullPointerException if schema is null. */ protected LenientFeature(List<Attribute> attributes, SimpleFeatureType schema, String featureID) throws IllegalAttributeException, NullPointerException { super( preFix(attributes, schema), checkSchema( schema), SimpleFeatureBuilder.createDefaultFeatureIdentifier(featureID )); // superclass just punts the values in ... we are going to validate if needed constructing=true; List<Object> values = toValues( attributes ); //values = fixed( values ); setAttributes(values); constructing=false; }