📄 formfield.html
字号:
getOptions</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/util/Iterator.html" title="class or interface in java.util">Iterator</A><<A HREF="../../../org/jivesoftware/smackx/FormField.Option.html" title="class in org.jivesoftware.smackx">FormField.Option</A>> <B>getOptions</B>()</PRE><DL><DD>Returns an Iterator for the available options that the user has in order to answer the question.<P><DD><DL><DT><B>Returns:</B><DD>Iterator for the available options.</DL></DD></DL><HR><A NAME="isRequired()"><!-- --></A><H3>isRequired</H3><PRE>public boolean <B>isRequired</B>()</PRE><DL><DD>Returns true if the question must be answered in order to complete the questionnaire.<P><DD><DL><DT><B>Returns:</B><DD>true if the question must be answered in order to complete the questionnaire.</DL></DD></DL><HR><A NAME="getType()"><!-- --></A><H3>getType</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> <B>getType</B>()</PRE><DL><DD>Returns an indicative of the format for the data to answer. Valid formats are: <p/> <ul> <li>text-single -> single line or word of text <li>text-private -> instead of showing the user what they typed, you show ***** to protect it <li>text-multi -> multiple lines of text entry <li>list-single -> given a list of choices, pick one <li>list-multi -> given a list of choices, pick one or more <li>boolean -> 0 or 1, true or false, yes or no. Default value is 0 <li>fixed -> fixed for putting in text to show sections, or just advertise your web site in the middle of the form <li>hidden -> is not given to the user at all, but returned with the questionnaire <li>jid-single -> Jabber ID - choosing a JID from your roster, and entering one based on the rules for a JID. <li>jid-multi -> multiple entries for JIDs </ul><P><DD><DL><DT><B>Returns:</B><DD>format for the data to answer.</DL></DD></DL><HR><A NAME="getValues()"><!-- --></A><H3>getValues</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/util/Iterator.html" title="class or interface in java.util">Iterator</A><<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>> <B>getValues</B>()</PRE><DL><DD>Returns an Iterator for the default values of the question if the question is part of a form to fill out. Otherwise, returns an Iterator for the answered values of the question.<P><DD><DL><DT><B>Returns:</B><DD>an Iterator for the default values or answered values of the question.</DL></DD></DL><HR><A NAME="getVariable()"><!-- --></A><H3>getVariable</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> <B>getVariable</B>()</PRE><DL><DD>Returns the variable name that the question is filling out.<P><DD><DL><DT><B>Returns:</B><DD>the variable name of the question.</DL></DD></DL><HR><A NAME="setDescription(java.lang.String)"><!-- --></A><H3>setDescription</H3><PRE>public void <B>setDescription</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> description)</PRE><DL><DD>Sets a description that provides extra clarification about the question. This information could be presented to the user either in tool-tip, help button, or as a section of text before the question.<p> <p/> If the question is of type FIXED then the description should remain empty.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>description</CODE> - provides extra clarification about the question.</DL></DD></DL><HR><A NAME="setLabel(java.lang.String)"><!-- --></A><H3>setLabel</H3><PRE>public void <B>setLabel</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> label)</PRE><DL><DD>Sets the label of the question which should give enough information to the user to fill out the form.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>label</CODE> - the label of the question.</DL></DD></DL><HR><A NAME="setRequired(boolean)"><!-- --></A><H3>setRequired</H3><PRE>public void <B>setRequired</B>(boolean required)</PRE><DL><DD>Sets if the question must be answered in order to complete the questionnaire.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>required</CODE> - if the question must be answered in order to complete the questionnaire.</DL></DD></DL><HR><A NAME="setType(java.lang.String)"><!-- --></A><H3>setType</H3><PRE>public void <B>setType</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> type)</PRE><DL><DD>Sets an indicative of the format for the data to answer. Valid formats are: <p/> <ul> <li>text-single -> single line or word of text <li>text-private -> instead of showing the user what they typed, you show ***** to protect it <li>text-multi -> multiple lines of text entry <li>list-single -> given a list of choices, pick one <li>list-multi -> given a list of choices, pick one or more <li>boolean -> 0 or 1, true or false, yes or no. Default value is 0 <li>fixed -> fixed for putting in text to show sections, or just advertise your web site in the middle of the form <li>hidden -> is not given to the user at all, but returned with the questionnaire <li>jid-single -> Jabber ID - choosing a JID from your roster, and entering one based on the rules for a JID. <li>jid-multi -> multiple entries for JIDs </ul><P><DD><DL><DT><B>Parameters:</B><DD><CODE>type</CODE> - an indicative of the format for the data to answer.</DL></DD></DL><HR><A NAME="addValue(java.lang.String)"><!-- --></A><H3>addValue</H3><PRE>public void <B>addValue</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> value)</PRE><DL><DD>Adds a default value to the question if the question is part of a form to fill out. Otherwise, adds an answered value to the question.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>value</CODE> - a default value or an answered value of the question.</DL></DD></DL><HR><A NAME="addValues(java.util.List)"><!-- --></A><H3>addValues</H3><PRE>public void <B>addValues</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/util/List.html" title="class or interface in java.util">List</A><<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>> newValues)</PRE><DL><DD>Adds a default values to the question if the question is part of a form to fill out. Otherwise, adds an answered values to the question.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>newValues</CODE> - default values or an answered values of the question.</DL></DD></DL><HR><A NAME="resetValues()"><!-- --></A><H3>resetValues</H3><PRE>protected void <B>resetValues</B>()</PRE><DL><DD>Removes all the values of the field.<P><DD><DL></DL></DD></DL><HR><A NAME="addOption(org.jivesoftware.smackx.FormField.Option)"><!-- --></A><H3>addOption</H3><PRE>public void <B>addOption</B>(<A HREF="../../../org/jivesoftware/smackx/FormField.Option.html" title="class in org.jivesoftware.smackx">FormField.Option</A> option)</PRE><DL><DD>Adss an available options to the question that the user has in order to answer the question.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>option</CODE> - a new available option for the question.</DL></DD></DL><HR><A NAME="toXML()"><!-- --></A><H3>toXML</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A> <B>toXML</B>()</PRE><DL><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=2 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="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><b>Smack</b></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../org/jivesoftware/smackx/Form.html" title="class in org.jivesoftware.smackx"><B>PREV CLASS</B></A> <A HREF="../../../org/jivesoftware/smackx/FormField.Option.html" title="class in org.jivesoftware.smackx"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../index.html?org/jivesoftware/smackx/FormField.html" target="_top"><B>FRAMES</B></A> <A HREF="FormField.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: <A HREF="#nested_class_summary">NESTED</A> | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR><i>Copyright © 2003-2007 Jive Software. </i></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -