org.progeeks.graph
Class EdgeUserObjectFormat

java.lang.Object
  extended by org.progeeks.meta.format.AbstractPropertyFormat
      extended by org.progeeks.meta.format.DefaultPropertyFormat
          extended by org.progeeks.graph.EdgeUserObjectFormat
All Implemented Interfaces:
PropertyFormat

public class EdgeUserObjectFormat
extends DefaultPropertyFormat

Version:
$Revision: 1.1 $
Author:
Paul Speed

Constructor Summary
EdgeUserObjectFormat()
           
 
Method Summary
 java.lang.String format(java.lang.Object obj)
          Formats the specified object as a string.
 PropertyFormat getDelegateFormat()
          Returns the delegate PropertyFormat that edge user objects will be passed to for string conversion.
 void setDelegateFormat(PropertyFormat format)
          Sets the delegate PropertyFormat that edge user objects will be passed to for string conversion.
 
Methods inherited from class org.progeeks.meta.format.DefaultPropertyFormat
format, parseObject, toString
 
Methods inherited from class org.progeeks.meta.format.AbstractPropertyFormat
format, parseObject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EdgeUserObjectFormat

public EdgeUserObjectFormat()
Method Detail

setDelegateFormat

public void setDelegateFormat(PropertyFormat format)
Sets the delegate PropertyFormat that edge user objects will be passed to for string conversion. If a passed object is not an edge then it is also handed to the delegate format directly.


getDelegateFormat

public PropertyFormat getDelegateFormat()
Returns the delegate PropertyFormat that edge user objects will be passed to for string conversion.


format

public java.lang.String format(java.lang.Object obj)
Formats the specified object as a string. If the object is a Graph.Edge then the user object object is unwrapped and passed to the delegate property format. Otherwise, the object is passed to the delegate directly.

Specified by:
format in interface PropertyFormat
Overrides:
format in class DefaultPropertyFormat


Copyright © 2002-2003 Paul Speed. All Rights Reserved.