1 package com.fasterxml.jackson.core; 2 3 import com.fasterxml.jackson.core.util.JacksonFeature; 4 5 /** 6 * Marker interface that is to be implemented by data format - specific features. 7 * Interface used since Java Enums can not extend classes or other Enums, but 8 * they can implement interfaces; and as such we may be able to use limited 9 * amount of generic functionality. 10 *<p> 11 * Since 2.12 this is more of an extra marker feature, as its core API is now 12 * defined in more general {@link JacksonFeature}. 13 * 14 * @since 2.6 15 */ 16 public interface FormatFeature 17 extends JacksonFeature // since 2.12 18 { 19 /** 20 * Accessor for checking whether this feature is enabled by default. 21 */ 22 @Override enabledByDefault()23 public boolean enabledByDefault(); 24 25 /** 26 * Returns bit mask for this feature instance; must be a single bit, 27 * that is of form <code>(1 << N)</code> 28 */ 29 @Override getMask()30 public int getMask(); 31 32 /** 33 * Convenience method for checking whether feature is enabled in given bitmask 34 */ 35 @Override enabledIn(int flags)36 public boolean enabledIn(int flags); 37 } 38