Package org.eclipse.persistence.oxm.mappings

Examples of org.eclipse.persistence.oxm.mappings.XMLChoiceCollectionMapping.addChoiceElement()


        XMLChoiceCollectionMapping additionalOperationsMapping = new XMLChoiceCollectionMapping();
        additionalOperationsMapping.setAttributeName("additionalOperations");
        additionalOperationsMapping.setContainerPolicy(new ListContainerPolicy(ArrayList.class));
        additionalOperationsMapping.addChoiceElement("procedure", ProcedureOperationModel.class);
        additionalOperationsMapping.addChoiceElement("plsql-procedure", PLSQLProcedureOperationModel.class);
        additionalOperationsMapping.addChoiceElement("sql", SQLOperationModel.class);
        descriptor.addMapping(additionalOperationsMapping);

        return descriptor;
    }
View Full Code Here


        XMLChoiceCollectionMapping additionalOperationsMapping = new XMLChoiceCollectionMapping();
        additionalOperationsMapping.setAttributeName("additionalOperations");
        additionalOperationsMapping.setContainerPolicy(new ListContainerPolicy(ArrayList.class));
        additionalOperationsMapping.addChoiceElement("procedure", ProcedureOperationModel.class);
        additionalOperationsMapping.addChoiceElement("plsql-procedure", PLSQLProcedureOperationModel.class);
        additionalOperationsMapping.addChoiceElement("sql", SQLOperationModel.class);
        descriptor.addMapping(additionalOperationsMapping);

        return descriptor;
    }
View Full Code Here

        descriptor.addMapping(propertiesMapping);

        XMLChoiceCollectionMapping operationsMapping = new XMLChoiceCollectionMapping();
        operationsMapping.setAttributeName("operations");
        operationsMapping.setContainerPolicy(new ListContainerPolicy(ArrayList.class));
        operationsMapping.addChoiceElement("table", TableOperationModel.class);
        operationsMapping.addChoiceElement("procedure", ProcedureOperationModel.class);
        operationsMapping.addChoiceElement("plsql-procedure", PLSQLProcedureOperationModel.class);
        operationsMapping.addChoiceElement("sql", SQLOperationModel.class);
        descriptor.addMapping(operationsMapping);
View Full Code Here

        XMLChoiceCollectionMapping operationsMapping = new XMLChoiceCollectionMapping();
        operationsMapping.setAttributeName("operations");
        operationsMapping.setContainerPolicy(new ListContainerPolicy(ArrayList.class));
        operationsMapping.addChoiceElement("table", TableOperationModel.class);
        operationsMapping.addChoiceElement("procedure", ProcedureOperationModel.class);
        operationsMapping.addChoiceElement("plsql-procedure", PLSQLProcedureOperationModel.class);
        operationsMapping.addChoiceElement("sql", SQLOperationModel.class);
        descriptor.addMapping(operationsMapping);

        return descriptor;
View Full Code Here

        XMLChoiceCollectionMapping operationsMapping = new XMLChoiceCollectionMapping();
        operationsMapping.setAttributeName("operations");
        operationsMapping.setContainerPolicy(new ListContainerPolicy(ArrayList.class));
        operationsMapping.addChoiceElement("table", TableOperationModel.class);
        operationsMapping.addChoiceElement("procedure", ProcedureOperationModel.class);
        operationsMapping.addChoiceElement("plsql-procedure", PLSQLProcedureOperationModel.class);
        operationsMapping.addChoiceElement("sql", SQLOperationModel.class);
        descriptor.addMapping(operationsMapping);

        return descriptor;
    }
View Full Code Here

        operationsMapping.setAttributeName("operations");
        operationsMapping.setContainerPolicy(new ListContainerPolicy(ArrayList.class));
        operationsMapping.addChoiceElement("table", TableOperationModel.class);
        operationsMapping.addChoiceElement("procedure", ProcedureOperationModel.class);
        operationsMapping.addChoiceElement("plsql-procedure", PLSQLProcedureOperationModel.class);
        operationsMapping.addChoiceElement("sql", SQLOperationModel.class);
        descriptor.addMapping(operationsMapping);

        return descriptor;
    }
View Full Code Here

                List<XMLField> tgtFlds = new ArrayList<XMLField>();
                for (XmlJoinNode xmlJoinNode: next.getXmlJoinNodes().getXmlJoinNode()) {
                    srcFlds.add(new XMLField(xmlJoinNode.getXmlPath()));
                    tgtFlds.add(new XMLField(xmlJoinNode.getReferencedXmlPath()));
                }
                mapping.addChoiceElement(srcFlds, type.getQualifiedName(), tgtFlds);
            } else if (isIdRef) {
                // handle IDREF
                String tgtXPath = null;
                TypeInfo referenceType = typeInfo.get(type.getQualifiedName());
                if (null != referenceType && referenceType.isIDSet()) {
View Full Code Here

                if (next.getXmlPath() != null) {
                    srcXPath = new XMLField(next.getXmlPath());
                } else {
                    srcXPath = getXPathForField(next, namespace, true);
                }
                mapping.addChoiceElement(srcXPath.getXPath(), type.getQualifiedName(), tgtXPath);
            } else {
                XMLField xpath;
                if (next.getXmlPath() != null) {
                    xpath = new XMLField(next.getXmlPath());
                } else {
View Full Code Here

                if (next.getXmlPath() != null) {
                    xpath = new XMLField(next.getXmlPath());
                } else {
                    xpath = getXPathForField(next, namespace, !(this.typeInfo.containsKey(type.getQualifiedName())));
                }
                mapping.addChoiceElement(xpath.getName(), type.getQualifiedName());
            }
        }
        return mapping;
    }
View Full Code Here

                xmlField.setSchemaType(XMLConstants.ANY_TYPE_QNAME);
            }
            DatabaseMapping nestedMapping;
            if(isCollection){
                XMLChoiceCollectionMapping xmlChoiceCollectionMapping = (XMLChoiceCollectionMapping) mapping;
                xmlChoiceCollectionMapping.addChoiceElement(xmlField, element.getJavaTypeName());
                nestedMapping = (DatabaseMapping) xmlChoiceCollectionMapping.getChoiceElementMappings().get(xmlField);
                if(nestedMapping.isAbstractCompositeCollectionMapping()){
                    ((XMLCompositeCollectionMapping)nestedMapping).setKeepAsElementPolicy(UnmarshalKeepAsElementPolicy.KEEP_UNKNOWN_AS_ELEMENT);
                }
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.