📄 vpffeatureclass.html
字号:
</p> <p> The Registry interface provided by the data module provides an example of how to store associate FeatureType and namespace information. Please note that you may not have duplicate typeNames in the same Namespace. </p><P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/geotools/feature/FeatureType.html#getNamespace()">getNamespace</A></CODE> in interface <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>Namespace of schema</DL></DD></DL><HR><A NAME="getTypeName()"><!-- --></A><H3>getTypeName</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> <B>getTypeName</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></B></DD><DD>Gets the type name for this schema. <p> In GML this must be the element name of the Feature. </p><P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/geotools/feature/FeatureType.html#getTypeName()">getTypeName</A></CODE> in interface <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>The name of this feature type.</DL></DD></DL><HR><A NAME="getAttributeTypes()"><!-- --></A><H3>getAttributeTypes</H3><PRE>public <A HREF="../../../../org/geotools/feature/AttributeType.html" title="interface in org.geotools.feature">AttributeType</A>[] <B>getAttributeTypes</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></B></DD><DD>AttributeTypes for this FeatureType, all attributes defined by this FeatureType and its super types define schema for feature instances. <p> The provided array of AttributeTypes should be considered as adding to (or overriding) the the AttribtueTypes defined by this FeatureTypes ancestors. </p> <p> Note Well: Client code should not consider the index provided by the find( attName ) method as a valid index into the returned array. </p><P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/geotools/feature/FeatureType.html#getAttributeTypes()">getAttributeTypes</A></CODE> in interface <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>Array of AttributeType describing this schema, array may be length 0, but should not be null</DL></DD></DL><HR><A NAME="hasAttributeType(java.lang.String)"><!-- --></A><H3>hasAttributeType</H3><PRE>public boolean <B>hasAttributeType</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> xPath)</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></B></DD><DD>This is only used twice in the whole geotools code base, and one of those is for a test, so we're removing it from the interface. If getAttributeType does not have the AttributeType it will just return null. Gets the number of occurrences of this attribute. <p> Question: the comment says we are removing this, but it is not depricated? And how the heck can the number of occurances out of a boolean. </p><P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/geotools/feature/FeatureType.html#hasAttributeType(java.lang.String)">hasAttributeType</A></CODE> in interface <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>xPath</CODE> - XPath pointer to attribute type.<DT><B>Returns:</B><DD>Number of occurrences.</DL></DD></DL><HR><A NAME="getAttributeType(java.lang.String)"><!-- --></A><H3>getAttributeType</H3><PRE>public <A HREF="../../../../org/geotools/feature/AttributeType.html" title="interface in org.geotools.feature">AttributeType</A> <B>getAttributeType</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> xPath)</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></B></DD><DD>Gets the attributeType at this xPath, if the specified attributeType does not exist then <code>null</code> is returned. <p> Question: it is unclear how this interacts with the complete schema defined by this FeatureType and its ancestors (in which a given xpath may refer to several AttributeTypes as restrictions are applied. </p> <p> Perhaps this method should be restricted to a FlatFeatureType? Or should have the option of returning an array of matching AttributeType in order of inheiritence? </p><P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/geotools/feature/FeatureType.html#getAttributeType(java.lang.String)">getAttributeType</A></CODE> in interface <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>xPath</CODE> - XPath pointer to attribute type.<DT><B>Returns:</B><DD>AttributeType, or null if unavaialble</DL></DD></DL><HR><A NAME="find(org.geotools.feature.AttributeType)"><!-- --></A><H3>find</H3><PRE>public int <B>find</B>(<A HREF="../../../../org/geotools/feature/AttributeType.html" title="interface in org.geotools.feature">AttributeType</A> type)</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></B></DD><DD>Find the position of a given AttributeType. <p> Match is based on attribute type name, the resulting index may be used with getAttributeType( index ). </p><P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/geotools/feature/FeatureType.html#find(org.geotools.feature.AttributeType)">find</A></CODE> in interface <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>type</CODE> - The type to search for.<DT><B>Returns:</B><DD>-1 if not found, a zero-based index if found.</DL></DD></DL><HR><A NAME="getDefaultGeometry()"><!-- --></A><H3>getDefaultGeometry</H3><PRE>public <A HREF="../../../../org/geotools/feature/GeometryAttributeType.html" title="interface in org.geotools.feature">GeometryAttributeType</A> <B>getDefaultGeometry</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></B></DD><DD>Gets the default geometry AttributeType. <p> If the FeatureType has more one geometry it is up to the implementor to determine which geometry is the default. If working with multiple geometries it is best to get the attributeTypes and iterate through them, checking for instances of GeometryAttribtueType. </p> <p> This should just be used a convenience method when it is known that the features do not have multiple geometries. </p><P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/geotools/feature/FeatureType.html#getDefaultGeometry()">getDefaultGeometry</A></CODE> in interface <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></DL></DD><DD><DL><DT><B>Returns:</B><DD>The attribute type of the default geometry, which will contain the position.</DL></DD></DL><HR><A NAME="getAttributeCount()"><!-- --></A><H3>getAttributeCount</H3><PRE>public int <B>getAttributeCount</B>()</PRE><DL><DD><B>Description copied from interface: <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></B></DD><DD>The number of attribues defined by this schema. <p> This method to allows access to the complete schema as defined by this FeatureType and its ancestors. </p> <p> <ul> Notes: <li> <li>for FeatureType with no super type this count value is the the same as getAttributeTypes().length. </p><P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/geotools/feature/FeatureType.html#getAttributeCount()">getAttributeCount</A></CODE> in interface <CODE><A HREF="../../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A></CODE></DL></DD><DD><DL>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -