Package org.forgerock.api.jackson
Interface WithExampleSchema<T>
- Type Parameters:
T- The type of the example.
- All Known Implementing Classes:
CrestAnySchema,CrestArraySchema,CrestBooleanSchema,CrestObjectSchema
public interface WithExampleSchema<T>
Extension for CREST and OpenAPI schemas to express an example value.
-
Method Summary
Modifier and TypeMethodDescriptionGetsexampleJSON Schema field.voidsetExample(String example) SetsexampleJSON Schema field.
-
Method Details
-
getExample
T getExample()GetsexampleJSON Schema field.- Returns:
- The example value, or null if not defined.
-
setExample
SetsexampleJSON Schema field.- Parameters:
example- The example value.- Throws:
IOException- When the type of schema cannot be parsed from the String value.
-