public class SimpleFeatureTypeImpl extends FeatureTypeImpl implements SimpleFeatureType
identifiedbinding, description, isAbstract, name, restrictions, superType, userData| Constructor and Description |
|---|
SimpleFeatureTypeImpl(Name name,
List<AttributeDescriptor> schema,
GeometryDescriptor defaultGeometry,
boolean isAbstract,
List<Filter> restrictions,
AttributeType superType,
InternationalString description) |
| Modifier and Type | Method and Description |
|---|---|
int |
getAttributeCount()
Returns the number of attributes composing the feature type
This method is convenience for
getAttributes().size(). |
List<AttributeDescriptor> |
getAttributeDescriptors()
The list of attribute descriptors which make up the feature type.
|
AttributeDescriptor |
getDescriptor(int index)
Returns the attribute descriptor at the specified index.
|
AttributeDescriptor |
getDescriptor(Name name)
Describe a single property by name.
|
AttributeDescriptor |
getDescriptor(String name)
Describe a single property by unqualified name.
|
AttributeType |
getType(int index)
Returns the type of the attribute at the specified index.
|
AttributeType |
getType(Name name)
Returns the type of the attribute which matches the specified name.
|
AttributeType |
getType(String name)
Returns the type of the attribute which matches the specified name.
|
String |
getTypeName()
The local name for this FeatureType.
|
List<AttributeType> |
getTypes()
Returns the types of all the attributes which make up the feature.
|
int |
indexOf(Name name)
Returns the index of the attribute which matches the specified name.
|
int |
indexOf(String name)
Returns the index of the attribute which matches the specified name.
|
equals, getCoordinateReferenceSystem, getGeometryDescriptor, hashCodegetBinding, getDescriptors, isInline, toStringcreateDefaultValue, getSuper, isIdentified, parsegetDescription, getName, getRestrictions, getUserData, isAbstractgetCoordinateReferenceSystem, getGeometryDescriptor, isIdentifiedgetBinding, getDescriptors, isInlinegetSuperequals, getDescription, getName, getRestrictions, getUserData, hashCode, isAbstractpublic SimpleFeatureTypeImpl(Name name, List<AttributeDescriptor> schema, GeometryDescriptor defaultGeometry, boolean isAbstract, List<Filter> restrictions, AttributeType superType, InternationalString description)
public final List<AttributeDescriptor> getAttributeDescriptors()
SimpleFeatureTypeThis method is a convenience for:
return (List<AttributeDescriptor>) getProperties();
getAttributeDescriptors in interface SimpleFeatureTypeSimpleFeatureType.getAttributeDescriptors()public List<AttributeType> getTypes()
SimpleFeatureTypeThis method is convenience for:
List types = new ArrayList();
for (Property p : getProperties()) {
types.add(p.getType());
}
return types;
getTypes in interface SimpleFeatureTypepublic AttributeType getType(Name name)
SimpleFeatureTypeThis method is convenience for:
return (AttributeType) getProperty(name).getType();
If there is no such attribute which matches name, null is returned.
getType in interface SimpleFeatureTypename - The name of the attribute whose type to return.null.public AttributeType getType(String name)
SimpleFeatureTypeThis method is convenience for:
return (AttributeType) getProperty(name).getType();
If there is no such attribute which matches name, null is returned.
getType in interface SimpleFeatureTypename - The name of the attribute whose type to return.null.public AttributeType getType(int index)
SimpleFeatureTypeThis method is convenience for:
return (AttributeType)((List)getProperties()).get(index)).getType();
getType in interface SimpleFeatureTypeindex - The index of the attribute whose type to return.public AttributeDescriptor getDescriptor(Name name)
ComplexTypeThis method returns null if no such property is found.
getDescriptor in interface SimpleFeatureTypegetDescriptor in interface ComplexTypegetDescriptor in class ComplexTypeImplname - The name of the property to get.null.public AttributeDescriptor getDescriptor(String name)
ComplexTypeNote: Special care should be taken when using this method in the case that two properties
with the same local name but different namespace uri exist. For this reason using ComplexType.getDescriptor(Name) is safer.
This method returns null if no such property is found.
getDescriptor in interface SimpleFeatureTypegetDescriptor in interface ComplexTypegetDescriptor in class ComplexTypeImplname - The name of the property to get.null.public AttributeDescriptor getDescriptor(int index)
SimpleFeatureTypeThis method is convenience for:
return (AttributeDescriptor) ((List) getProperties()).get(index);
getDescriptor in interface SimpleFeatureTypeindex - The index of the descriptor to return.public int indexOf(Name name)
SimpleFeatureType-1 is returned in the instance there is no attribute matching the specified name.
indexOf in interface SimpleFeatureTypename - The name of the attribute whose index to return.public int indexOf(String name)
SimpleFeatureType-1 is returned in the instance there is no attribute matching the specified name.
indexOf in interface SimpleFeatureTypename - The name of the attribute whose index to return.public int getAttributeCount()
SimpleFeatureTypeThis method is convenience for getAttributes().size().
getAttributeCount in interface SimpleFeatureTypepublic String getTypeName()
SimpleFeatureTypeSpecifically this method returns getName().getLocalPart().
getTypeName in interface SimpleFeatureTypeCopyright © 1996–2021 Geotools. All rights reserved.