本文整理了Java中org.eclipse.xsd.XSDTypeDefinition.getAnnotation()
方法的一些代码示例,展示了XSDTypeDefinition.getAnnotation()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XSDTypeDefinition.getAnnotation()
方法的具体详情如下:
包路径:org.eclipse.xsd.XSDTypeDefinition
类名称:XSDTypeDefinition
方法名:getAnnotation
[英]Returns the value of the 'Annotation' containment reference.
This concrete reference represents the direct annotation content of a complexType element or a simpleType element.
[中]返回“注释”包含引用的值。
这个具体的引用表示complexType元素或{$1$}元素的直接注释内容。
代码示例来源:origin: org.eclipse.xsd/org.eclipse.xsd
void handleTypeArguments(XSDTypeDefinition xsdTypeDefinition, EClassifier eClassifier)
{
XSDAnnotation xsdAnnotation = xsdTypeDefinition.getAnnotation();
if (xsdAnnotation != null)
{
List<Element> applicationInformationList = xsdAnnotation.getApplicationInformation(EcorePackage.eNS_URI);
for (Element applicationInformation : applicationInformationList)
{
if ("typeParameters".equals(applicationInformation.getAttributeNS(EcorePackage.eNS_URI, "key")))
{
for (Element typeParameter : getElements(applicationInformation, "typeParameter"))
{
ETypeParameter eTypeParameter = EcoreFactory.eINSTANCE.createETypeParameter();
String typeParameterName = typeParameter.getAttributeNS(null, "name");
eTypeParameter.setName(typeParameterName);
eClassifier.getETypeParameters().add(eTypeParameter);
eTypeParameter.getEBounds().addAll(getGenericTypes(xsdTypeDefinition, typeParameter, eClassifier, typeParameter.getAttributeNS(null, "bounds")));
}
}
}
}
}
代码示例来源:origin: org.eclipse/org.eclipse.xsd
void handleTypeArguments(XSDTypeDefinition xsdTypeDefinition, EClassifier eClassifier)
{
XSDAnnotation xsdAnnotation = xsdTypeDefinition.getAnnotation();
if (xsdAnnotation != null)
{
List<Element> applicationInformationList = xsdAnnotation.getApplicationInformation(EcorePackage.eNS_URI);
for (Element applicationInformation : applicationInformationList)
{
if ("typeParameters".equals(applicationInformation.getAttributeNS(EcorePackage.eNS_URI, "key")))
{
for (Element typeParameter : getElements(applicationInformation, "typeParameter"))
{
ETypeParameter eTypeParameter = EcoreFactory.eINSTANCE.createETypeParameter();
String typeParameterName = typeParameter.getAttributeNS(null, "name");
eTypeParameter.setName(typeParameterName);
eClassifier.getETypeParameters().add(eTypeParameter);
eTypeParameter.getEBounds().addAll(getGenericTypes(xsdTypeDefinition, typeParameter, eClassifier, typeParameter.getAttributeNS(null, "bounds")));
}
}
}
}
}
代码示例来源:origin: org.eclipse.xsd/org.eclipse.xsd
if ((xsdAnnotation = xsdTypeDefinition.getAnnotation()) == null)
代码示例来源:origin: org.eclipse/org.eclipse.xsd
if ((xsdAnnotation = xsdTypeDefinition.getAnnotation()) == null)
代码示例来源:origin: org.eclipse/org.eclipse.wst.xsd.ui
xsdAnnotation = xsdComp.getAnnotation();
if (createIfNotExist && xsdAnnotation == null)
内容来源于网络,如有侵权,请联系作者删除!