org.plasma.sdo.core
Class CorePathAssembler

java.lang.Object
  extended by org.plasma.sdo.core.CorePathAssembler
All Implemented Interfaces:
PathAssembler, PlasmaDataGraphVisitor

public class CorePathAssembler
extends Object
implements PathAssembler

A graph visitor which assembles and stores a list of candidate paths from the root data-object to the given target data-object and returns the minimum (least hops) path or set of paths as SDO path-strings.


Field Summary
static String PATH_DELIM
           
static String PATH_INDEX_LEFT
           
static String PATH_INDEX_RIGHT
           
static String PATH_PREFIX
           
 
Constructor Summary
CorePathAssembler(DataObject pathTarget)
           
 
Method Summary
 String[] getAllPaths()
           
 int getMinimumPathDepth()
           
 String getMinimumPathString()
           
 int getPathCount()
           
 void visit(DataObject target, DataObject source, String propertyName, int level)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PATH_PREFIX

public static String PATH_PREFIX

PATH_DELIM

public static String PATH_DELIM

PATH_INDEX_RIGHT

public static String PATH_INDEX_RIGHT

PATH_INDEX_LEFT

public static String PATH_INDEX_LEFT
Constructor Detail

CorePathAssembler

public CorePathAssembler(DataObject pathTarget)
Method Detail

visit

public void visit(DataObject target,
                  DataObject source,
                  String propertyName,
                  int level)
Specified by:
visit in interface PlasmaDataGraphVisitor

getMinimumPathString

public String getMinimumPathString()
Specified by:
getMinimumPathString in interface PathAssembler

getMinimumPathDepth

public int getMinimumPathDepth()
Specified by:
getMinimumPathDepth in interface PathAssembler

getPathCount

public int getPathCount()
Specified by:
getPathCount in interface PathAssembler

getAllPaths

public String[] getAllPaths()
Specified by:
getAllPaths in interface PathAssembler


Copyright © 2014. All rights reserved.