|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
A representation of an object in the world, including its location, geometry, and other attributes. A Feature has spatial attributes (polygons, points, etc.) and non-spatial attributes (strings, dates, and numbers).
In the current Workbench model, each feature has one spatial attribute (Geometry) and zero or more non-spatial attributes.
| Method Summary | |
java.lang.Object |
clone()
Clones this Feature. |
Feature |
clone(boolean deep)
Clones this Feature. |
java.lang.Object |
getAttribute(int i)
Returns the specified attribute. |
java.lang.Object |
getAttribute(java.lang.String name)
Returns the specified attribute. |
java.lang.Object[] |
getAttributes()
A low-level accessor that is not normally used. |
double |
getDouble(int attributeIndex)
Returns a double attribute. |
com.vividsolutions.jts.geom.Geometry |
getGeometry()
Convenience method for returning the spatial attribute. |
int |
getID()
Returns a number that uniquely identifies this feature. |
int |
getInteger(int attributeIndex)
Returns a integer attribute. |
FeatureSchema |
getSchema()
Returns the feature's metadata |
java.lang.String |
getString(int attributeIndex)
Returns the result of calling #toString on the attribute at the given (zero-based) index, or "" if it is null. |
java.lang.String |
getString(java.lang.String attributeName)
Returns the result of calling #toString on the attribute with the given (case-sensitive) name, or "" if it is null. |
void |
setAttribute(int attributeIndex,
java.lang.Object newAttribute)
Sets the specified attribute. |
void |
setAttribute(java.lang.String attributeName,
java.lang.Object newAttribute)
Sets the specified attribute. |
void |
setAttributes(java.lang.Object[] attributes)
A low-level accessor that is not normally used. |
void |
setGeometry(com.vividsolutions.jts.geom.Geometry geometry)
Convenience method for setting the spatial attribute. |
void |
setSchema(FeatureSchema schema)
A low-level accessor that is not normally used. |
| Methods inherited from interface java.lang.Comparable |
compareTo |
| Method Detail |
public void setAttributes(java.lang.Object[] attributes)
attributes - may have a different
length than the current attributes.public void setSchema(FeatureSchema schema)
public int getID()
public void setAttribute(int attributeIndex,
java.lang.Object newAttribute)
attributeIndex - the array index at which to put the new attributenewAttribute - the new attribute
public void setAttribute(java.lang.String attributeName,
java.lang.Object newAttribute)
attributeName - the name of the attribute to setnewAttribute - the new attributepublic void setGeometry(com.vividsolutions.jts.geom.Geometry geometry)
geometry - the new spatial attributepublic java.lang.Object getAttribute(int i)
i - the index of the attribute to get
public java.lang.Object getAttribute(java.lang.String name)
name - the name of the attribute to get
public java.lang.String getString(int attributeIndex)
public int getInteger(int attributeIndex)
attributeIndex - the index of the attribute to retrieve
public double getDouble(int attributeIndex)
attributeIndex - the index of the attribute to retrieve
public java.lang.String getString(java.lang.String attributeName)
public com.vividsolutions.jts.geom.Geometry getGeometry()
public FeatureSchema getSchema()
public java.lang.Object clone()
public Feature clone(boolean deep)
deep - whether or not to clone the geometry
public java.lang.Object[] getAttributes()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||