本文整理了Java中org.eclipse.xsd.XSDElementDeclaration.getTypeDefinition()
方法的一些代码示例,展示了XSDElementDeclaration.getTypeDefinition()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XSDElementDeclaration.getTypeDefinition()
方法的具体详情如下:
包路径:org.eclipse.xsd.XSDElementDeclaration
类名称:XSDElementDeclaration
方法名:getTypeDefinition
[英]Returns the value of the 'Type Definition' reference.
This represents the type definition infoset property.
[中]返回“类型定义”引用的值。
这表示type definitioninfoset属性。
代码示例来源:origin: geoserver/geoserver
XSDElementDeclaration element = (XSDElementDeclaration) e.next();
if (ft.getName().equals(element.getName())) {
type = element.getTypeDefinition();
break;
代码示例来源:origin: geotools/geotools
public XSDTypeDefinition getTypeDefinition() {
return declaration.getTypeDefinition();
}
代码示例来源:origin: geotools/geotools
type = ((XSDElementDeclaration)named).getTypeDefinition();
desc = "element";
代码示例来源:origin: geotools/geotools
type = e.getTypeDefinition();
代码示例来源:origin: geotools/geotools
XSDTypeDefinition contentType = content.getTypeDefinition();
if (contentType.getName() == null) {
代码示例来源:origin: geotools/geotools
/**
* Uses EMF reflection to create an instance of the EMF model object this binding maps to.
*
* <p>The properties of the resulting object are set using the the contents of
* <param>node</param>. In the case that the name of a child element or attributes does not
* match the name of a property on the object, subclasses may wish to extend this method and set
* the property explicitly.
*/
public Object parse(ElementInstance instance, Node node, Object value) throws Exception {
// does this binding actually map to an eObject?
if (EObject.class.isAssignableFrom(getType()) && (factory != null)) {
EObject eObject = createEObject(value);
if (eObject == null) {
return value;
}
setProperties(eObject, node, false);
setProperties(eObject, node, true);
// check for a complex type with simpleContent, in this case use
// the string value (if any) to set the value property
if (instance.getElementDeclaration().getTypeDefinition().getBaseType()
instanceof XSDTypeDefinition) {
if ((value != null) && EMFUtils.has(eObject, "value")) {
setProperty(eObject, "value", value, false);
}
}
return eObject;
}
// could not do it, just return whatever was passed in
return value;
}
代码示例来源:origin: geotools/geotools
Schemas.getChildElementParticles(element.getTypeDefinition(), true)) {
XSDElementDeclaration childElement = (XSDElementDeclaration) childParticle.getContent();
if (childElement.isElementDeclarationReference()) {
代码示例来源:origin: geotools/geotools
type = e.getTypeDefinition();
.get(XSDElementDeclaration.class);
if (e != null) {
type = e.getTypeDefinition();
} else if (element != null) {
XSDTypeDefinition elementTypeDef = element.getTypeDefinition();
QName qualifiedElementTypeName =
new QName(
代码示例来源:origin: geotools/geotools
XSDTypeDefinition childType = element.getTypeDefinition();
if (childType == null) {
childType = findGlobalElementXSDType(element);
代码示例来源:origin: geotools/geotools
XSDSchema dctSchema = DCT.getInstance().getSchema();
XSDElementDeclaration declaration = dctSchema.resolveElementDeclaration(sl.getName());
if (declaration.getTypeDefinition() == null) {
XSDSchema dcSchema = DC.getInstance().getSchema();
declaration = dcSchema.resolveElementDeclaration(sl.getName());
代码示例来源:origin: geotools/geotools
XSDTypeDefinition typeDef = element.getTypeDefinition();
boolean isAnyType =
typeDef.getName() != null
for (XSDParticle childParticle :
(List<XSDParticle>)
Schemas.getChildElementParticles(element.getTypeDefinition(), true)) {
XSDElementDeclaration childElement =
(XSDElementDeclaration) childParticle.getContent();
Schemas.getAnyElementParticles(element.getTypeDefinition()));
if (anyElementParticles.size() > 0) {
Collection complexAtts = null;
new ArrayList<XSDParticle>(
Schemas.getChildElementParticles(
element.getTypeDefinition(), false));
for (Object complex : complexAtts) {
if (complex instanceof ComplexAttribute) {
代码示例来源:origin: geotools/geotools
typeDefinition = elemDecl.getTypeDefinition();
typeDefinition = elemDecl.getTypeDefinition();
代码示例来源:origin: geotools/geotools
if (child.getTypeDefinition() == null) {
foundNull = true;
代码示例来源:origin: geotools/geotools
element = element.getResolvedElementDeclaration();
XSDTypeDefinition childType = element.getTypeDefinition();
if (childType == null) {
childType = findGlobalElementXSDType(element);
代码示例来源:origin: geotools/geotools
if (child.getTypeDefinition() == null) {
foundNull = true;
代码示例来源:origin: org.eclipse/org.eclipse.wst.xsd.ui
public void visitXSDElementDeclaration(XSDElementDeclaration xsdElementDeclaration)
{
indent += 2;
XSDTypeDefinition td = xsdElementDeclaration.getTypeDefinition();
if (td == null)
{
td = xsdElementDeclaration.getAnonymousTypeDefinition();
}
visitXSDObject(td);
indent -= 2;
}
代码示例来源:origin: org.eclipse/org.eclipse.xsd
protected XSDDiagnostic checkElementComplexContent
(String elementName,
String part,
String anchor,
Element element)
{
XSDElementDeclaration xsdElementDeclaration = getSchema().getSchemaForSchema().resolveElementDeclaration(elementName);
return checkComplexContent((XSDComplexTypeDefinition)xsdElementDeclaration.getTypeDefinition(), part, anchor, element);
}
代码示例来源:origin: org.eclipse.xsd/org.eclipse.xsd
protected XSDDiagnostic checkElementComplexContent
(String elementName,
String part,
String anchor,
Element element)
{
XSDElementDeclaration xsdElementDeclaration = getSchema().getSchemaForSchema().resolveElementDeclaration(elementName);
return checkComplexContent((XSDComplexTypeDefinition)xsdElementDeclaration.getTypeDefinition(), part, anchor, element);
}
代码示例来源:origin: org.eclipse/org.eclipse.wst.xsd.ui
public IType getType()
{
XSDTypeDefinition td = getXSDElementDeclaration().getResolvedElementDeclaration().getTypeDefinition();
//if (td != null &&
// td.getTargetNamespace() != null && td.getTargetNamespace().equals(XSDConstants.SCHEMA_FOR_SCHEMA_URI_2001)) return null;
return (td != null) ? (IType) XSDAdapterFactory.getInstance().adapt(td) : null;
}
代码示例来源:origin: org.eclipse/org.eclipse.wst.xsd.ui
public void visitElementDeclaration(org.eclipse.xsd.XSDElementDeclaration element)
{
if (element.getTypeDefinition() == target)
{
XSDSimpleTypeDefinition type = target.getSchema().getSchemaForSchema().resolveSimpleTypeDefinition("string"); //$NON-NLS-1$
element.setTypeDefinition(type);
}
super.visitElementDeclaration(element);
}
};
内容来源于网络,如有侵权,请联系作者删除!