Skip to content
This repository was archived by the owner on Dec 25, 2024. It is now read-only.

Latest commit

 

History

History
66 lines (53 loc) · 3.36 KB

File metadata and controls

66 lines (53 loc) · 3.36 KB

DanishPig

org.openapijsonschematools.client.components.schemas.DanishPig.java public class DanishPig

A class that contains necessary nested schema classes, and classes to store validated list and map payloads

Nested Class Summary

Modifier and Type Class and Description
static class DanishPig.DanishPig1
schema class
static class DanishPig.DanishPigMap
output class for Map payloads
static class DanishPig.ClassName
schema class

DanishPig1

public static class DanishPig1
extends JsonSchema

A schema class that validates payloads

Field Summary

Modifier and Type Field and Description
static LinkedHashMap<String, KeywordValidator> keywordToValidator
new LinkedHashMap<>(Map.ofEntries(
    new KeywordEntry("type", new TypeValidator(Set.of(FrozenMap.class))),
    new KeywordEntry("properties", new PropertiesValidator(Map.ofEntries(
        new PropertyEntry("className", ClassName.class))
    ))),
    new KeywordEntry("required", new RequiredValidator(Set.of(
        "className"
    )))
));

Method Summary

Modifier and Type Method and Description
static DanishPigMap validate(Map<String, Object> arg, SchemaConfiguration configuration)

DanishPigMap

public static class DanishPigMap
extends FrozenMap<String, Object>

A class to store validated Map payloads

Method Summary

Modifier and Type Method and Description
static DanishPigMap of(Map<String, Object> arg, SchemaConfiguration configuration)
String className()
must be one of ["DanishPig"]
Object getAdditionalProperty(String name)
provides type safety for additional properties

Input Map Keys

type: Map<String, Object>
Key Type Description Notes
className String must be one of ["DanishPig"]
anyStringName Object any string name can be used but the value must be the correct type [optional]

ClassName

public static class ClassName
extends JsonSchema

A schema class that validates payloads

Field Summary

Modifier and Type Field and Description
static LinkedHashMap<String, KeywordValidator> keywordToValidator
new LinkedHashMap<>(Map.ofEntries(
    new KeywordEntry("type", new TypeValidator(Set.of(
        String.class
    ))),
    new KeywordEntry("enum", new EnumValidator(Set.of(
        "DanishPig"
)))
));

Method Summary

Modifier and Type Method and Description
static String validate(String arg, SchemaConfiguration configuration)

[Back to top] [Back to Component Schemas] [Back to README]