/** * Writes a complex type * * @param simpleType * @param metaInfHolder * @throws SchemaCompilationException */ private void writeSimpleType(XmlSchemaSimpleType simpleType, BeanWriterMetaInfoHolder metaInfHolder) throws SchemaCompilationException { writer.write(simpleType, processedTypemap, processedGroupTypeMap, metaInfHolder); processedTypeMetaInfoMap.put(simpleType.getQName(), metaInfHolder); }
/** * Writes a complex type * * @param simpleType * @param metaInfHolder * @throws SchemaCompilationException */ private void writeSimpleType(XmlSchemaSimpleType simpleType, BeanWriterMetaInfoHolder metaInfHolder) throws SchemaCompilationException { writer.write(simpleType, processedTypemap, processedGroupTypeMap, metaInfHolder); processedTypeMetaInfoMap.put(simpleType.getQName(), metaInfHolder); }
if (simpleType.getQName() != null) { if (processedTypemap.containsKey(simpleType.getQName()) || baseSchemaTypeMap.containsKey(simpleType.getQName())) { return; fullyQualifiedClassName = writer.makeFullyQualifiedClassName(simpleType.getQName()); processedTypemap.put(simpleType.getQName(), fullyQualifiedClassName); } else { metaInfHolder.setSimple(true); if (simpleType.getQName() == null) { this.processedAnonymousComplexTypesMap.put(xsElt, metaInfHolder); QName fakeQname; metaInfHolder.setOwnQname(simpleType.getQName()); if (fullyQualifiedClassName != null) { metaInfHolder.setOwnClassName(fullyQualifiedClassName);
if (simpleType.getQName() != null) { if (processedTypemap.containsKey(simpleType.getQName()) || baseSchemaTypeMap.containsKey(simpleType.getQName())) { return; fullyQualifiedClassName = writer.makeFullyQualifiedClassName(simpleType.getQName()); processedTypemap.put(simpleType.getQName(), fullyQualifiedClassName); } else { metaInfHolder.setSimple(true); if (simpleType.getQName() == null) { this.processedAnonymousComplexTypesMap.put(xsElt, metaInfHolder); QName fakeQname; metaInfHolder.setOwnQname(simpleType.getQName()); if (fullyQualifiedClassName != null) { metaInfHolder.setOwnClassName(fullyQualifiedClassName);
/** * @param simpleType * @param typeMap * @param metainf * @return Returns String. * @throws SchemaCompilationException */ public String write(XmlSchemaSimpleType simpleType, Map<QName,String> typeMap, Map<QName,String> groupTypeMap, BeanWriterMetaInfoHolder metainf) throws SchemaCompilationException { try { QName qName = simpleType.getQName(); if (qName == null) { qName = (QName) simpleType.getMetaInfoMap().get(SchemaConstants.SchemaCompilerInfoHolder.FAKE_QNAME); } metainf.addtStatus(qName, SchemaConstants.SIMPLE_TYPE_OR_CONTENT); return process(qName, metainf, typeMap, groupTypeMap, true, false); } catch (Exception e) { throw new SchemaCompilationException(e); } }
/** * @param simpleType * @param typeMap * @param metainf * @return Returns String. * @throws SchemaCompilationException */ public String write(XmlSchemaSimpleType simpleType, Map<QName,String> typeMap, Map<QName,String> groupTypeMap, BeanWriterMetaInfoHolder metainf) throws SchemaCompilationException { try { QName qName = simpleType.getQName(); if (qName == null) { qName = (QName) simpleType.getMetaInfoMap().get(SchemaConstants.SchemaCompilerInfoHolder.FAKE_QNAME); } metainf.addtStatus(qName, SchemaConstants.SIMPLE_TYPE_OR_CONTENT); return process(qName, metainf, typeMap, groupTypeMap, true, false); } catch (Exception e) { throw new SchemaCompilationException(e); } }
if (content instanceof XmlSchemaSimpleTypeList) { final XmlSchemaSimpleTypeList list = (XmlSchemaSimpleTypeList) content; typeInfo.simpleBaseType = list.getItemType().getQName();
/** * @param simpleType * @param typeMap * @param metainf * @return Returns String. * @throws org.apache.axis2.schema.SchemaCompilationException * */ public String write(XmlSchemaSimpleType simpleType, Map<QName,String> typeMap, Map<QName,String> groupTypeMap, BeanWriterMetaInfoHolder metainf) throws SchemaCompilationException { try { //determine the package for this type. QName qName = simpleType.getQName(); if (qName == null) { qName = (QName) simpleType.getMetaInfoMap().get(SchemaConstants.SchemaCompilerInfoHolder.FAKE_QNAME); } metainf.addtStatus(qName, SchemaConstants.SIMPLE_TYPE_OR_CONTENT); return process(qName, metainf, typeMap, groupTypeMap, true, false); } catch (SchemaCompilationException e) { throw e; } catch (Exception e) { throw new SchemaCompilationException(e); } }
/** * @param simpleType * @param typeMap * @param metainf * @return Returns String. * @throws org.apache.axis2.schema.SchemaCompilationException * */ public String write(XmlSchemaSimpleType simpleType, Map<QName,String> typeMap, Map<QName,String> groupTypeMap, BeanWriterMetaInfoHolder metainf) throws SchemaCompilationException { try { //determine the package for this type. QName qName = simpleType.getQName(); if (qName == null) { qName = (QName) simpleType.getMetaInfoMap().get(SchemaConstants.SchemaCompilerInfoHolder.FAKE_QNAME); } metainf.addtStatus(qName, SchemaConstants.SIMPLE_TYPE_OR_CONTENT); return process(qName, metainf, typeMap, groupTypeMap, true, false); } catch (SchemaCompilationException e) { throw e; } catch (Exception e) { throw new SchemaCompilationException(e); } }
+ xsdSimpleType.getQName());
simpleTypeEl, schemaEl); element.schemaType = simpleType; element.schemaTypeName = simpleType.getQName(); } else if ((complexTypeEl = XDOMUtil.getFirstChildElementNS(el, XmlSchema.SCHEMA_NS, "complexType")) != null) {
private static void processXmlSchemaSimpleType(XmlSchemaSimpleType xmlSchema, JavaMethod jm, JavaParameter parameter, MessagePartInfo part) { if (xmlSchema.getContent() instanceof XmlSchemaSimpleTypeList && (!part.isElement() || !jm.isWrapperStyle())) { parameter.annotate(new XmlListAnotator(jm.getInterface())); } if (Constants.XSD_HEXBIN.equals(xmlSchema.getQName()) && (!part.isElement() || !jm.isWrapperStyle())) { parameter.annotate(new XmlJavaTypeAdapterAnnotator(jm.getInterface(), HexBinaryAdapter.class)); } }
private static void processXmlSchemaSimpleType(XmlSchemaSimpleType xmlSchema, JavaMethod method, MessagePartInfo part) { if (xmlSchema.getContent() instanceof XmlSchemaSimpleTypeList && (!part.isElement() || !method.isWrapperStyle())) { method.annotate(new XmlListAnotator(method.getInterface())); } if (Constants.XSD_HEXBIN.equals(xmlSchema.getQName()) && (!part.isElement() || !method.isWrapperStyle())) { method.annotate(new XmlJavaTypeAdapterAnnotator(method.getInterface(), HexBinaryAdapter.class)); } }
QName typeName = xsdSimpleType.getQName(); if (typeName != null && XsdConstants.XSD_NS.equals(typeName.getNamespaceURI())) {
anonstring.setQName(new QName(typeMap.getTargetNamespace(), stringScopedName.toString())); anonstring.setBound(Long.parseLong(boundNode.toString())); anonstring.setType(simpleType.getQName()); anonwstring.setQName(new QName(typeMap.getTargetNamespace(), stringScopedName.toString())); anonwstring.setBound(Long.parseLong(boundNode.toString())); anonwstring.setType(simpleType.getQName());
List<String> values = XmlSchemaUtils.enumeratorValues(simpleType); code.append("//\n"); code.append("// Simple type (enumeration) " + simpleType.getQName() + "\n"); code.append("//\n"); for (String value : values) {
anonstring.setQName(new QName(typeMap.getTargetNamespace(), anonstringName)); anonstring.setBound(Long.parseLong(boundNode.toString())); anonstring.setType(simpleType.getQName()); anonwstring.setQName(new QName(typeMap.getTargetNamespace(), anonstringName)); anonwstring.setBound(Long.valueOf(boundNode.toString())); anonwstring.setType(simpleType.getQName()); alias.setQName(new QName(typeMap.getTargetNamespace(), stringScopedName.toString())); alias.setBasetype(anon.getQName()); alias.setType(simpleType.getQName()); alias.setRepositoryID(stringScopedName.toIDLRepositoryID());
corbaEnum.setQName(new QName(typeMap.getTargetNamespace(), enumNameScope.toString())); corbaEnum.setRepositoryID(enumNameScope.toIDLRepositoryID()); corbaEnum.setType(enumSchemaSimpleType.getQName());