📄 graphmatrixundirected.html
字号:
<BR> Remove possible edge between vertices labeled vLabel1 and vLabel2.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../structure/GraphMatrixUndirected.html#toString()">toString</A></B>()</CODE><BR> Construct a string representation of graph.</TD></TR></TABLE> <A NAME="methods_inherited_from_class_structure.GraphMatrix"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class structure.<A HREF="../structure/GraphMatrix.html">GraphMatrix</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="../structure/GraphMatrix.html#add(java.lang.Object)">add</A>, <A HREF="../structure/GraphMatrix.html#clear()">clear</A>, <A HREF="../structure/GraphMatrix.html#contains(java.lang.Object)">contains</A>, <A HREF="../structure/GraphMatrix.html#containsEdge(java.lang.Object, java.lang.Object)">containsEdge</A>, <A HREF="../structure/GraphMatrix.html#degree(java.lang.Object)">degree</A>, <A HREF="../structure/GraphMatrix.html#get(java.lang.Object)">get</A>, <A HREF="../structure/GraphMatrix.html#getEdge(java.lang.Object, java.lang.Object)">getEdge</A>, <A HREF="../structure/GraphMatrix.html#isDirected()">isDirected</A>, <A HREF="../structure/GraphMatrix.html#isEmpty()">isEmpty</A>, <A HREF="../structure/GraphMatrix.html#isVisited(java.lang.Object)">isVisited</A>, <A HREF="../structure/GraphMatrix.html#isVisitedEdge(structure.Edge)">isVisitedEdge</A>, <A HREF="../structure/GraphMatrix.html#iterator()">iterator</A>, <A HREF="../structure/GraphMatrix.html#neighbors(java.lang.Object)">neighbors</A>, <A HREF="../structure/GraphMatrix.html#remove(java.lang.Object)">remove</A>, <A HREF="../structure/GraphMatrix.html#reset()">reset</A>, <A HREF="../structure/GraphMatrix.html#size()">size</A>, <A HREF="../structure/GraphMatrix.html#visit(java.lang.Object)">visit</A>, <A HREF="../structure/GraphMatrix.html#visitEdge(structure.Edge)">visitEdge</A></CODE></TD></TR></TABLE> <A NAME="methods_inherited_from_class_structure.AbstractStructure"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class structure.<A HREF="../structure/AbstractStructure.html">AbstractStructure</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="../structure/AbstractStructure.html#elements()">elements</A>, <A HREF="../structure/AbstractStructure.html#hashCode()">hashCode</A>, <A HREF="../structure/AbstractStructure.html#values()">values</A></CODE></TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#<clinit>()"><clinit></A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#clone()">clone</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#equals(java.lang.Object)">equals</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#finalize()">finalize</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#getClass()">getClass</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#notify()">notify</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#notifyAll()">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#registerNatives()">registerNatives</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#wait()">wait</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#wait(long)">wait</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#wait(long, int)">wait</A></CODE></TD></TR></TABLE> <A NAME="methods_inherited_from_class_structure.Structure"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from interface structure.<A HREF="../structure/Structure.html">Structure</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="../structure/Structure.html#elements()">elements</A>, <A HREF="../structure/Structure.html#values()">values</A></CODE></TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TD></TR></TABLE><A NAME="GraphMatrixUndirected(int)"><!-- --></A><H3>GraphMatrixUndirected</H3><PRE>public <B>GraphMatrixUndirected</B>(int size)</PRE><DL><DD>Construct an undirected, adjacency-matrix based graph.<DD><DL><DT><B>Parameters:</B><DD><CODE>size</CODE> - Maximum number of vertices in graph.</DL></DD></DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="addEdge(java.lang.Object, java.lang.Object, java.lang.Object)"><!-- --></A><H3>addEdge</H3><PRE>public void <B>addEdge</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A> vLabel1, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A> vLabel2, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A> label)</PRE><DL><DD>Add an edge between two vertices within the graph. Edge is undirected. Duplicate edges are silently replaced. Labels on edges may be null.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../structure/GraphMatrix.html#addEdge(java.lang.Object, java.lang.Object, java.lang.Object)">addEdge</A></CODE> in class <CODE><A HREF="../structure/GraphMatrix.html">GraphMatrix</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>vLabel1</CODE> - One vertex.<DD><CODE>vLabel2</CODE> - Another vertex.<DD><CODE>label</CODE> - Label associated with the edge.<DT><B>Precondition:</B><DD>vLabel1 and vLabel2 are labels of existing vertices, v1 & v2<DT><B>Postcondition:</B><DD>an edge (undirected) is inserted between v1 and v2; if edge is new, it is labeled with label (can be null)</DL></DD></DL><HR><A NAME="removeEdge(java.lang.Object, java.lang.Object)"><!-- --></A><H3>removeEdge</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A> <B>removeEdge</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A> vLabel1, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A> vLabel2)</PRE><DL><DD>Remove possible edge between vertices labeled vLabel1 and vLabel2.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../structure/GraphMatrix.html#removeEdge(java.lang.Object, java.lang.Object)">removeEdge</A></CODE> in class <CODE><A HREF="../structure/GraphMatrix.html">GraphMatrix</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>vLabel1</CODE> - One vertex.<DD><CODE>vLabel2</CODE> - Another vertex.<DT><B>Precondition:</B><DD>vLabel1 and vLabel2 are labels of existing vertices<DT><B>Postcondition:</B><DD>edge is removed, its label is returned<DT><B>Returns:</B><DD>The label associated with the edge removed.</DL></DD></DL><HR><A NAME="edgeCount()"><!-- --></A><H3>edgeCount</H3><PRE>public int <B>edgeCount</B>()</PRE><DL><DD>Determine the number of edges in graph.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../structure/GraphMatrix.html#edgeCount()">edgeCount</A></CODE> in class <CODE><A HREF="../structure/GraphMatrix.html">GraphMatrix</A></CODE></DL></DD><DD><DL><DT><B>Postcondition:</B><DD>returns the number of edges in graph<DT><B>Returns:</B><DD>Number of edges in graph.</DL></DD></DL><HR><A NAME="edges()"><!-- --></A><H3>edges</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/util/Iterator.html">Iterator</A> <B>edges</B>()</PRE><DL><DD>Construct an traversal over all edges. edge is considered exactly once. Order is not guaranteed.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="../structure/GraphMatrix.html#edges()">edges</A></CODE> in class <CODE><A HREF="../structure/GraphMatrix.html">GraphMatrix</A></CODE></DL></DD><DD><DL><DT><B>Postcondition:</B><DD>returns traversal across all edges of graph (returns Edges)<DT><B>Returns:</B><DD>AbstractIterator over edges.</DL></DD></DL><HR><A NAME="toString()"><!-- --></A><H3>toString</H3><PRE>public <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A> <B>toString</B>()</PRE><DL><DD>Construct a string representation of graph.<DD><DL><DT><B>Overrides:</B><DD><CODE><A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#toString()">toString</A></CODE> in class <CODE><A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A></CODE></DL></DD><DD><DL><DT><B>Postcondition:</B><DD>returns string representation of graph<DT><B>Returns:</B><DD>String representing graph.</DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_bottom"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3"> <TR ALIGN="center" VALIGN="top"> <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><a href=../copyright.html target=_top>© 1998-2002 McGraw-Hill</a></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../structure/GraphMatrixDirected.html"><B>PREV CLASS</B></A> <A HREF="../structure/GraphMatrixVertex.html"><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="GraphMatrixUndirected.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: INNER | <A HREF="#fields_inherited_from_class_structure.GraphMatrix">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: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -