org.apache.ws.commons.schema.XmlSchemaObject类的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(8.1k)|赞(0)|评价(0)|浏览(104)

本文整理了Java中org.apache.ws.commons.schema.XmlSchemaObject类的一些代码示例,展示了XmlSchemaObject类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XmlSchemaObject类的具体详情如下:
包路径:org.apache.ws.commons.schema.XmlSchemaObject
类名称:XmlSchemaObject

XmlSchemaObject介绍

暂无

代码示例

代码示例来源:origin: org.apache.cxf/cxf-api

  1. public static String cleanedUpSchemaSource(XmlSchemaObject subject) {
  2. if (subject == null || subject.getSourceURI() == null) {
  3. return "";
  4. } else {
  5. return subject.getSourceURI() + ":" + subject.getLineNumber();
  6. }
  7. }
  8. }

代码示例来源:origin: apache/cxf

  1. public void serialize(XmlSchemaObject schemaObject,
  2. @SuppressWarnings("rawtypes") Class classOfType, Node domNode) {
  3. Map<Object, Object> metaInfoMap = schemaObject.getMetaInfoMap();
  4. MimeAttribute mimeType = (MimeAttribute)metaInfoMap.get(MimeAttribute.MIME_QNAME);
  5. Element elt = (Element)domNode;
  6. Attr att1 = elt.getOwnerDocument().createAttributeNS(MimeAttribute.MIME_QNAME.getNamespaceURI(),
  7. MimeAttribute.MIME_QNAME.getLocalPart());
  8. att1.setValue(mimeType.getValue());
  9. elt.setAttributeNodeNS(att1);
  10. }

