Java Code Examples for com.sun.xml.internal.bind.v2.model.core.NonElement#getType()

The following examples show how to use com.sun.xml.internal.bind.v2.model.core.NonElement#getType() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: XmlSchemaGenerator.java    From TencentKona-8 with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Adds an additional element declaration.
 *
 * @param tagName
 *      The name of the element declaration to be added.
 * @param type
 *      The type this element refers to.
 *      Can be null, in which case the element refers to an empty anonymous complex type.
 */
public void add( QName tagName, boolean isNillable, NonElement<T,C> type ) {

    if(type!=null && type.getType()==navigator.ref(CompositeStructure.class))
        return; // this is a special class we introduced for JAX-WS that we *don't* want in the schema


    Namespace n = getNamespace(tagName.getNamespaceURI());
    n.elementDecls.put(tagName.getLocalPart(), n.new ElementWithType(isNillable,type));

    // search for foreign namespace references
    if(type!=null)
        n.addDependencyTo(type.getTypeName());
}
 
Example 2
Source File: XmlSchemaGenerator.java    From jdk8u60 with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Adds an additional element declaration.
 *
 * @param tagName
 *      The name of the element declaration to be added.
 * @param type
 *      The type this element refers to.
 *      Can be null, in which case the element refers to an empty anonymous complex type.
 */
public void add( QName tagName, boolean isNillable, NonElement<T,C> type ) {

    if(type!=null && type.getType()==navigator.ref(CompositeStructure.class))
        return; // this is a special class we introduced for JAX-WS that we *don't* want in the schema


    Namespace n = getNamespace(tagName.getNamespaceURI());
    n.elementDecls.put(tagName.getLocalPart(), n.new ElementWithType(isNillable,type));

    // search for foreign namespace references
    if(type!=null)
        n.addDependencyTo(type.getTypeName());
}
 
Example 3
Source File: XmlSchemaGenerator.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Adds an additional element declaration.
 *
 * @param tagName
 *      The name of the element declaration to be added.
 * @param type
 *      The type this element refers to.
 *      Can be null, in which case the element refers to an empty anonymous complex type.
 */
public void add( QName tagName, boolean isNillable, NonElement<T,C> type ) {

    if(type!=null && type.getType()==navigator.ref(CompositeStructure.class))
        return; // this is a special class we introduced for JAX-WS that we *don't* want in the schema


    Namespace n = getNamespace(tagName.getNamespaceURI());
    n.elementDecls.put(tagName.getLocalPart(), n.new ElementWithType(isNillable,type));

    // search for foreign namespace references
    if(type!=null)
        n.addDependencyTo(type.getTypeName());
}
 
Example 4
Source File: XmlSchemaGenerator.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Adds an additional element declaration.
 *
 * @param tagName
 *      The name of the element declaration to be added.
 * @param type
 *      The type this element refers to.
 *      Can be null, in which case the element refers to an empty anonymous complex type.
 */
public void add( QName tagName, boolean isNillable, NonElement<T,C> type ) {

    if(type!=null && type.getType()==navigator.ref(CompositeStructure.class))
        return; // this is a special class we introduced for JAX-WS that we *don't* want in the schema


    Namespace n = getNamespace(tagName.getNamespaceURI());
    n.elementDecls.put(tagName.getLocalPart(), n.new ElementWithType(isNillable,type));

    // search for foreign namespace references
    if(type!=null)
        n.addDependencyTo(type.getTypeName());
}
 
Example 5
Source File: XmlSchemaGenerator.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Adds an additional element declaration.
 *
 * @param tagName
 *      The name of the element declaration to be added.
 * @param type
 *      The type this element refers to.
 *      Can be null, in which case the element refers to an empty anonymous complex type.
 */
public void add( QName tagName, boolean isNillable, NonElement<T,C> type ) {

    if(type!=null && type.getType()==navigator.ref(CompositeStructure.class))
        return; // this is a special class we introduced for JAX-WS that we *don't* want in the schema


    Namespace n = getNamespace(tagName.getNamespaceURI());
    n.elementDecls.put(tagName.getLocalPart(), n.new ElementWithType(isNillable,type));

    // search for foreign namespace references
    if(type!=null)
        n.addDependencyTo(type.getTypeName());
}
 
Example 6
Source File: XmlSchemaGenerator.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Adds an additional element declaration.
 *
 * @param tagName
 *      The name of the element declaration to be added.
 * @param type
 *      The type this element refers to.
 *      Can be null, in which case the element refers to an empty anonymous complex type.
 */
public void add( QName tagName, boolean isNillable, NonElement<T,C> type ) {

    if(type!=null && type.getType()==navigator.ref(CompositeStructure.class))
        return; // this is a special class we introduced for JAX-WS that we *don't* want in the schema


    Namespace n = getNamespace(tagName.getNamespaceURI());
    n.elementDecls.put(tagName.getLocalPart(), n.new ElementWithType(isNillable,type));

    // search for foreign namespace references
    if(type!=null)
        n.addDependencyTo(type.getTypeName());
}
 
Example 7
Source File: XmlSchemaGenerator.java    From openjdk-8-source with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Adds an additional element declaration.
 *
 * @param tagName
 *      The name of the element declaration to be added.
 * @param type
 *      The type this element refers to.
 *      Can be null, in which case the element refers to an empty anonymous complex type.
 */
public void add( QName tagName, boolean isNillable, NonElement<T,C> type ) {

    if(type!=null && type.getType()==navigator.ref(CompositeStructure.class))
        return; // this is a special class we introduced for JAX-WS that we *don't* want in the schema


    Namespace n = getNamespace(tagName.getNamespaceURI());
    n.elementDecls.put(tagName.getLocalPart(), n.new ElementWithType(isNillable,type));

    // search for foreign namespace references
    if(type!=null)
        n.addDependencyTo(type.getTypeName());
}
 
Example 8
Source File: XmlSchemaGenerator.java    From openjdk-8 with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Adds an additional element declaration.
 *
 * @param tagName
 *      The name of the element declaration to be added.
 * @param type
 *      The type this element refers to.
 *      Can be null, in which case the element refers to an empty anonymous complex type.
 */
public void add( QName tagName, boolean isNillable, NonElement<T,C> type ) {

    if(type!=null && type.getType()==navigator.ref(CompositeStructure.class))
        return; // this is a special class we introduced for JAX-WS that we *don't* want in the schema


    Namespace n = getNamespace(tagName.getNamespaceURI());
    n.elementDecls.put(tagName.getLocalPart(), n.new ElementWithType(isNillable,type));

    // search for foreign namespace references
    if(type!=null)
        n.addDependencyTo(type.getTypeName());
}