Class StaticFeatureSet
java.lang.Object
org.inferred.freebuilder.processor.source.feature.StaticFeatureSet
- All Implemented Interfaces:
FeatureSet
Stores a set of
Feature instances, defaulting to FeatureType.testDefault(org.inferred.freebuilder.processor.source.feature.FeatureSet) when
asked for a type that was not explicitly registered.-
Field Summary
FieldsModifier and TypeFieldDescription -
Constructor Summary
ConstructorsConstructorDescriptionStaticFeatureSet(Feature<?>... features) Creates a feature set which will returnfeatureswhenget(org.inferred.freebuilder.processor.source.feature.FeatureType<T>)is called for the appropriate type. -
Method Summary
Modifier and TypeMethodDescription<T extends Feature<T>>
Tget(FeatureType<T> featureType) Returns the registered instance offeatureType, or the value ofFeatureType.testDefault(org.inferred.freebuilder.processor.source.feature.FeatureSet)if no explicit instance was registered with this set.toString()
-
Field Details
-
featuresByType
-
-
Constructor Details
-
StaticFeatureSet
Creates a feature set which will returnfeatureswhenget(org.inferred.freebuilder.processor.source.feature.FeatureType<T>)is called for the appropriate type.
-
-
Method Details
-
get
Returns the registered instance offeatureType, or the value ofFeatureType.testDefault(org.inferred.freebuilder.processor.source.feature.FeatureSet)if no explicit instance was registered with this set.- Specified by:
getin interfaceFeatureSet
-
toString
-