📄 hierarchypropertyparser.html
字号:
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static void</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/gui/HierarchyPropertyParser.html#main(java.lang.String[])">main</A></B>(java.lang.String[] args)</CODE><BR> Tests out the parser.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> int</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/gui/HierarchyPropertyParser.html#numChildren()">numChildren</A></B>()</CODE><BR> The number of the children nodes.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> java.lang.String</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/gui/HierarchyPropertyParser.html#parentValue()">parentValue</A></B>()</CODE><BR> The value in the parent node.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> int</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/gui/HierarchyPropertyParser.html#search(java.util.Vector, java.lang.String)">search</A></B>(java.util.Vector vct, java.lang.String target)</CODE><BR> Helper function to search for the given target string in a given vector in which the elements' value may hopefully is equal to the target.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/gui/HierarchyPropertyParser.html#setSeperator(java.lang.String)">setSeperator</A></B>(java.lang.String s)</CODE><BR> Set the seperator between levels.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> java.lang.String</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/gui/HierarchyPropertyParser.html#showTree()">showTree</A></B>()</CODE><BR> Show the whole tree in text format</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> java.lang.String[]</CODE></FONT></TD><TD><CODE><B><A HREF="../../weka/gui/HierarchyPropertyParser.html#tokenize(java.lang.String)">tokenize</A></B>(java.lang.String rawString)</CODE><BR> Tokenize the given string based on the seperator and put the tokens into an array of strings</TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class java.lang.Object</B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE>equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><!-- ========= 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="HierarchyPropertyParser()"><!-- --></A><H3>HierarchyPropertyParser</H3><PRE>public <B>HierarchyPropertyParser</B>()</PRE><DL><DD>Default constructor<P></DL><HR><A NAME="HierarchyPropertyParser(java.lang.String, java.lang.String)"><!-- --></A><H3>HierarchyPropertyParser</H3><PRE>public <B>HierarchyPropertyParser</B>(java.lang.String p, java.lang.String delim) throws java.lang.Exception</PRE><DL><DD>Constructor that builds a tree from the given property with the given delimitor<P><DT><B>Parameters:</B><DD><CODE>p</CODE> - the given property string<DD><CODE>delim</CODE> - the given dilimitor</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="setSeperator(java.lang.String)"><!-- --></A><H3>setSeperator</H3><PRE>public void <B>setSeperator</B>(java.lang.String s)</PRE><DL><DD>Set the seperator between levels. Default is dot.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>s</CODE> - the seperator symbol</DL></DD></DL><HR><A NAME="getSeperator()"><!-- --></A><H3>getSeperator</H3><PRE>public java.lang.String <B>getSeperator</B>()</PRE><DL><DD>Get the seperator between levels. Default is dot.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>the seperator symbol</DL></DD></DL><HR><A NAME="build(java.lang.String, java.lang.String)"><!-- --></A><H3>build</H3><PRE>public void <B>build</B>(java.lang.String p, java.lang.String delim) throws java.lang.Exception</PRE><DL><DD>Build a tree from the given property with the given delimitor<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>p</CODE> - the given property<DD><CODE>delim</CODE> - the given delimitor<DT><B>Throws:</B><DD><CODE>java.lang.Exception</CODE></DL></DD></DL><HR><A NAME="add(java.lang.String)"><!-- --></A><H3>add</H3><PRE>public void <B>add</B>(java.lang.String property)</PRE><DL><DD>Add the given item of property to the tree<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>property</CODE> - the given item</DL></DD></DL><HR><A NAME="tokenize(java.lang.String)"><!-- --></A><H3>tokenize</H3><PRE>public java.lang.String[] <B>tokenize</B>(java.lang.String rawString)</PRE><DL><DD>Tokenize the given string based on the seperator and put the tokens into an array of strings<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>rawString</CODE> - the given string<DT><B>Returns:</B><DD>an array of strings</DL></DD></DL><HR><A NAME="contains(java.lang.String)"><!-- --></A><H3>contains</H3><PRE>public boolean <B>contains</B>(java.lang.String string)</PRE><DL><DD>Whether the HierarchyPropertyParser contains the given string<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>string</CODE> - the given string<DT><B>Returns:</B><DD>whether contains</DL></DD></DL><HR><A NAME="isHierachic(java.lang.String)"><!-- --></A><H3>isHierachic</H3><PRE>public boolean <B>isHierachic</B>(java.lang.String string)</PRE><DL><DD>Whether the given string has a hierachy structure with the seperators<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>string</CODE> - the given string</DL></DD></DL><HR><A NAME="search(java.util.Vector, java.lang.String)"><!-- --></A><H3>search</H3><PRE>public int <B>search</B>(java.util.Vector vct, java.lang.String target)</PRE><DL><DD>Helper function to search for the given target string in a given vector in which the elements' value may hopefully is equal to the target. If such elements are found the first index is returned, otherwise -1<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>vct</CODE> - the given vector<DD><CODE>target</CODE> - the given target string<DT><B>Returns:</B><DD>the index of the found element, -1 if not found</DL></DD></DL><HR><A NAME="goTo(java.lang.String)"><!-- --></A><H3>goTo</H3><PRE>public boolean <B>goTo</B>(java.lang.String path)</PRE><DL><DD>Go to a certain node of the tree according to the specified path Note that the path must be absolute path from the root. <br> For relative path, see goDown(String path).<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>path</CODE> - the given absolute path<DT><B>Returns:</B><DD>whether the path exists, if false the current position does not move</DL></DD></DL><HR><A NAME="goDown(java.lang.String)"><!-- --></A><H3>goDown</H3><PRE>public boolean <B>goDown</B>(java.lang.String path)</PRE><DL><DD>Go to a certain node of the tree down from the current node according to the specified relative path. The path does not contain the value of current node<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>path</CODE> - the given relative path<DT><B>Returns:</B><DD>whether the path exists, if false the current position does not move</DL></DD></DL><HR><A NAME="goToRoot()"><!-- --></A><H3>goToRoot</H3><PRE>public void <B>goToRoot</B>()</PRE><DL><DD>Go to the root of the tree<P><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="goToParent()"><!-- --></A><H3>goToParent</H3><PRE>public void <B>goToParent</B>()</PRE><DL><DD>Go to the parent from the current position in the tree If the current position is the root, it stays there and does not move
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -