Package io.polyapi.plugin.service.schema
Class PolySchemaStore
java.lang.Object
org.jsonschema2pojo.SchemaStore
io.polyapi.plugin.service.schema.PolySchemaStore
public class PolySchemaStore
extends org.jsonschema2pojo.SchemaStore
This class is a copy of the parent
SchemaStore with the difference that uses a PolyFragmentResolver instead of a FragmentResolver.-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final org.jsonschema2pojo.FragmentResolverFields inherited from class org.jsonschema2pojo.SchemaStore
contentResolver, logger, schemas -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.jsonschema2pojo.SchemaCreate or look up a new schema which has the given ID and read the contents of the given ID as a URL.org.jsonschema2pojo.SchemaCreate or look up a new schema using the given schema as a parent and the path as a relative reference.Methods inherited from class org.jsonschema2pojo.SchemaStore
clearCache, removeFragment, selfReferenceWithoutParentFile
-
Field Details
-
fragmentResolver
protected final org.jsonschema2pojo.FragmentResolver fragmentResolver
-
-
Constructor Details
-
PolySchemaStore
public PolySchemaStore()
-
-
Method Details
-
create
Create or look up a new schema which has the given ID and read the contents of the given ID as a URL. If a schema with the given ID is already known, then a reference to the original schema will be returned.- Overrides:
createin classorg.jsonschema2pojo.SchemaStore- Parameters:
id- the id of the schema being createdrefFragmentPathDelimiters- A string containing any characters that should act as path delimiters when resolving $ref fragments.- Returns:
- a schema object containing the contents of the given path
-
create
public org.jsonschema2pojo.Schema create(org.jsonschema2pojo.Schema parent, String path, String refFragmentPathDelimiters) Create or look up a new schema using the given schema as a parent and the path as a relative reference. If a schema with the given parent and relative path is already known, then a reference to the original schema will be returned.- Overrides:
createin classorg.jsonschema2pojo.SchemaStore- Parameters:
parent- the schema which is the parent of the schema to be created.path- the relative path of this schema (will be used to create a complete URI by resolving this path against the parent schema's id)refFragmentPathDelimiters- A string containing any characters that should act as path delimiters when resolving $ref fragments.- Returns:
- a schema object containing the contents of the given path
-