use of com.webcohesion.enunciate.modules.jaxb.model.types.XmlType in project enunciate by stoicflame.
the class ComplexDataTypeImpl method getSupertypes.
@Override
public List<DataTypeReference> getSupertypes() {
ArrayList<DataTypeReference> supertypes = null;
XmlType supertype = this.typeDefinition.getBaseType();
while (supertype != null) {
if (supertypes == null) {
supertypes = new ArrayList<DataTypeReference>();
}
supertypes.add(new DataTypeReferenceImpl(supertype, false, registrationContext));
supertype = supertype instanceof XmlClassType ? ((XmlClassType) supertype).getTypeDefinition() instanceof ComplexTypeDefinition ? ((XmlClassType) supertype).getTypeDefinition().getBaseType() : null : null;
}
return supertypes;
}
use of com.webcohesion.enunciate.modules.jaxb.model.types.XmlType in project enunciate by stoicflame.
the class EnumTypeDefinition method getBaseType.
// Inherited.
@Override
public XmlType getBaseType() {
XmlType xmlType = KnownXmlType.STRING;
if (xmlEnum != null) {
DecoratedTypeMirror typeMirror = Annotations.mirrorOf(new Callable<Class<?>>() {
@Override
public Class<?> call() throws Exception {
return xmlEnum.value();
}
}, this.env);
xmlType = XmlTypeFactory.getXmlType(typeMirror, this.context);
}
return xmlType;
}
Aggregations