wt.epm.util
Class LinkUtilities

java.lang.Object
  extended bywt.epm.util.LinkUtilities

public class LinkUtilities
extends Object

The LinkUtilities class provides set of static methods for sorting and manipulating collections of Binary links.

Supported API: false

Extendable: false


Nested Class Summary
private static class LinkUtilities.Role
           
 
Field Summary
private static String ROLEA_REF
           
private static String ROLEB_REF
           
 
Constructor Summary
LinkUtilities()
           
 
Method Summary
static WTSet getRoleObjects(WTCollection links, Class linkClass, String roleName)
          Given a collection of links, return a WTSet of objects for the given role.
static void inflateRoleObjects(WTCollection links, Class linkClass, String roleName, WTCollection objects)
           
static WTKeyedMap sortByRole(WTCollection links, Class linkClass, String roleName)
          Given a collection of BinaryLinks, sort the links of the given class by the given role.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ROLEA_REF

private static String ROLEA_REF

ROLEB_REF

private static String ROLEB_REF
Constructor Detail

LinkUtilities

public LinkUtilities()
Method Detail

getRoleObjects

public static WTSet getRoleObjects(WTCollection links,
                                   Class linkClass,
                                   String roleName)
                            throws WTException
Given a collection of links, return a WTSet of objects for the given role. If the role object is inflated, the object is added to the WTSet otherwise its QueryKey is.

Supported API: false

Returns:
WTSet of objects for the given role
Throws:
WTException

sortByRole

public static WTKeyedMap sortByRole(WTCollection links,
                                    Class linkClass,
                                    String roleName)
                             throws WTException
Given a collection of BinaryLinks, sort the links of the given class by the given role.

Supported API: false

Returns:
Map that holds WTSets of links of the given class indexed by the given role
Throws:
WTException

inflateRoleObjects

public static void inflateRoleObjects(WTCollection links,
                                      Class linkClass,
                                      String roleName,
                                      WTCollection objects)
                               throws WTException
Throws:
WTException