代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema

  1. Map metaInfoMap = schemaObject.getMetaInfoMap();
  2. if (metaInfoMap==null){
  3. metaInfoMap = new HashMap();
  4. Map metaInfoMapFromSchemaElement = schemaObject.getMetaInfoMap();
  5. if (metaInfoMapFromSchemaElement==null){
  6. schemaObject.setMetaInfoMap(metaInfoMap);
  7. }else{
  8. metaInfoMapFromSchemaElement.putAll(metaInfoMap);

代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema

  1. public String toString(String prefix, int tab) {
  2. String xml = new String();
  3. for (int i = 0; i < getCount(); i++) {
  4. xml += getItem(i).toString(prefix, tab);
  5. }
  6. return xml;
  7. }
  8. }

代码示例来源:origin: org.apache.cxf/cxf-core

  1. public void serialize(XmlSchemaObject schemaObject,
  2. @SuppressWarnings("rawtypes") Class classOfType, Node domNode) {
  3. Map<Object, Object> metaInfoMap = schemaObject.getMetaInfoMap();
  4. MimeAttribute mimeType = (MimeAttribute)metaInfoMap.get(MimeAttribute.MIME_QNAME);
  5. Element elt = (Element)domNode;
  6. Attr att1 = elt.getOwnerDocument().createAttributeNS(MimeAttribute.MIME_QNAME.getNamespaceURI(),
  7. MimeAttribute.MIME_QNAME.getLocalPart());
  8. att1.setValue(mimeType.getValue());
  9. elt.setAttributeNodeNS(att1);
  10. }

代码示例来源:origin: org.apache.ws.schema/XmlSchema

  1. Map metaInfoMap = schemaObject.getMetaInfoMap();
  2. if (metaInfoMap==null){
  3. metaInfoMap = new HashMap();
  4. Map metaInfoMapFromSchemaElement = schemaObject.getMetaInfoMap();
  5. if (metaInfoMapFromSchemaElement==null){
  6. schemaObject.setMetaInfoMap(metaInfoMap);
  7. }else{
  8. metaInfoMapFromSchemaElement.putAll(metaInfoMap);

代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema

  1. public String toString(String prefix, int tab) {
  2. String xml = new String();
  3. for (int i = 0; i < getCount(); i++) {
  4. xml += getItem(i).toString(prefix, tab);
  5. }
  6. return xml;
  7. }
  8. }

代码示例来源:origin: org.apache.cxf/cxf-rt-core

  1. public void serialize(XmlSchemaObject schemaObject,
  2. @SuppressWarnings("rawtypes") Class classOfType, Node domNode) {
  3. Map<Object, Object> metaInfoMap = schemaObject.getMetaInfoMap();
  4. MimeAttribute mimeType = (MimeAttribute)metaInfoMap.get(MimeAttribute.MIME_QNAME);
  5. Element elt = (Element)domNode;
  6. Attr att1 = elt.getOwnerDocument().createAttributeNS(MimeAttribute.MIME_QNAME.getNamespaceURI(),
  7. MimeAttribute.MIME_QNAME.getLocalPart());
  8. att1.setValue(mimeType.getValue());
  9. elt.setAttributeNodeNS(att1);
  10. }

代码示例来源:origin: org.apache.cxf/cxf-bundle-jaxrs

  1. public static String cleanedUpSchemaSource(XmlSchemaObject subject) {
  2. if (subject == null || subject.getSourceURI() == null) {
  3. return "";
  4. } else {
  5. return subject.getSourceURI() + ":" + subject.getLineNumber();
  6. }
  7. }
  8. }

代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema

  1. Map metaInfoMapFromSchemaElement = schemaObject.getMetaInfoMap();
  2. if (metaInfoMapFromSchemaElement==null){
  3. schemaObject.setMetaInfoMap(metaInfoMap);
  4. }else{
  5. metaInfoMapFromSchemaElement.putAll(metaInfoMap);

代码示例来源:origin: org.apache.ws.schema/XmlSchema

  1. public String toString(String prefix, int tab) {
  2. String xml = new String();
  3. for (int i = 0; i < getCount(); i++) {
  4. xml += getItem(i).toString(prefix, tab);
  5. }
  6. return xml;
  7. }
  8. }

代码示例来源:origin: org.apache.cxf/cxf-bundle-jaxrs

  1. public void serialize(XmlSchemaObject schemaObject,
  2. @SuppressWarnings("rawtypes") Class classOfType, Node domNode) {
  3. Map<Object, Object> metaInfoMap = schemaObject.getMetaInfoMap();
  4. MimeAttribute mimeType = (MimeAttribute)metaInfoMap.get(MimeAttribute.MIME_QNAME);
  5. Element elt = (Element)domNode;
  6. Attr att1 = elt.getOwnerDocument().createAttributeNS(MimeAttribute.MIME_QNAME.getNamespaceURI(),
  7. MimeAttribute.MIME_QNAME.getLocalPart());
  8. att1.setValue(mimeType.getValue());
  9. elt.setAttributeNodeNS(att1);
  10. }

代码示例来源:origin: apache/cxf

  1. static String cleanedUpSchemaSource(XmlSchemaObject subject) {
  2. if (subject == null || subject.getSourceURI() == null) {
  3. return "";
  4. }
  5. return subject.getSourceURI() + ":" + subject.getLineNumber();
  6. }
  7. }

代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema

  1. public String toString(String prefix, int tab) {
  2. String xml = new String();
  3. for (int i = 0; i < tab; i++)
  4. xml += "\t";
  5. if (!prefix.equals("") && prefix.indexOf(":") == -1)
  6. prefix += ":";
  7. xml += "<" + prefix + "sequence>\n";
  8. for (int i = 0; i < items.getCount(); i++) {
  9. xml += items.getItem(i).toString(prefix, (tab + 1));
  10. }
  11. for (int i = 0; i < tab; i++)
  12. xml += "\t";
  13. xml += "</" + prefix + "sequence>\n";
  14. return xml;
  15. }
  16. }

