use of org.wildfly.swarm.microprofile.openapi.api.models.ExternalDocumentationImpl in project wildfly-swarm by wildfly-swarm.
the class OpenApiParser method readExternalDocs.
/**
* Reads an {@link ExternalDocumentation} OpenAPI node.
* @param node
*/
private ExternalDocumentation readExternalDocs(JsonNode node) {
if (node == null) {
return null;
}
ExternalDocumentationImpl model = new ExternalDocumentationImpl();
model.setDescription(JsonUtil.stringProperty(node, OpenApiConstants.PROP_DESCRIPTION));
model.setUrl(JsonUtil.stringProperty(node, OpenApiConstants.PROP_URL));
readExtensions(node, model);
return model;
}
use of org.wildfly.swarm.microprofile.openapi.api.models.ExternalDocumentationImpl in project wildfly-swarm by wildfly-swarm.
the class OpenApiAnnotationScanner method readExternalDocs.
/**
* Reads an ExternalDocumentation annotation.
* @param externalDocAnno
*/
private ExternalDocumentation readExternalDocs(AnnotationValue externalDocAnno) {
if (externalDocAnno == null) {
return null;
}
LOG.debug("Processing an @ExternalDocumentation annotation.");
AnnotationInstance nested = externalDocAnno.asNested();
ExternalDocumentation externalDoc = new ExternalDocumentationImpl();
externalDoc.setDescription(JandexUtil.stringValue(nested, OpenApiConstants.PROP_DESCRIPTION));
externalDoc.setUrl(JandexUtil.stringValue(nested, OpenApiConstants.PROP_URL));
return externalDoc;
}
use of org.wildfly.swarm.microprofile.openapi.api.models.ExternalDocumentationImpl in project wildfly-swarm by wildfly-swarm.
the class SchemaFactory method readExternalDocs.
private static ExternalDocumentation readExternalDocs(AnnotationValue externalDocAnno) {
if (externalDocAnno == null) {
return null;
}
AnnotationInstance nested = externalDocAnno.asNested();
ExternalDocumentation externalDoc = new ExternalDocumentationImpl();
externalDoc.setDescription(JandexUtil.stringValue(nested, OpenApiConstants.PROP_DESCRIPTION));
externalDoc.setUrl(JandexUtil.stringValue(nested, OpenApiConstants.PROP_URL));
return externalDoc;
}
Aggregations