Zest
1.5.0.201305060205

org.eclipse.zest.core.viewers
Interface IGraphContentProvider


public interface IGraphContentProvider

A graph content provider.


Method Summary
 java.lang.Object getDestination(java.lang.Object rel)
          Gets the target Object for the given relationship.
 java.lang.Object[] getElements(java.lang.Object input)
          Returns all the relationships in the graph for the given input.
 java.lang.Object getSource(java.lang.Object rel)
          Gets the source Object for the given relationship.
 

Method Detail

getSource

java.lang.Object getSource(java.lang.Object rel)
Gets the source Object for the given relationship. Note, at least one of the source or destination must not be null. If both are null, then nothing can be displayed in the graph (a relationship cannot exist without nodes to be connected to). However, if one of getSource() or getDestination() returns null, then the resulting graph will contain an unconnected node for the non-null object returned from the other method.

Parameters:
rel - the relationship.
Returns:
the source, or null for an unconnected destination.

getDestination

java.lang.Object getDestination(java.lang.Object rel)
Gets the target Object for the given relationship. Note, at least one of the source or destination must not be null. If both are null, then nothing can be displayed in the graph (a relationship cannot exist without nodes to be connected to). However, if one of getSource() or getDestination() returns null, then the resulting graph will contain an unconnected node for the non-null object returned from the other method.

Parameters:
rel - the relationship.
Returns:
the destination, or null for an unconnected source.

getElements

java.lang.Object[] getElements(java.lang.Object input)
Returns all the relationships in the graph for the given input.

Returns:
all the relationships in the graph for the given input.

Zest
1.5.0.201305060205

Copyright (c) IBM Corp. and others 2000, 2011. All Rights Reserved.