org.apache.woden.wsdl20

## Interface TypeDefinition

- All Known Subinterfaces:
    EdTypeDefinition

      public interface TypeDefinition

  Represents the TypeDefinition component described in the WSDL 2.0 component model (within the Description Component section of the W3C WSDL 2.0 spec). This component represents global data type definitions such as top-level, named type definitions in W3C XML Schema (e.g. <xs:simpleType> or <xs:complexType>).

  However, it does not mandate W3C XML Schema as the type system. It defines behaviour to query the type system and the underlying content model or API being used to represent the type definitions, and to return a java.lang.Object representing the actual type definition object. Based on the type system and content model, the application must cast this Object to the appropriate type to manipulate its contents.

  Note that while TypeDefinition is described along with the Component model in the W3C WSDL 2.0 specification, it is not a WSDL component itself. It simply provides a way of representing components from the underlying type system within the WSDL Component model.

  Author:
    John Kaputin (jkaputin@apache.org)

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static String` | `API_APACHE_WS_XS` A constant representing the Apache WS-Commons XmlSchema API.
    `static String` | `API_W3C_DOM` A constant representing the DOM API.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `Object` | `getContent()` Returns the underlying type definition as a java.lang.Object, which should be cast to the appropriate type as indicated by the `getContentModel()` method.
    `String` | `getContentModel()` Indicates the type of object model or API which should be used to access the content of the underlying type definition.
    `QName` | `getName()` Representing the {name} property of the TypeDefinition component, this method returns the qualified name of this TypeDefinition.
    `URI` | `getSystem()` Representing the {system} property of the TypeDefinition component, this method indicates the type system from which this type definition is derived.

- - ### Field Detail

    - #### API_W3C_DOM

          static final String API_W3C_DOM

      A constant representing the DOM API. This may be used to indicate the content model of the underlying type definition.
      See Also:
        Constant Field Values

    - #### API_APACHE_WS_XS

          static final String API_APACHE_WS_XS

      A constant representing the Apache WS-Commons XmlSchema API. This may be used to indicate the content model of the underlying type definition.
      See Also:
        Constant Field Values

  - ### Method Detail

    - #### getName

          QName getName()

      Representing the {name} property of the TypeDefinition component, this method returns the qualified name of this TypeDefinition.
      Returns:
        the QName that identifies this TypeDefinition

    - #### getSystem

          URI getSystem()

      Representing the {system} property of the TypeDefinition component, this method indicates the type system from which this type definition is derived. For example, "http://www.w3.org/2001/XMLSchema" indicates the W3C XML Schema type system.
      Returns:
        the URI identifying the type system

    - #### getContentModel

          String getContentModel()

      Indicates the type of object model or API which should be used to access the content of the underlying type definition. This can be used to determine how to cast the Object returned by the `getContent()` method.

      For example:

      - The content model "org.w3c.dom" indicates that the DOM API should be used, so the type org.w3c.dom.Element will be used to represent the content of the type definition.
      - The content model "org.apache.ws.commons.schema" indicates that the WS-Commons XmlSchema API from the Apache WebServices project is used, so an org.apache.ws.commons.schema.XmlSchemaType will be used to represent the content of the type definition.
      Returns:
        a String identifying the type definition's content model

    - #### getContent

          Object getContent()

      Returns the underlying type definition as a java.lang.Object, which should be cast to the appropriate type as indicated by the `getContentModel()` method.
      Returns:
        the Object representing the content of the type definition

Copyright ? Apache Software Foundation. All Rights Reserved.