net.sourceforge.e4graph
Interface Vertex

All Known Subinterfaces:
BooleanVertex, BytesVertex, DoubleVertex, FloatVertex, IntVertex, LongVertex, NodeVertex, StringVertex

public interface Vertex

The Vertex class provides the abstraction of a vertex originating from a node. A vertex is associated with a node, its originating node. Vertices are identified by name and instance count or by rank within the originating node. Each vertex stores an instance of class Object.

Author:
Ryan Shaw

Method Summary
 void close()
          Releases a vertex's resources and closes it immediately.
 void delete()
          Deletes this vertex from its persistent storage.
 java.lang.Object get()
          Returns the value of this vertex.
 int getIndex()
          Returns the index of this vertex within its containing node.
 java.lang.String getName()
          Returns the name of this vertex, or null if the vertex is closed.
 Node getNode()
          Returns the node containing this vertex.
 Storage getStorage()
          Returns the storage containing this vertex.
 int getUniqueID()
          Returns an integer which uniquely identifies this vertex within its containing storage.
 boolean isClosed()
          Tests to see if a vertex is closed.
 void set(java.lang.Object value)
          Sets the value of this vertex.
 void setName(java.lang.String name)
          Sets the name of this vertex.
 

Method Detail

get

public java.lang.Object get()
                     throws E4GraphException
Returns the value of this vertex.
Returns:
the value of this vertex
Throws:
E4GraphException - if the vertex is closed

set

public void set(java.lang.Object value)
         throws E4GraphException
Sets the value of this vertex.
Parameters:
value - the new value of this vertex
Throws:
E4GraphException - if the vertex is closed

getIndex

public int getIndex()
             throws E4GraphException
Returns the index of this vertex within its containing node.
Returns:
the index of this vertex within its containing node
Throws:
E4GraphException - if the vertex is closed

getName

public java.lang.String getName()
Returns the name of this vertex, or null if the vertex is closed.
Returns:
the name of this vertex, or null if the vertex is closed

setName

public void setName(java.lang.String name)
             throws E4GraphException
Sets the name of this vertex.
Parameters:
name - the new name of the vertex
Throws:
E4GraphException - if the vertex is closed

getUniqueID

public int getUniqueID()
Returns an integer which uniquely identifies this vertex within its containing storage.
Returns:
an integer which uniquely identifies this vertex

getStorage

public Storage getStorage()
                   throws E4GraphException
Returns the storage containing this vertex.
Returns:
the storage containing this vertex
Throws:
E4GraphException - if the vertex is closed

getNode

public Node getNode()
             throws E4GraphException
Returns the node containing this vertex.
Returns:
the node containing this vertex
Throws:
E4GraphException - if the vertex is closed

delete

public void delete()
            throws E4GraphException
Deletes this vertex from its persistent storage.
Throws:
E4GraphException - if an error occurs

isClosed

public boolean isClosed()
Tests to see if a vertex is closed.
Returns:
true if the vertex is closed; false if it's still open

close

public void close()
Releases a vertex's resources and closes it immediately.


Copyright (c) 2001, Silver Egg Technology Co., Ltd.