org.gcube.datatransformation.datatransformationlibrary.model.graph
Class TNode

java.lang.Object
  extended by org.gcube.datatransformation.datatransformationlibrary.model.ContentType
      extended by org.gcube.datatransformation.datatransformationlibrary.model.graph.TNode

public class TNode
extends ContentType

Author:
Dimitris Katris, NKUA

Node of the transformationUnit's graph.


Constructor Summary
TNode()
          Creates a new TNode.
TNode(ContentType contentType)
          Instantiates a TNode from a content type.
TNode(String mimeType, List<Parameter> contentTypeParameters)
          Creates a new TNode.
 
Method Summary
 boolean addEdge(TEdge edge)
          Adds a new edge to this node.
 boolean equals(Object obj)
           
 ArrayList<TEdge> getEdges()
          Returns the edges of this node to other nodes of the graph.
 boolean hasEdges()
          Returns true if there are edges from this node to another one.
 int sizeOfEdges()
          Returns the amount of the edges of this node.
 
Methods inherited from class org.gcube.datatransformation.datatransformationlibrary.model.ContentType
addContentTypeParameters, clone, fromDOM, fromXML, gensupport, gensupport, getContentTypeParameters, getMimeType, hashCode, setContentTypeParameters, setMimeType, support, support, supportAndFillUnbound, toDOM, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TNode

public TNode()
Creates a new TNode.


TNode

public TNode(ContentType contentType)
Instantiates a TNode from a content type.

Parameters:
contentType - The content type of the TNode.

TNode

public TNode(String mimeType,
             List<Parameter> contentTypeParameters)
Creates a new TNode.

Parameters:
mimeType - The mimetype of the node.
contentTypeParameters - The content type parameters of the node.
Method Detail

getEdges

public ArrayList<TEdge> getEdges()
Returns the edges of this node to other nodes of the graph.

Returns:
The edges of this node.

addEdge

public boolean addEdge(TEdge edge)
Adds a new edge to this node.

Parameters:
edge - The edge to be added.
Returns:
If the edge was added successfully.

hasEdges

public boolean hasEdges()
Returns true if there are edges from this node to another one.

Returns:
true if there are edges from this node to another one.

sizeOfEdges

public int sizeOfEdges()
Returns the amount of the edges of this node.

Returns:
The amount of the edges of this node.

equals

public boolean equals(Object obj)
Overrides:
equals in class ContentType
Parameters:
obj - The object to be checked.
Returns:
True if the two nodes are equal.
See Also:
ContentType.equals(java.lang.Object)


Copyright © 2013. All Rights Reserved.