Package com.io7m.jxe.core
Class JXESchemaResolutionMappings.Builder
java.lang.Object
com.io7m.jxe.core.JXESchemaResolutionMappings.Builder
- Enclosing class:
- JXESchemaResolutionMappings
Builds instances of type
JXESchemaResolutionMappings.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds a newJXESchemaResolutionMappings.from(JXESchemaResolutionMappingsType instance) Fill a builder with attribute values from the providedJXESchemaResolutionMappingsTypeinstance.putAllMappings(Map<? extends URI, ? extends JXESchemaDefinition> entries) Put all mappings from the specified map as entries tomappingsmap.putMappings(URI key, JXESchemaDefinition value) Put one entry to themappingsmap.putMappings(Map.Entry<? extends URI, ? extends JXESchemaDefinition> entry) Put one entry to themappingsmap.setMappings(Map<? extends URI, ? extends JXESchemaDefinition> entries) Sets or replaces all mappings from the specified map as entries for themappingsmap.
-
Method Details
-
from
Fill a builder with attribute values from the providedJXESchemaResolutionMappingsTypeinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
putMappings
Put one entry to themappingsmap.- Parameters:
key- The key in the mappings mapvalue- The associated value in the mappings map- Returns:
thisbuilder for use in a chained invocation
-
putMappings
public final JXESchemaResolutionMappings.Builder putMappings(Map.Entry<? extends URI, ? extends JXESchemaDefinition> entry) Put one entry to themappingsmap. Nulls are not permitted- Parameters:
entry- The key and value entry- Returns:
thisbuilder for use in a chained invocation
-
setMappings
public final JXESchemaResolutionMappings.Builder setMappings(Map<? extends URI, ? extends JXESchemaDefinition> entries) Sets or replaces all mappings from the specified map as entries for themappingsmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the mappings map- Returns:
thisbuilder for use in a chained invocation
-
putAllMappings
public final JXESchemaResolutionMappings.Builder putAllMappings(Map<? extends URI, ? extends JXESchemaDefinition> entries) Put all mappings from the specified map as entries tomappingsmap. Nulls are not permitted- Parameters:
entries- The entries that will be added to the mappings map- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newJXESchemaResolutionMappings.- Returns:
- An immutable instance of JXESchemaResolutionMappings
- Throws:
IllegalStateException- if any required attributes are missing
-