Package com.networknt.schema.resource
Class SchemaMappers.Builder
java.lang.Object
com.networknt.schema.resource.SchemaMappers.Builder
- Enclosing class:
SchemaMappers
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionadd(SchemaMapper schemaMapper) Adds a schema mapper.build()Builds aSchemaMappersSets the function that maps the IRI to another IRI.Sets the function that maps the IRI to another IRI if the predicate is true.Sets the mappings.Maps a schema given a source prefix with a replacement.values(Consumer<List<SchemaMapper>> customizer) Customize the schema mappers.with(SchemaMappers.Builder builder)
-
Constructor Details
-
Builder
public Builder() -
Builder
-
-
Method Details
-
with
-
values
Customize the schema mappers.- Parameters:
customizer- the customizer- Returns:
- the builder
-
add
Adds a schema mapper.- Parameters:
schemaMapper- the schema mapper- Returns:
- the builder
-
mapPrefix
Maps a schema given a source prefix with a replacement.- Parameters:
source- the source prefixreplacement- the replacement prefix- Returns:
- the builder
-
mappings
Sets the mappings.- Parameters:
mappings- the mappings- Returns:
- the builder
-
mappings
Sets the function that maps the IRI to another IRI.- Parameters:
mappings- the mappings- Returns:
- the builder
-
mappings
Sets the function that maps the IRI to another IRI if the predicate is true.- Parameters:
test- the predicatemappings- the mappings- Returns:
- the builder
-
build
Builds aSchemaMappers- Returns:
- the schema mappers
-