Class SimpleType

  • All Implemented Interfaces:
    EventListener, IGProp<GProp<?>[]>, IPropCnr, java.lang.Cloneable
    Direct Known Subclasses:
    BuiltInType, EditorSimpleType, ListSimpleType, UnionSimpleType, WildcardElement

    public class SimpleType
    extends SchemaComponent
    The simpleType element defines a simple type and specifies the constraints and information about the values of attributes or text-only elements.

    Parent elements: attribute, element, list, restriction, schema, union.

    Syntax:

     [simpleType
     id=ID
     name=NCName
     any attributes
     ]
    
     (annotation?,(restriction|list|union))
     [/simpleType]
     
    Author:
    Christopher Mindus
    • Constructor Detail

      • SimpleType

        public SimpleType()
        Creates a new unnamed Simple Type schema property.
      • SimpleType

        public SimpleType​(Atom atom)
        Creates a new named Simple Type schema property.
        Parameters:
        atom - The name.
    • Method Detail

      • getBaseType

        public SimpleType getBaseType()
        Gets the base simpleType.
        Returns:
        The base type, or null for none.
      • getPrimitiveType

        public BuiltInType getPrimitiveType()
        Gets the primitive built-in simple type.
        Returns:
        The simple type, or null for tree or schema errors.
      • getFacet

        public Facet getFacet​(java.lang.String facet)
        Gets a facet. Facets are only available for "restricted simple types" and not built-in type, union or list.
        Parameters:
        facet - On of the facet strings as Facet.FACET_*.
        Returns:
        The Facet, or null if not set or unknown.
      • buildMessage

        public void buildMessage​(IMessageBuilder messageBuilder,
                                 javax.xml.soap.SOAPElement parent,
                                 javax.xml.soap.SOAPElement current,
                                 boolean isProduction)
                          throws PropException,
                                 javax.xml.soap.SOAPException
        Builds the SOAP message to send it.
        Specified by:
        buildMessage in class SchemaComponent
        Parameters:
        messageBuilder - The message builder.
        parent - The parent element.
        current - The current element, null if not already created.
        isProduction - Flag indicating the data is "production data" as opposed to sample/template.
        Throws:
        PropException - For build error of a property.
        javax.xml.soap.SOAPException - For SOAP errors.