Search in sources :

Example 1 with Oas30ExternalDocumentation

use of io.apicurio.datamodels.openapi.v3.models.Oas30ExternalDocumentation in project apicurio-data-models by Apicurio.

the class Oas20to30TransformationVisitor method visitExternalDocumentation.

/**
 * @see io.apicurio.datamodels.core.visitors.IVisitor#visitExternalDocumentation(io.apicurio.datamodels.core.models.common.ExternalDocumentation)
 */
@Override
public void visitExternalDocumentation(ExternalDocumentation node) {
    IExternalDocumentationParent parent30 = (IExternalDocumentationParent) this.lookup(node.parent());
    Oas30ExternalDocumentation externalDocs30 = (Oas30ExternalDocumentation) parent30.createExternalDocumentation();
    parent30.setExternalDocumentation(externalDocs30);
    externalDocs30.description = node.description;
    externalDocs30.url = node.url;
    this.mapNode(node, externalDocs30);
}
Also used : IExternalDocumentationParent(io.apicurio.datamodels.core.models.common.IExternalDocumentationParent) Oas30ExternalDocumentation(io.apicurio.datamodels.openapi.v3.models.Oas30ExternalDocumentation)

Aggregations

IExternalDocumentationParent (io.apicurio.datamodels.core.models.common.IExternalDocumentationParent)1 Oas30ExternalDocumentation (io.apicurio.datamodels.openapi.v3.models.Oas30ExternalDocumentation)1