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

com.cerner.beadledom.jackson.JsonGeneratorFeatureFlag Maven / Gradle / Ivy

There is a newer version: 4.1.2
Show newest version
package com.cerner.beadledom.jackson;

import com.fasterxml.jackson.core.JsonGenerator;
import com.google.auto.value.AutoValue;

/**
 * A helper class to enable/disable Jackson {@link JsonGenerator.Feature}'s
 * via Guice's multibinding.
 *
 * 

Example: * *

{@code @ProvidesIntoSet
 * JsonGeneratorFeatureFlag getJsonGeneratorFeature() {
 *   return JsonGeneratorFeatureFlag.create(JsonGenerator.Feature.FEATURE_NAME, true);
 * }
 * }
* * @author Nimesh Subramanian */ @AutoValue public abstract class JsonGeneratorFeatureFlag { public static JsonGeneratorFeatureFlag create(JsonGenerator.Feature feature, Boolean isEnabled) { return new AutoValue_JsonGeneratorFeatureFlag(feature, isEnabled); } public abstract JsonGenerator.Feature feature(); public abstract Boolean isEnabled(); }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy