All Downloads are FREE. Search and download functionalities are using the official Maven repository.

xpertss.json.schema.keyword.digest.helpers.IdentityDigester Maven / Gradle / Ivy

The newest version!
package xpertss.json.schema.keyword.digest.helpers;

import com.fasterxml.jackson.databind.JsonNode;
import com.github.fge.jackson.NodeType;
import xpertss.json.schema.keyword.digest.AbstractDigester;

/**
 * A "no-op" digester
 *
 * 

This is the most simple of digesters, which will return its input as the * digested forms. If you choose to use it, you will therefore only have to * provide the list of types supported by your keyword.

*/ public final class IdentityDigester extends AbstractDigester { /** * Constructor * * @param keyword the name for this keyword * @param first the first supported type * @param other other supported types, if any */ public IdentityDigester(String keyword, NodeType first, NodeType... other) { super(keyword, first, other); } @Override public JsonNode digest(JsonNode schema) { return schema; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy