Package wt.impact

Class ImpactHelper

java.lang.Object
wt.impact.ImpactHelper

public final class ImpactHelper extends Object
Helper for working with impact associations and for using the ImpactService.

Supported API: true

Extendable: false
See Also:
  • Method Details

    • getService

      public static ImpactService getService()
      Get the implemented wt.impact.ImpactService object.

      Supported API: true
    • getImpactAssociationId

      public static String getImpactAssociationId()
      Get association ID for impact associations.

      Supported API: true
    • getTypeIdentifier

      public static final TypeIdentifier getTypeIdentifier(Object object) throws WTException
      Wrapped for testing purposes.

      Supported API: true
      Throws:
      WTException
      See Also:
    • getSubTypes

      public static Set<TypeIdentifier> getSubTypes(TypeIdentifier rootTypeId, boolean onlyInstantiable, WTContainerRef containerRef) throws WTException
      Get sub-types of a root type.

      Supported API: true
      Parameters:
      rootTypeId - Root TypeIdentifier object.
      onlyInstantiable - True to return only instantiable types, false to return both instantiable and non-instantiable.
      containerRef - Reference to site (ExchangeContainer) or organization (OrgContainer).
      Returns:
      Set of TypeIdentifier objects for all sub-types (guaranteed non-null, may be empty). Will include rootTypeId if it is instantiable or if onlyInstantiable is false.
      Throws:
      WTException
    • getSubTypes

      public static Set<TypeIdentifier> getSubTypes(Collection<TypeIdentifier> rootTypeIds, boolean onlyInstantiable, WTContainerRef containerRef) throws WTException
      Get sub-types of a collection of root types.

      Supported API: true
      Parameters:
      rootTypeId - Collection of root TypeIdentifier objects.
      onlyInstantiable - True to return only instantiable types, false to return both instantiable and non-instantiable.
      containerRef - Reference to site (ExchangeContainer) or organization (OrgContainer).
      Returns:
      Set of TypeIdentifier objects for all sub-types of all rootTypeIds (guaranteed non-null, may be empty). Will include rootTypeIds if they are instantiable or if onlyInstantiable is false.
      Throws:
      WTException
    • getContainerRefFromObject

      public static WTContainerRef getContainerRefFromObject(Object container) throws WTException
      Get organization or site container reference from an object.

      Supported API: true
      Parameters:
      container - WTContained or WTContainerRef object used to derive the association rule's organization or site context.
      Returns:
      Organization reference if object is contained in an organization, PDM or project container, site reference if object is contained directly in the site container or if it could not be determined (guaranteed non-null).
      Throws:
      WTException