Class PrismSchemaBuildingUtil

java.lang.Object
com.evolveum.midpoint.prism.schema.PrismSchemaBuildingUtil

public class PrismSchemaBuildingUtil extends Object
Methods that help non-standard (lazy?) clients with schema building. Moved here to avoid polluting the standard interfaces.
  • Constructor Details

    • PrismSchemaBuildingUtil

      public PrismSchemaBuildingUtil()
  • Method Details

    • addNewContainerDefinition

      public static PrismContainerDefinition<?> addNewContainerDefinition(@NotNull @NotNull PrismSchema schema, @NotNull @NotNull String localItemName, @NotNull @NotNull String localTypeName)
      Creates a new top-level PrismContainerDefinition and adds it to the schema. It tries to find a ComplexTypeDefinition for the specified type name, and creates (and adds) an empty one if it doesn't exist.
      Parameters:
      localItemName - item (container) name "relative" to schema namespace
      localTypeName - type name "relative" to schema namespace
      Returns:
      new container definition
    • addNewComplexTypeDefinition

      public static ComplexTypeDefinition addNewComplexTypeDefinition(@NotNull @NotNull PrismSchema schema, @NotNull @NotNull String localTypeName)
      Creates and adds a new ComplexTypeDefinition.
    • addNewPropertyDefinition

      @VisibleForTesting public static PrismPropertyDefinition<?> addNewPropertyDefinition(PrismSchema schema, String localItemName, QName typeName)
      Creates a top-level property definition and adds it to the schema. This is a preferred way how to create definition in the schema.
      Parameters:
      localItemName - element name "relative" to schema namespace
      typeName - XSD type name of the element
      Returns:
      new property definition