Class OpenAPIDSLUtil


  • public class OpenAPIDSLUtil
    extends Object
    • Method Detail

      • getObjectTypeIdFromOperationId

        public static String getObjectTypeIdFromOperationId​(io.swagger.v3.oas.models.OpenAPI api,
                                                            String operationId)
        Given the operationId from the spec, this method retrieves the unique combination of httpMethod and the path associated with it. The custom objectTypeId is a combination of httpMethod and path delimited with #OBJECT_TYPE_ID_DELIMITER
        Returns:
        unique combination of httpMethod and path
      • buildCustomObjectTypeId

        public static String buildCustomObjectTypeId​(String httpMethod,
                                                     String openApiPath)
        Simply concatenates httpMethod and the path values together separated by ":"
        Returns:
        httpMethod:openApiPath
      • getHttpMethodFromCustomObjectTypeId

        public static String getHttpMethodFromCustomObjectTypeId​(String customObjectTypeId)
        Gets the configured HTTP method from the connector action / operation field. Extracts the HTTP method from ObjectTypeId set during browse and accounts for the possibility of multiple #OBJECT_TYPE_ID_DELIMITER in the ObjectTypeId
        Returns:
        the http method
      • getPathFromCustomObjectTypeId

        public static String getPathFromCustomObjectTypeId​(String customObjectTypeId)
        Gets the configured Path to execute upon. Extracts the path from ObjectTypeId set during browse and accounts for the possibility of multiple #OBJECT_TYPE_ID_DELIMITER in the ObjectTypeId
        Returns:
        the path