Examples of CElementInfo


Examples of com.sun.tools.internal.xjc.model.CElementInfo

                    String className = null;
                    if(getGlobalBinding().isGenerateElementClass())
                        className = deriveName(decl);

                    // otherwise map global elements to JAXBElement
                    CElementInfo cei = new CElementInfo(
                        model, tagName, selector.getClassScope(), className, custs, decl.getLocator());
                    selector.boundElements.put(decl,cei);

                    stb.refererStack.push(decl);    // referer is element
                    cei.initContentType( selector.bindToType(decl.getType(),decl), decl, decl.getDefaultValue() );
                    stb.refererStack.pop();
                    r = cei;
                }
            }
        }
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

        }

        if (component instanceof XSElementDecl && !isCollapsable((XSElementDecl)component)) {
            XSElementDecl e = ((XSElementDecl)component);

            CElementInfo cei = new CElementInfo(model, elementName,
                    selector.getClassScope(), clsName,
                    bindInfo.toCustomizationList(), decl.getLocation() );
            selector.boundElements.put(e,cei);

            stb.refererStack.push(component);    // referer is element
            cei.initContentType(
                selector.bindToType(e.getType(),e),
                e,e.getDefaultValue());
            stb.refererStack.pop();
            return cei;
            // TODO: support javadoc and userSpecifiedImplClass
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

                                decl.getLocator(), null, BGMBuilder.getName(decl), decl,
                                custs);
                bean.setBaseClass((CClassInfo)target);
                prop.getElements().add(bean);
            } else {
                CElementInfo e = new CElementInfo(model,BGMBuilder.getName(decl),scope,target,
                        decl.getDefaultValue(), decl, custs, decl.getLocator());
                prop.getElements().add(e);
            }
        }
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

    /**
     * Checks if the given component is bound to a class.
     */
    public final CElement isBound( XSElementDecl x, XSComponent referer ) {
        CElementInfo r = boundElements.get(x);
        if(r!=null)
            return r;
        return bindToType(x,referer);
    }
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

                CElement ref = elements.iterator().next();
                if(ref instanceof ClassInfo) {
                    result.add(createPropertyImpl(rp,ref.getElementName()));
                } else {
                    CElementInfo eref = (CElementInfo)ref;
                    if(!eref.getSubstitutionMembers().isEmpty())
                        return null;    // elements with a substitution group isn't qualified for the wrapper style

                    // JAX-WS doesn't want to see JAXBElement, so we have to hide it for them.
                    ElementAdapter fr;
                    if(rp.isCollection())
                        fr = new ElementCollectionAdapter(parent.outline.getField(rp), eref);
                    else
                        fr = new ElementSingleAdapter(parent.outline.getField(rp), eref);

                    result.add(new PropertyImpl(this,
                        fr, eref.getElementName()));
                }
            } else
                // to be eligible for the wrapper style, only elements are allowed.
                // according to the JAX-RPC spec 2.3.1.2, element refs are disallowed
                return null;
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

            // that I sent to jaxb-tech
            TODO.checkSpec();
        }

        {// collision check
            CElementInfo existing = elementFactoryNames.put(ei.getSqueezedName(),ei);
            if( existing!=null ) {
                outline.getErrorReceiver().error(existing.getLocator(),
                    Messages.OBJECT_FACTORY_CONFLICT.format(ei.getSqueezedName()));
                outline.getErrorReceiver().error(ei.getLocator(),
                    Messages.OBJECT_FACTORY_CONFLICT_RELATED.format());
                return;
            }
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

    /**
     * Checks if the given component is bound to a class.
     */
    public final CElement isBound( XSElementDecl x, XSComponent referer ) {
        CElementInfo r = boundElements.get(x);
        if(r!=null)
            return r;
        return bindToType(x,referer);
    }
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

    }

    /** Returns raw schema name for simpleType property. May return null for other types. */
    public final QName rawName() {
        if (fr instanceof ElementAdapter) {
            CElementInfo eInfo = ((ElementAdapter)fr).ei;
            if ((eInfo != null) && (eInfo.getProperty() != null)) {
                return eInfo.getProperty().getTypes().get(0).getTypeName();
            }
        }
        return null;
    }
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

                CElement ref = elements.iterator().next();
                if (ref instanceof ClassInfo) {
                    result.add(createPropertyImpl(rp, ref.getElementName()));
                } else {
                    CElementInfo eref = (CElementInfo) ref;
                    if (!eref.getSubstitutionMembers().isEmpty()) {
                        return null;    // elements with a substitution group isn't qualified for the wrapper style
                    }
                    // JAX-WS doesn't want to see JAXBElement, so we have to hide it for them.
                    ElementAdapter fr;
                    if (rp.isCollection()) {
                        fr = new ElementCollectionAdapter(parent.outline.getField(rp), eref);
                    } else {
                        fr = new ElementSingleAdapter(parent.outline.getField(rp), eref);
                    }

                    result.add(new PropertyImpl(this,
                            fr, eref.getElementName()));
                }
            } else {// to be eligible for the wrapper style, only elements are allowed.
                    // according to the JAX-RPC spec 2.3.1.2, element refs are disallowed
                return null;
            }
View Full Code Here

Examples of com.sun.tools.internal.xjc.model.CElementInfo

                    String className = null;
                    if(getGlobalBinding().isGenerateElementClass())
                        className = deriveName(decl);

                    // otherwise map global elements to JAXBElement
                    CElementInfo cei = new CElementInfo(
                        model, tagName, selector.getClassScope(), className, custs, decl.getLocator());
                    selector.boundElements.put(decl,cei);

                    stb.refererStack.push(decl);    // referer is element
                    cei.initContentType( selector.bindToType(decl.getType(),decl), decl, decl.getDefaultValue() );
                    stb.refererStack.pop();
                    r = cei;
                }
            }
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.