本文整理了Java中org.apache.ws.commons.schema.XmlSchemaAnnotation
类的一些代码示例,展示了XmlSchemaAnnotation
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XmlSchemaAnnotation
类的具体详情如下:
包路径:org.apache.ws.commons.schema.XmlSchemaAnnotation
类名称:XmlSchemaAnnotation
[英]Defines an annotation. Represents the World Wide Web Consortium (W3C) annotation element.
[中]定义注释。表示万维网联盟(W3C)注释元素。
代码示例来源:origin: com.legsem.legstar/legstar-jaxbgen
annotation = new XmlSchemaAnnotation();
} else {
annotation = element.getAnnotation();
for (Iterator < XmlSchemaObject > i = annotation.getItems()
.getIterator(); i.hasNext();) {
XmlSchemaObject subAnnotation = i.next();
annotation.getItems().add(appInfo);
代码示例来源:origin: org.apache.ws/com.springsource.org.apache.ws.commons.schema
XmlSchemaAnnotation annotation = new XmlSchemaAnnotation();
annotation.items = content;
代码示例来源:origin: com.legsem.legstar/legstar-xsd2cob
/**
* Extracts the cobol annotation from an XML schema element.
*
* @param xsdElement the XML schema element
* @return the COBOL annotation or bull if none found
*/
protected Element getCobolAnnotation(XmlSchemaElement xsdElement) {
XmlSchemaAnnotation annotation = xsdElement.getAnnotation();
if (annotation != null && annotation.getItems().getCount() > 0) {
XmlSchemaAppInfo appinfo = (XmlSchemaAppInfo) annotation.getItems()
.getItem(0);
if (appinfo.getMarkup() != null) {
for (int i = 0; i < appinfo.getMarkup().getLength(); i++) {
Node node = appinfo.getMarkup().item(i);
if (node instanceof Element
&& node.getLocalName().equals(CobolMarkup.ELEMENT)
&& node.getNamespaceURI().equals(CobolMarkup.NS)) {
return (Element) node;
}
}
}
}
return null;
}
代码示例来源:origin: org.apache.ws.commons.schema/XmlSchema
XmlSchemaAnnotation annotation = new XmlSchemaAnnotation();
annotation.items = content;
代码示例来源:origin: com.legsem.legstar/legstar-xsd2cob
/** {@inheritDoc} */
public void processElement(final XmlSchema schema,
final XmlSchemaElement xsdElement, final int level)
throws XsdMappingException {
XmlSchemaAnnotation annotation = xsdElement.getAnnotation();
if (annotation != null && annotation.getItems().getCount() > 0) {
XmlSchemaAppInfo appinfo = (XmlSchemaAppInfo) annotation.getItems()
.getItem(0);
if (appinfo.getMarkup() != null) {
for (int i = 0; i < appinfo.getMarkup().getLength(); i++) {
Node node = appinfo.getMarkup().item(i);
if (node instanceof Element
&& node.getLocalName().equals(CobolMarkup.ELEMENT)
&& node.getNamespaceURI().equals(CobolMarkup.NS)) {
writeElement(schema, xsdElement, _writer,
(Element) node, level);
}
}
}
}
}
代码示例来源:origin: com.legsem.legstar/legstar-xsd2cob
annotation = new XmlSchemaAnnotation();
} else {
annotation = schemaObject.getAnnotation();
for (Iterator < XmlSchemaObject > i = annotation.getItems()
.getIterator(); i.hasNext();) {
XmlSchemaObject subAnnotation = i.next();
annotation.getItems().add(appInfo);
代码示例来源:origin: org.apache.ws.schema/XmlSchema
XmlSchemaAnnotation annotation = new XmlSchemaAnnotation();
annotation.items = content;
代码示例来源:origin: apache/cxf
private boolean isObjectReference(SchemaCollection schemaList, QName name) {
for (XmlSchema schema : schemaList.getXmlSchemas()) {
XmlSchemaElement element = schema.getElementByName(name);
if (element != null) {
XmlSchemaAnnotation annotation = element.getAnnotation();
if (annotation != null) {
List<XmlSchemaAnnotationItem> annotationColl = annotation.getItems();
for (XmlSchemaAnnotationItem item : annotationColl) {
if (item instanceof XmlSchemaAppInfo) {
return true;
}
}
}
}
}
return false;
}
代码示例来源:origin: apache/cxf
XmlSchemaAnnotation annotation = new XmlSchemaAnnotation();
XmlSchemaAppInfo appInfo = new XmlSchemaAppInfo();
try {
annotation.getItems().add(appInfo);
代码示例来源:origin: apache/cxf
for (XmlSchemaAnnotationItem item : annotation.getItems()) {
XmlSchemaAppInfo appInfo = (XmlSchemaAppInfo)item;
if (appInfo != null) {
代码示例来源:origin: apache/cxf
for (XmlSchemaAnnotationItem ann : annotation.getItems()) {
if (ann instanceof XmlSchemaAppInfo) {
appInfo = (XmlSchemaAppInfo)ann;
内容来源于网络,如有侵权,请联系作者删除!