*** This class provides Binary Compatibility only, not Source Compatibility ***

Class XMLStream

java.lang.Object
com.sas.services.storedprocess.metadata.DataSourceOrTarget
com.sas.services.storedprocess.metadata.GenericStream
com.sas.services.storedprocess.metadata.XMLStream
All Implemented Interfaces:
Serializable

@SASScope("ALL") @BinaryCompatibilityOnly public class XMLStream extends GenericStream
Design time XMLStream data source or target.
Since:
9.2
See Also:
  • Field Summary

    Fields inherited from class com.sas.services.storedprocess.metadata.DataSourceOrTarget

    _cultureElement, _descElement, _element, _labelElement
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructs and empty XML Stream Data Source or Data Target object with no associated schema.
  • Method Summary

    Modifier and Type
    Method
    Description
    String
    Returns the reference name.
    String
    Returns the reference namespace.
    String
    Returns the schema URI.
    boolean
    Determines whether the reference type is for a schema element or schema type.
    boolean
    The return values determines whether a schema is associated with this XML Stream.
    boolean
    Determines whether the schema is to be embedded of referenced in generated WSDL.
    void
    setIsReferenceTypeForSchemaElement(boolean referenceTypeIsForSchemaElement)
    Sets whether the reference type is for a schema element or schema type.
    void
    setIsSchemaAvailable(boolean schemaIsAvailable)
    Sets whether a schema is be associated with this XML Stream.
    void
    setIsSchemaToBeEmbeddedInWSDL(boolean schemaIsToBeEmbeddedInWSDL)
    Sets whether the schema is to be embedded of referenced in generated WSDL.
    void
    setReferenceName(String referenceName)
    Sets the reference name.
    void
    setReferenceNameSpace(String referenceNameSpace)
    Sets the reference namespace.
    void
    setSchemaURI(String schemaURI)
    Sets the schema URI.
    void
    Validates the XMLStream.

    Methods inherited from class com.sas.services.storedprocess.metadata.GenericStream

    allowsRewinds, getExpectedContentType, getFileref, setAllowRewinds, setExpectedContentType, setFileref

    Methods inherited from class com.sas.services.storedprocess.metadata.DataSourceOrTarget

    getDescription, getLabel, isSource, setDescription, setLabel, setSource

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • XMLStream

      public XMLStream()
      Constructs and empty XML Stream Data Source or Data Target object with no associated schema. By default a data source is returned and the expected content type set to "text/xml"; a data Target can be constructed by calling DataSourceOrTarget.setSource(boolean). Rewinding is only supported for data sources and can be specified via the GenericStream.setAllowRewinds(boolean) method.
  • Method Details

    • isSchemaAvailable

      public boolean isSchemaAvailable()
      The return values determines whether a schema is associated with this XML Stream. If true, schema details can be obtained from getSchemaURI(), getReferenceNameSpace(), getReferenceName() and isReferenceTypeForSchemaElement(). And, isSchemaToBeEmbeddedInWSDL() returns a valid value.
      Returns:
      the availability of a schema
    • setIsSchemaAvailable

      public void setIsSchemaAvailable(boolean schemaIsAvailable)
      Sets whether a schema is be associated with this XML Stream. If set to true, schema details should be set using setSchemaURI(String), setReferenceNameSpace(String), setReferenceName(String) and setIsReferenceTypeForSchemaElement(boolean). And, setIsSchemaToBeEmbeddedInWSDL(boolean) should be called.
    • getSchemaURI

      public String getSchemaURI() throws IllegalStateException
      Returns the schema URI. This method should only be called if isSchemaAvailable() returns true.
      Returns:
      the schema URI
      Throws:
      IllegalStateException - if called when isSchemaAvailable() returns false
    • setSchemaURI

      public void setSchemaURI(String schemaURI)
      Sets the schema URI.
    • getReferenceNameSpace

      public String getReferenceNameSpace()
      Returns the reference namespace. This method should only be called if isSchemaAvailable() returns true.
      Returns:
      the reference namespace
      Throws:
      IllegalStateException - if called when isSchemaAvailable() returns false
    • setReferenceNameSpace

      public void setReferenceNameSpace(String referenceNameSpace)
      Sets the reference namespace.
    • getReferenceName

      public String getReferenceName()
      Returns the reference name. This method should only be called if isSchemaAvailable() returns true.
      Returns:
      the reference name
      Throws:
      IllegalStateException - if called when isSchemaAvailable() returns false
    • setReferenceName

      public void setReferenceName(String referenceName)
      Sets the reference name.
    • isReferenceTypeForSchemaElement

      public boolean isReferenceTypeForSchemaElement()
      Determines whether the reference type is for a schema element or schema type. If true, it is for a schema element; if false for a schema type. This method should only be called if isSchemaAvailable() returns true.
      Returns:
      whether the reference type is for a schema element or schema type
      Throws:
      IllegalStateException - if called when isSchemaAvailable() returns false or the value has not been set
    • setIsReferenceTypeForSchemaElement

      public void setIsReferenceTypeForSchemaElement(boolean referenceTypeIsForSchemaElement)
      Sets whether the reference type is for a schema element or schema type.
      Parameters:
      referenceTypeIsForSchemaElement - if true, it is for a schema element; if false for a schema type.
    • isSchemaToBeEmbeddedInWSDL

      public boolean isSchemaToBeEmbeddedInWSDL()
      Determines whether the schema is to be embedded of referenced in generated WSDL. If true, the schema is embedded; if false, the schema is generated. This method should only be called if isSchemaAvailable() returns true.
      Returns:
      whether the reference type is for a schema element or schema type
      Throws:
      IllegalStateException - if called when isSchemaAvailable() returns false or the value has not been set
    • setIsSchemaToBeEmbeddedInWSDL

      public void setIsSchemaToBeEmbeddedInWSDL(boolean schemaIsToBeEmbeddedInWSDL)
      Sets whether the schema is to be embedded of referenced in generated WSDL.
      Parameters:
      schemaIsToBeEmbeddedInWSDL - if true, the schema is embedded; if false, the schema is generated.
    • validate

      public void validate() throws ServiceException
      Validates the XMLStream. There is no requirement for consumer code to call this method. In addition to what is done by GenericStream.validate(), this method ensures that the various components which describe and involve the schema have been set if isSchemaAvailable() returns true.
      Overrides:
      validate in class GenericStream
      Throws:
      ServiceException - if validation fails