Class SchemaMap

java.lang.Object
io.github.microcks.util.SchemaMap

public class SchemaMap extends Object
This is a lightweight structure representing a Schema registry snapshot dedicated for being used by message validators.
Author:
laurent
  • Constructor Details

    • SchemaMap

      public SchemaMap()
      Build a new schema map with empty content.
    • SchemaMap

      public SchemaMap(Map<String,String> schemaEntries)
      Initialize a new schema map with provided content.
      Parameters:
      schemaEntries - Map of schema entries. Keys are schema paths, Values are schema string representation.
  • Method Details

    • putSchemaEntry

      public void putSchemaEntry(String schemaPath, String content)
      Put a new schema entry in map.
      Parameters:
      schemaPath - The path of this new entry.
      content - The string representation of schema content
    • hasSchemaEntry

      public boolean hasSchemaEntry(String schemaPath)
      Check if we've got an entry for this schema path.
      Parameters:
      schemaPath - The path of searched entry.
      Returns:
      True if we've got a corresponding entry, false otherwise.
    • getSchemaEntry

      public String getSchemaEntry(String schemaPath)
      Get schema entry string content.
      Parameters:
      schemaPath - The path of searched entry.
      Returns:
      The string representation of schema content