public static JsonSchemaValidator matchesJsonSchema(String schema) {
        return new JsonSchemaValidatorFactory<String>() {
            @Override
            JsonNode createSchemaInstance(String input) throws IOException {
                return JsonLoader.fromString(input);
            }
        }.create(schema);
    }
public static JsonSchemaValidator matchesJsonSchema(String schema) {
        return new JsonSchemaValidatorFactory<String>() {
            @Override
            JsonNode createSchemaInstance(String input) throws IOException {
                return JsonLoader.fromString(input);
            }
        }.create(schema);
    }
public static JsonSchemaValidator matchesJsonSchema ( String schema ) { return new JsonSchemaValidatorFactory < String > ( ) { @ Override JsonNode createSchemaInstance ( String input ) throws IOException { return JsonLoader . fromString ( input ) ; } } . create ( schema ) ; }
Creates a Hamcrest matcher that validates that a JSON document conforms to the JSON schema provided to this method.

@param schema The string defining the JSON schema
@return A Hamcrest matcher
Creates a Hamcrest matcher that validates that a JSON document conforms to the JSON schema provided to this method .