本文整理了Java中org.apache.ws.commons.schema.XmlSchemaObject
类的一些代码示例,展示了XmlSchemaObject
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XmlSchemaObject
类的具体详情如下:
包路径:org.apache.ws.commons.schema.XmlSchemaObject
类名称:XmlSchemaObject
暂无
代码示例来源:origin: org.apache.cxf/cxf-api
public static String cleanedUpSchemaSource(XmlSchemaObject subject) {
if (subject == null || subject.getSourceURI() == null) {
return "";
} else {
return subject.getSourceURI() + ":" + subject.getLineNumber();
}
}
}
代码示例来源:origin: apache/cxf
public void serialize(XmlSchemaObject schemaObject,
@SuppressWarnings("rawtypes") Class classOfType, Node domNode) {
Map<Object, Object> metaInfoMap = schemaObject.getMetaInfoMap();
MimeAttribute mimeType = (MimeAttribute)metaInfoMap.get(MimeAttribute.MIME_QNAME);
Element elt = (Element)domNode;
Attr att1 = elt.getOwnerDocument().createAttributeNS(MimeAttribute.MIME_QNAME.getNamespaceURI(),
MimeAttribute.MIME_QNAME.getLocalPart());
att1.setValue(mimeType.getValue());
elt.setAttributeNodeNS(att1);
}
代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema
Map metaInfoMap = schemaObject.getMetaInfoMap();
if (metaInfoMap==null){
metaInfoMap = new HashMap();
Map metaInfoMapFromSchemaElement = schemaObject.getMetaInfoMap();
if (metaInfoMapFromSchemaElement==null){
schemaObject.setMetaInfoMap(metaInfoMap);
}else{
metaInfoMapFromSchemaElement.putAll(metaInfoMap);
代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema
public String toString(String prefix, int tab) {
String xml = new String();
for (int i = 0; i < getCount(); i++) {
xml += getItem(i).toString(prefix, tab);
}
return xml;
}
}
代码示例来源:origin: org.apache.cxf/cxf-core
public void serialize(XmlSchemaObject schemaObject,
@SuppressWarnings("rawtypes") Class classOfType, Node domNode) {
Map<Object, Object> metaInfoMap = schemaObject.getMetaInfoMap();
MimeAttribute mimeType = (MimeAttribute)metaInfoMap.get(MimeAttribute.MIME_QNAME);
Element elt = (Element)domNode;
Attr att1 = elt.getOwnerDocument().createAttributeNS(MimeAttribute.MIME_QNAME.getNamespaceURI(),
MimeAttribute.MIME_QNAME.getLocalPart());
att1.setValue(mimeType.getValue());
elt.setAttributeNodeNS(att1);
}
代码示例来源:origin: org.apache.ws.schema/XmlSchema
Map metaInfoMap = schemaObject.getMetaInfoMap();
if (metaInfoMap==null){
metaInfoMap = new HashMap();
Map metaInfoMapFromSchemaElement = schemaObject.getMetaInfoMap();
if (metaInfoMapFromSchemaElement==null){
schemaObject.setMetaInfoMap(metaInfoMap);
}else{
metaInfoMapFromSchemaElement.putAll(metaInfoMap);
代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema
public String toString(String prefix, int tab) {
String xml = new String();
for (int i = 0; i < getCount(); i++) {
xml += getItem(i).toString(prefix, tab);
}
return xml;
}
}
代码示例来源:origin: org.apache.cxf/cxf-rt-core
public void serialize(XmlSchemaObject schemaObject,
@SuppressWarnings("rawtypes") Class classOfType, Node domNode) {
Map<Object, Object> metaInfoMap = schemaObject.getMetaInfoMap();
MimeAttribute mimeType = (MimeAttribute)metaInfoMap.get(MimeAttribute.MIME_QNAME);
Element elt = (Element)domNode;
Attr att1 = elt.getOwnerDocument().createAttributeNS(MimeAttribute.MIME_QNAME.getNamespaceURI(),
MimeAttribute.MIME_QNAME.getLocalPart());
att1.setValue(mimeType.getValue());
elt.setAttributeNodeNS(att1);
}
代码示例来源:origin: org.apache.cxf/cxf-bundle-jaxrs
public static String cleanedUpSchemaSource(XmlSchemaObject subject) {
if (subject == null || subject.getSourceURI() == null) {
return "";
} else {
return subject.getSourceURI() + ":" + subject.getLineNumber();
}
}
}
代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema
Map metaInfoMapFromSchemaElement = schemaObject.getMetaInfoMap();
if (metaInfoMapFromSchemaElement==null){
schemaObject.setMetaInfoMap(metaInfoMap);
}else{
metaInfoMapFromSchemaElement.putAll(metaInfoMap);
代码示例来源:origin: org.apache.ws.schema/XmlSchema
public String toString(String prefix, int tab) {
String xml = new String();
for (int i = 0; i < getCount(); i++) {
xml += getItem(i).toString(prefix, tab);
}
return xml;
}
}
代码示例来源:origin: org.apache.cxf/cxf-bundle-jaxrs
public void serialize(XmlSchemaObject schemaObject,
@SuppressWarnings("rawtypes") Class classOfType, Node domNode) {
Map<Object, Object> metaInfoMap = schemaObject.getMetaInfoMap();
MimeAttribute mimeType = (MimeAttribute)metaInfoMap.get(MimeAttribute.MIME_QNAME);
Element elt = (Element)domNode;
Attr att1 = elt.getOwnerDocument().createAttributeNS(MimeAttribute.MIME_QNAME.getNamespaceURI(),
MimeAttribute.MIME_QNAME.getLocalPart());
att1.setValue(mimeType.getValue());
elt.setAttributeNodeNS(att1);
}
代码示例来源:origin: apache/cxf
static String cleanedUpSchemaSource(XmlSchemaObject subject) {
if (subject == null || subject.getSourceURI() == null) {
return "";
}
return subject.getSourceURI() + ":" + subject.getLineNumber();
}
}
代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema
public String toString(String prefix, int tab) {
String xml = new String();
for (int i = 0; i < tab; i++)
xml += "\t";
if (!prefix.equals("") && prefix.indexOf(":") == -1)
prefix += ":";
xml += "<" + prefix + "sequence>\n";
for (int i = 0; i < items.getCount(); i++) {
xml += items.getItem(i).toString(prefix, (tab + 1));
}
for (int i = 0; i < tab; i++)
xml += "\t";
xml += "</" + prefix + "sequence>\n";
return xml;
}
}
代码示例来源:origin: org.apache.ws.schema/XmlSchema
/**
* A generic method to process the extra attributes and the extra
* elements present within the schema.
* What are considered extensions are child elements with non schema namespace
* and child attributes with any namespace.
* @param schemaObject
* @param parentElement
*/
private void processExtensibilityComponents(XmlSchemaObject schemaObject, Element parentElement) {
if (extReg!=null){
Map metaInfoMap = schemaObject.getMetaInfoMap();
if (metaInfoMap!=null && !metaInfoMap.isEmpty()) {
//get the extra objects and call the respective deserializers
Iterator keysIt = metaInfoMap.keySet().iterator();
while (keysIt.hasNext()) {
Object key = keysIt.next();
extReg.serializeExtension(schemaObject,metaInfoMap.get(key).getClass(),parentElement);
}
}
}
}
代码示例来源:origin: apache/cxf
public static String cleanedUpSchemaSource(XmlSchemaObject subject) {
if (subject == null || subject.getSourceURI() == null) {
return "";
}
return subject.getSourceURI() + ":" + subject.getLineNumber();
}
代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema
public String toString(String prefix, int tab) {
String xml = new String();
for (int i = 0; i < tab; i++)
xml += "\t";
if (!prefix.equals("") && prefix.indexOf(":") == -1)
prefix += ":";
xml += "<" + prefix + "sequence>\n";
for (int i = 0; i < items.getCount(); i++) {
xml += items.getItem(i).toString(prefix, (tab + 1));
}
for (int i = 0; i < tab; i++)
xml += "\t";
xml += "</" + prefix + "sequence>\n";
return xml;
}
}
代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema
/**
* A generic method to process the extra attributes and the extra
* elements present within the schema.
* What are considered extensions are child elements with non schema namespace
* and child attributes with any namespace.
* @param schemaObject
* @param parentElement
*/
private void processExtensibilityComponents(XmlSchemaObject schemaObject, Element parentElement) {
if (extReg!=null){
Map metaInfoMap = schemaObject.getMetaInfoMap();
if (metaInfoMap!=null && !metaInfoMap.isEmpty()) {
//get the extra objects and call the respective deserializers
Iterator keysIt = metaInfoMap.keySet().iterator();
while (keysIt.hasNext()) {
Object key = keysIt.next();
extReg.serializeExtension(schemaObject,metaInfoMap.get(key).getClass(),parentElement);
}
}
}
}
代码示例来源:origin: org.apache.cxf/cxf-common-utilities
public static String cleanedUpSchemaSource(XmlSchemaObject subject) {
if (subject == null || subject.getSourceURI() == null) {
return "";
} else {
return subject.getSourceURI() + ":" + subject.getLineNumber();
}
}
}
代码示例来源:origin: org.apache.ws.schema/XmlSchema
public String toString(String prefix, int tab) {
String xml = new String();
for (int i = 0; i < tab; i++)
xml += "\t";
if (!prefix.equals("") && prefix.indexOf(":") == -1)
prefix += ":";
xml += "<" + prefix + "sequence>\n";
for (int i = 0; i < items.getCount(); i++) {
xml += items.getItem(i).toString(prefix, (tab + 1));
}
for (int i = 0; i < tab; i++)
xml += "\t";
xml += "</" + prefix + "sequence>\n";
return xml;
}
}
内容来源于网络,如有侵权,请联系作者删除!