defaultfeaturetype.html

来自「Geotools是一个开源的Java GIS工具包,可利用它来开发符合标准的地理」· HTML 代码 · 共 961 行 · 第 1/4 页

HTML
961 行
字号
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#find(org.geotools.feature.AttributeType)">find</A></B>(<A HREF="../../../org/geotools/feature/AttributeType.html" title="interface in org.geotools.feature">AttributeType</A>&nbsp;type)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Find the position of a given AttributeType.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#find(java.lang.String)">find</A></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>&nbsp;attName)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Find the position of an AttributeType which matches the given String.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A>[]</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#getAncestors()">getAncestors</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Obtain an array of this FeatureTypes ancestors. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#getAttributeCount()">getAttributeCount</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the number of attributes at the first 'level' of the schema.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../org/geotools/feature/AttributeType.html" title="interface in org.geotools.feature">AttributeType</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#getAttributeType(int)">getAttributeType</A></B>(int&nbsp;position)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the attributeType at the specified index.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../org/geotools/feature/AttributeType.html" title="interface in org.geotools.feature">AttributeType</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#getAttributeType(java.lang.String)">getAttributeType</A></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>&nbsp;xPath)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the attributeType at this xPath, if the specified attributeType does not exist then null is returned.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../org/geotools/feature/AttributeType.html" title="interface in org.geotools.feature">AttributeType</A>[]</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#getAttributeTypes()">getAttributeTypes</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;AttributeTypes for this FeatureType, all attributes defined by this FeatureType and its super types define schema for feature instances. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../org/geotools/feature/GeometryAttributeType.html" title="interface in org.geotools.feature">GeometryAttributeType</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#getDefaultGeometry()">getDefaultGeometry</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the default geometry AttributeType.  </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/net/URI.html" title="class or interface in java.net">URI</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#getNamespace()">getNamespace</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the global schema namespace.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#getTypeName()">getTypeName</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the type name for this schema.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#hasAttributeType(java.lang.String)">hasAttributeType</A></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>&nbsp;xPath)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;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. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#hashCode()">hashCode</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hascode based on namespace, typeName, attributes and ancestors. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#isAbstract()">isAbstract</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Is this FeatureType an abstract type?</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#isDescendedFrom(org.geotools.feature.FeatureType)">isDescendedFrom</A></B>(<A HREF="../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A>&nbsp;type)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A convenience method for calling<br> <code> FeatureType f1; FeatureType f2; f1.isDescendedFrom(f2.getNamespace(),f2.getName()); </code></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#isDescendedFrom(java.net.URI, java.lang.String)">isDescendedFrom</A></B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/net/URI.html" title="class or interface in java.net">URI</A>&nbsp;nsURI,                <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;typeName1)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Test to determine whether this FeatureType is descended from the given FeatureType. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/geotools/feature/DefaultFeatureType.html#toString()">toString</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD></TR></TABLE>&nbsp;<A NAME="methods_inherited_from_class_Object"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD></TR></TABLE>&nbsp;<P><!-- ============ FIELD DETAIL =========== --><A NAME="field_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Field Detail</B></FONT></TD></TR></TABLE><A NAME="EMPTY"><!-- --></A><H3>EMPTY</H3><PRE>public static final <A HREF="../../../org/geotools/feature/FeatureType.html" title="interface in org.geotools.feature">FeatureType</A> <B>EMPTY</B></PRE><DL><DD>An feature type with no attributes<P><DL></DL></DL><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TD></TR></TABLE><A NAME="DefaultFeatureType(java.lang.String, java.lang.String, java.util.Collection, java.util.Collection, org.geotools.feature.GeometryAttributeType)"><!-- --></A><H3>DefaultFeatureType</H3><PRE>public <B>DefaultFeatureType</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>&nbsp;typeName,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;namespace,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Collection.html" title="class or interface in java.util">Collection</A>&nbsp;types,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Collection.html" title="class or interface in java.util">Collection</A>&nbsp;superTypes,                          <A HREF="../../../org/geotools/feature/GeometryAttributeType.html" title="interface in org.geotools.feature">GeometryAttributeType</A>&nbsp;defaultGeom)                   throws <A HREF="../../../org/geotools/feature/SchemaException.html" title="class in org.geotools.feature">SchemaException</A>,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></PRE><DL></DL><HR><A NAME="DefaultFeatureType(java.lang.String, java.net.URI, java.util.Collection, java.util.Collection, org.geotools.feature.GeometryAttributeType)"><!-- --></A><H3>DefaultFeatureType</H3><PRE>public <B>DefaultFeatureType</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>&nbsp;typeName,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/net/URI.html" title="class or interface in java.net">URI</A>&nbsp;namespace,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Collection.html" title="class or interface in java.util">Collection</A>&nbsp;types,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Collection.html" title="class or interface in java.util">Collection</A>&nbsp;superTypes,                          <A HREF="../../../org/geotools/feature/GeometryAttributeType.html" title="interface in org.geotools.feature">GeometryAttributeType</A>&nbsp;defaultGeom)                   throws <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></PRE><DL><DD>Constructs a new DefaultFeatureType. <p> Attributes from the superTypes will be copied to the list of attributes for this feature type.<P><DT><B>Parameters:</B><DD><CODE>typeName</CODE> - The name to give this FeatureType.<DD><CODE>namespace</CODE> - The namespace of the new FeatureType.<DD><CODE>types</CODE> - The attributeTypes to use for validation.<DD><CODE>superTypes</CODE> - The ancestors of this FeatureType.<DD><CODE>defaultGeom</CODE> - The attributeType to set as the defaultGeometry.<DT><B>Throws:</B><DD><CODE><A HREF="../../../org/geotools/feature/SchemaException.html" title="class in org.geotools.feature">SchemaException</A></CODE> - For problems making the FeatureType.<DD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></CODE> - If typeName is null.</DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="create(java.lang.Object[])"><!-- --></A><H3>create</H3><PRE>public <A HREF="../../../org/geotools/feature/Feature.html" title="interface in org.geotools.feature">Feature</A> <B>create</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A>[]&nbsp;attributes)               throws <A HREF="../../../org/geotools/feature/IllegalAttributeException.html" title="class in org.geotools.feature">IllegalAttributeException</A></PRE><DL><DD>Creates a new feature, with a generated unique featureID.  This is less than ideal, as a FeatureID should be persistant over time, generally created by a datasource.  This method is more for testing that doesn't need featureID.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/geotools/feature/FeatureType.html#create(java.lang.Object[])">create</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>attributes</CODE> - the array of attribute values

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?