代码示例来源:origin: org.apache.ws.schema/XmlSchema

  1. /**
  2. * A generic method to process the extra attributes and the extra
  3. * elements present within the schema.
  4. * What are considered extensions are child elements with non schema namespace
  5. * and child attributes with any namespace.
  6. * @param schemaObject
  7. * @param parentElement
  8. */
  9. private void processExtensibilityComponents(XmlSchemaObject schemaObject, Element parentElement) {
  10. if (extReg!=null){
  11. Map metaInfoMap = schemaObject.getMetaInfoMap();
  12. if (metaInfoMap!=null && !metaInfoMap.isEmpty()) {
  13. //get the extra objects and call the respective deserializers
  14. Iterator keysIt = metaInfoMap.keySet().iterator();
  15. while (keysIt.hasNext()) {
  16. Object key = keysIt.next();
  17. extReg.serializeExtension(schemaObject,metaInfoMap.get(key).getClass(),parentElement);
  18. }
  19. }
  20. }
  21. }

代码示例来源:origin: apache/cxf

  1. public static String cleanedUpSchemaSource(XmlSchemaObject subject) {
  2. if (subject == null || subject.getSourceURI() == null) {
  3. return "";
  4. }
  5. return subject.getSourceURI() + ":" + subject.getLineNumber();
  6. }

代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema

  1. public String toString(String prefix, int tab) {
  2. String xml = new String();
  3. for (int i = 0; i < tab; i++)
  4. xml += "\t";
  5. if (!prefix.equals("") && prefix.indexOf(":") == -1)
  6. prefix += ":";
  7. xml += "<" + prefix + "sequence>\n";
  8. for (int i = 0; i < items.getCount(); i++) {
  9. xml += items.getItem(i).toString(prefix, (tab + 1));
  10. }
  11. for (int i = 0; i < tab; i++)
  12. xml += "\t";
  13. xml += "</" + prefix + "sequence>\n";
  14. return xml;
  15. }
  16. }

代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema

  1. /**
  2. * A generic method to process the extra attributes and the extra
  3. * elements present within the schema.
  4. * What are considered extensions are child elements with non schema namespace
  5. * and child attributes with any namespace.
  6. * @param schemaObject
  7. * @param parentElement
  8. */
  9. private void processExtensibilityComponents(XmlSchemaObject schemaObject, Element parentElement) {
  10. if (extReg!=null){
  11. Map metaInfoMap = schemaObject.getMetaInfoMap();
  12. if (metaInfoMap!=null && !metaInfoMap.isEmpty()) {
  13. //get the extra objects and call the respective deserializers
  14. Iterator keysIt = metaInfoMap.keySet().iterator();
  15. while (keysIt.hasNext()) {
  16. Object key = keysIt.next();
  17. extReg.serializeExtension(schemaObject,metaInfoMap.get(key).getClass(),parentElement);
  18. }
  19. }
  20. }
  21. }

代码示例来源:origin: org.apache.cxf/cxf-common-utilities

  1. public static String cleanedUpSchemaSource(XmlSchemaObject subject) {
  2. if (subject == null || subject.getSourceURI() == null) {
  3. return "";
  4. } else {
  5. return subject.getSourceURI() + ":" + subject.getLineNumber();
  6. }
  7. }
  8. }

代码示例来源:origin: org.apache.ws.schema/XmlSchema

  1. public String toString(String prefix, int tab) {
  2. String xml = new String();
  3. for (int i = 0; i < tab; i++)
  4. xml += "\t";
  5. if (!prefix.equals("") && prefix.indexOf(":") == -1)
  6. prefix += ":";
  7. xml += "<" + prefix + "sequence>\n";
  8. for (int i = 0; i < items.getCount(); i++) {
  9. xml += items.getItem(i).toString(prefix, (tab + 1));
  10. }
  11. for (int i = 0; i < tab; i++)
  12. xml += "\t";
  13. xml += "</" + prefix + "sequence>\n";
  14. return xml;
  15. }
  16. }

相关文章