|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectscg.ac.ni.pmf.newgraph.graphdata.VertexData
public final class VertexData
Represents the data which defines a vertex. It has the ID of the vertex and the coordinates. It also implements the basic methods for manipulating vertices as the data structure, such as hash tables and sorting algorithms.
The class can only report info about the vertex, it can not change it.
For changing the vertex, the class Vertex
is used.
Vertex
,
Graph
,
Serialized FormMethod Summary | |
---|---|
java.lang.Object |
clone()
Clones the vertex. |
int |
compareTo(java.lang.Object o)
Compares the object. |
java.util.Set |
component()
Retrieves the component that the vertex belongs to. |
int |
degree()
Retrieves the degree of the vertex. |
boolean |
equals(java.lang.Object obj)
Indicates whether some other object is equal to this one. |
int |
getID()
Retrieves the identification number (ID) of the vertex. |
java.util.Set |
getIncident()
Retrieves the set of edges incident with the specified vertex. |
java.util.Enumeration |
getNeighbors()
Retrieves an enumeration of neighbors of the specified vertex. |
float |
getX()
Retrieves the horizontal coordinate (X) of the vertex on the graphical representation of the graph. |
float |
getY()
Retrieves the vertical coordinate (Y) of the vertex on the graphical representation of the graph. |
int |
hashCode()
Returns a hash code value for the object. |
boolean |
isAdjanced(VertexData v)
Retrieves is the vertex adjanced to the specified vertex. |
boolean |
isIncident(EdgeData e)
Retrieves is the vertex incident with the specified edge. |
boolean |
isPrimarySelected()
Retrieves is the vertex primary selected. |
boolean |
isSelected()
Retrieves is the vertex selected. |
java.lang.String |
toString()
Returns a string representation of the object. |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
Object.equals(Object)
public int hashCode()
hashCode
in class java.lang.Object
Object.hashCode()
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
clone
in class java.lang.Object
java.lang.CloneNotSupportedException
Object.clone()
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
Comparable.compareTo(Object)
public int getID()
public float getX()
public float getY()
public boolean isAdjanced(VertexData v)
v
- The vertex.
public boolean isIncident(EdgeData e)
e
- The edge.
public boolean isSelected()
isSelected
in interface ElementData
public boolean isPrimarySelected()
public java.util.Enumeration getNeighbors()
VertexData
.public java.util.Set getIncident()
null
.
EdgeData
.public int degree()
public java.util.Set component()
VertexData
.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |