use of com.webcohesion.enunciate.modules.jackson.model.types.JsonType in project enunciate by stoicflame.
the class ObjectDataTypeImpl method getSupertypes.
@Override
public List<DataTypeReference> getSupertypes() {
ArrayList<DataTypeReference> supertypes = null;
JsonType supertype = this.typeDefinition.getSupertype();
while (supertype != null) {
if (supertypes == null) {
supertypes = new ArrayList<DataTypeReference>();
}
supertypes.add(new DataTypeReferenceImpl(supertype, registrationContext));
supertype = supertype instanceof JsonClassType ? ((JsonClassType) supertype).getTypeDefinition() instanceof ObjectTypeDefinition ? ((ObjectTypeDefinition) ((JsonClassType) supertype).getTypeDefinition()).getSupertype() : null : null;
}
return supertypes;
}
use of com.webcohesion.enunciate.modules.jackson.model.types.JsonType in project enunciate by stoicflame.
the class Member method getAccessorType.
/**
* The type of an element accessor can be specified by an annotation.
*
* @return The accessor type.
*/
@Override
public DecoratedTypeMirror getAccessorType() {
if (this.explicitType != null) {
return this.explicitType;
}
JsonType specifiedJsonType = JsonTypeFactory.findSpecifiedType(this, this.context);
DecoratedTypeMirror specifiedType = specifiedJsonType instanceof JsonClassType ? (DecoratedTypeMirror) ((JsonClassType) specifiedJsonType).getTypeDefinition().asType() : null;
if (specifiedType != null) {
return specifiedType;
}
return super.getAccessorType();
}
Aggregations