public class SchemaFactory extends Object
| Modifier and Type | Method and Description |
|---|---|
static org.eclipse.microprofile.openapi.models.media.Schema |
enumToSchema(AnnotationScannerContext context,
org.jboss.jandex.Type enumType)
Convert a Jandex enum class type to a
Schema model.Adds each enum constant name to the list of the given schema's
enumeration list. |
static org.eclipse.microprofile.openapi.models.media.Schema |
readSchema(AnnotationScannerContext context,
org.jboss.jandex.AnnotationInstance schemaAnnotation)
Reads a Schema annotation into a model.
|
static org.eclipse.microprofile.openapi.models.media.Schema |
readSchema(AnnotationScannerContext context,
org.jboss.jandex.AnnotationValue value)
Reads a Schema annotation into a model.
|
static org.eclipse.microprofile.openapi.models.media.Schema |
readSchema(AnnotationScannerContext context,
org.eclipse.microprofile.openapi.models.media.Schema schema,
org.jboss.jandex.AnnotationInstance annotation,
org.jboss.jandex.ClassInfo clazz)
Populates the schema using the
@Schema
on the provided class. |
static org.eclipse.microprofile.openapi.models.media.Schema |
readSchema(AnnotationScannerContext context,
org.eclipse.microprofile.openapi.models.media.Schema schema,
org.jboss.jandex.AnnotationInstance annotation,
Map<String,Object> defaults) |
static org.eclipse.microprofile.openapi.models.media.Schema |
schemaRegistration(AnnotationScannerContext context,
org.jboss.jandex.Type type,
org.eclipse.microprofile.openapi.models.media.Schema schema)
Register the provided schema in the SchemaRegistry if allowed.
|
static org.eclipse.microprofile.openapi.models.media.Schema |
typeToSchema(AnnotationScannerContext context,
org.jboss.jandex.Type type,
List<AnnotationScannerExtension> extensions)
Converts a Jandex type to a
Schema model. |
public static org.eclipse.microprofile.openapi.models.media.Schema readSchema(AnnotationScannerContext context, org.jboss.jandex.AnnotationValue value)
context - scanning contextvalue - the annotation valuepublic static org.eclipse.microprofile.openapi.models.media.Schema readSchema(AnnotationScannerContext context, org.jboss.jandex.AnnotationInstance schemaAnnotation)
context - scanning contextschemaAnnotation - the @Schema annotationpublic static org.eclipse.microprofile.openapi.models.media.Schema readSchema(AnnotationScannerContext context, org.eclipse.microprofile.openapi.models.media.Schema schema, org.jboss.jandex.AnnotationInstance annotation, org.jboss.jandex.ClassInfo clazz)
@Schema
on the provided class. If the schema has already been registered (in components), the existing
registration will be replaced.context - scanning contextschema - schema model to populateannotation - schema annotation to readclazz - the class annotated with @Schemaimplementation has been specified in the annotationpublic static org.eclipse.microprofile.openapi.models.media.Schema readSchema(AnnotationScannerContext context, org.eclipse.microprofile.openapi.models.media.Schema schema, org.jboss.jandex.AnnotationInstance annotation, Map<String,Object> defaults)
public static org.eclipse.microprofile.openapi.models.media.Schema typeToSchema(AnnotationScannerContext context, org.jboss.jandex.Type type, List<AnnotationScannerExtension> extensions)
Schema model.context - scanning contexttype - the implementation type of the item to scanextensions - list of AnnotationScannerExtensionspublic static org.eclipse.microprofile.openapi.models.media.Schema enumToSchema(AnnotationScannerContext context, org.jboss.jandex.Type enumType)
Schema model.Adds each enum constant name to the list of the given schema's
enumeration list.
The given type must be found in the index.context - scanning contextenumType - type containing Java Enum constantsField.isEnumConstant()public static org.eclipse.microprofile.openapi.models.media.Schema schemaRegistration(AnnotationScannerContext context, org.jboss.jandex.Type type, org.eclipse.microprofile.openapi.models.media.Schema schema)
context - scanning contexttype - the type of the schema to registerschema - a schemaCopyright © 2018–2021. All rights reserved.