Class IntegrationObjectRootUtils


  • public final class IntegrationObjectRootUtils
    extends java.lang.Object
    • Method Detail

      • getRootIntegrationObjectItem

        public static IntegrationObjectItemModel getRootIntegrationObjectItem​(IntegrationObjectModel integrationObject)
        Checks if an IntegrationObject has a root IntegrationObjectItem and returns it. Otherwise returns null
        Parameters:
        integrationObject - an IntegrationObjectModel
        Returns:
        the root IntegrationObjectItemModel
      • getRootFromReturnIntegrationObjectItem

        public static IntegrationObjectItemModel getRootFromReturnIntegrationObjectItem​(IntegrationObjectModel integrationObject)
        Old algorithm to determine the root ComposedType from a IntegrationObject's IntegrationObjectItems. The root is the IntegrationObjectItem which has no parent IntegrationObjectItem. Algorithm: every IntegrationObjectItem is also an IntegrationObjectItemAttribute with ReturnIntegrationObjectItem != null, except for the root.
        Parameters:
        integrationObject - an IntegrationObjectModel
        Returns:
        the root IntegrationObjectItemModel
      • correctRoot

        public static IntegrationObjectModel correctRoot​(IntegrationObjectModel integrationObject,
                                                         java.lang.String rootCode)
        Corrects an IntegrationObject's root property which is located at the IntegrationObjectItemModel level. This method will set all other item's root boolean to false, except for the actual root.
        Parameters:
        integrationObject - IntegrationObjectModel to fix
        rootCode - Code of the root item
        Returns:
        The same IntegrationObjectModel with root type property corrected to contain a single valid root
      • resolveIntegrationObjectRoot

        public static IntegrationObjectModel resolveIntegrationObjectRoot​(IntegrationObjectModel integrationObject)
        Uses both the boolean attribute root detector and legacy algorithm in the case of boolean method failure to determine the root of the IntegrationObject.
        Parameters:
        integrationObject - an IntegrationObjectModel
        Returns:
        the IntegrationObjectModel with its root fixed if necessary