📄 fidmapper.html
字号:
<B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="initSupportStructures()"><!-- --></A><H3>initSupportStructures</H3><PRE>public void <B>initSupportStructures</B>()</PRE><DL><DD>This method will be called by JDBCDataStore when creating new tables to give the FID mapper an opportunity to initialize needed data structures, such as support tables, sequences, and so on.<P><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="getID(java.lang.Object[])"><!-- --></A><H3>getID</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>getID</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>[] attributes)</PRE><DL><DD>Returns the FID given the values of the prymary key attributes<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>attributes</CODE> - DOCUMENT ME!</DL></DD></DL><HR><A NAME="getPKAttributes(java.lang.String)"><!-- --></A><H3>getPKAttributes</H3><PRE>public <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>getPKAttributes</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> FID) throws <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/IOException.html" title="class or interface in java.io">IOException</A></PRE><DL><DD>Creates the value for the PK attributes given the feature. If the FID is null, will throw an IOException if not possible. If null is returned, no primary key value needs to be specified, which is what we want for auto-increment fields.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>FID</CODE> - The feature ID is going to be parsed<DT><B>Throws:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/IOException.html" title="class or interface in java.io">IOException</A></CODE></DL></DD></DL><HR><A NAME="createID(java.sql.Connection, org.geotools.feature.Feature, java.sql.Statement)"><!-- --></A><H3>createID</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>createID</B>(<A HREF="http://java.sun.com/j2se/1.4/docs/api/java/sql/Connection.html" title="class or interface in java.sql">Connection</A> conn, <A HREF="../../../../../org/geotools/feature/Feature.html" title="interface in org.geotools.feature">Feature</A> feature, <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/sql/Statement.html" title="class or interface in java.sql">Statement</A> statement) throws <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/IOException.html" title="class or interface in java.io">IOException</A></PRE><DL><DD>Creates a new ID for a feature. <br> This is done either by querying the database (for auto-increment like types, for example sequences) or by inspecting the Feature (for example, for primary keys with business meaning that whose attributes are included in the Feature ones).<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>conn</CODE> - - the database connection<DD><CODE>feature</CODE> - - the feature that needs the new FID<DD><CODE>statement</CODE> - - the statement used to insert the feature into the database<DT><B>Throws:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/java/io/IOException.html" title="class or interface in java.io">IOException</A></CODE></DL></DD></DL><HR><A NAME="returnFIDColumnsAsAttributes()"><!-- --></A><H3>returnFIDColumnsAsAttributes</H3><PRE>public boolean <B>returnFIDColumnsAsAttributes</B>()</PRE><DL><DD>If true the primary key columns will be returned as attributes. This is fundamental for primary key with businnes meaning.<P><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="getColumnCount()"><!-- --></A><H3>getColumnCount</H3><PRE>public int <B>getColumnCount</B>()</PRE><DL><DD>Returns the number of columns in the primary keys handled by this mapper<P><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="getColumnName(int)"><!-- --></A><H3>getColumnName</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>getColumnName</B>(int colIndex)</PRE><DL><DD>Returns the name of the specified column in the primary key<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>colIndex</CODE> - </DL></DD></DL><HR><A NAME="getColumnType(int)"><!-- --></A><H3>getColumnType</H3><PRE>public int <B>getColumnType</B>(int colIndex)</PRE><DL><DD>Returns the column type by using a constant available in the java.sql.Types interface<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>colIndex</CODE> - </DL></DD></DL><HR><A NAME="getColumnSize(int)"><!-- --></A><H3>getColumnSize</H3><PRE>public int <B>getColumnSize</B>(int colIndex)</PRE><DL><DD>Returns the size of a primary key column as it would be provided by the database metadata. Some fields requires a size specification, such as VARCHAR or NUMBER, whilst other don't have or don't need it (for example, an INTEGER or a TEXT field).<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>colIndex</CODE> - </DL></DD></DL><HR><A NAME="getColumnDecimalDigits(int)"><!-- --></A><H3>getColumnDecimalDigits</H3><PRE>public int <B>getColumnDecimalDigits</B>(int colIndex)</PRE><DL><DD>Provides the number of decimal digits for this column. This is relevant in particular when the column is a scaled integer such as a NUMBER column<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>colIndex</CODE> - </DL></DD></DL><HR><A NAME="isAutoIncrement(int)"><!-- --></A><H3>isAutoIncrement</H3><PRE>public boolean <B>isAutoIncrement</B>(int colIndex)</PRE><DL><DD>Returns true if the column is of serial type, that is, its value is automatically generated by the database if the user does not provide one<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>colIndex</CODE> - </DL></DD></DL><HR><A NAME="hasAutoIncrementColumns()"><!-- --></A><H3>hasAutoIncrementColumns</H3><PRE>public boolean <B>hasAutoIncrementColumns</B>()</PRE><DL><DD>Returns true if at least one column is of auto-increment type<P><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="isVolatile()"><!-- --></A><H3>isVolatile</H3><PRE>public boolean <B>isVolatile</B>()</PRE><DL><DD>Returns true it the FID generated by this mapper are volatile, that is, if asking twice for the same Feature will not provide the same FID. <p> This is usually true for mappers that try to generate a FID for tables without primary keys. </p> <p> When this method returns true, it's up to the datastore to decide what to do, but a sane policy may be to prevent Feature writing </p><P><DD><DL></DL></DD><DD><DL></DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ======= START OF BOTTOM NAVBAR ====== --><A NAME="navbar_bottom"><!-- --></A><A HREF="#skip-navbar_bottom" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/FIDMapper.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> PREV CLASS <A HREF="../../../../../org/geotools/data/jdbc/fidmapper/FIDMapperFactory.html" title="interface in org.geotools.data.jdbc.fidmapper"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A> <A HREF="FIDMapper.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--></SCRIPT><NOSCRIPT> <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: NESTED | FIELD | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: FIELD | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR>Copyright © 1996-2007 <a href="http://www.geotools.org">Geotools</a>. All Rights Reserved.</BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -