Class ImmutableThirdPartyAttributeBuilderStrategy
- java.lang.Object
-
- org.immutables.value.processor.meta.AttributeBuilderReflection.ThirdPartyAttributeBuilderStrategy
-
- org.immutables.value.processor.meta.ImmutableThirdPartyAttributeBuilderStrategy
-
- All Implemented Interfaces:
AttributeBuilderReflection.Strategy
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable final class ImmutableThirdPartyAttributeBuilderStrategy extends AttributeBuilderReflection.ThirdPartyAttributeBuilderStrategyImmutable implementation ofAttributeBuilderReflection.ThirdPartyAttributeBuilderStrategy.Use the static factory method to create immutable instances:
ImmutableThirdPartyAttributeBuilderStrategy.of().
-
-
Field Summary
Fields Modifier and Type Field Description private AttributeBuilderDescriptorattributeBuilderDescriptorprivate javax.lang.model.element.TypeElementattributeValueTypeprivate AttributeBuilderThirdPartyModelbuilderModel
-
Constructor Summary
Constructors Modifier Constructor Description privateImmutableThirdPartyAttributeBuilderStrategy(AttributeBuilderThirdPartyModel builderModel, javax.lang.model.element.TypeElement attributeValueType)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected javax.lang.model.element.TypeElementattributeValueType()Guaranteed not null if isAttributeBuilder is true.protected AttributeBuilderThirdPartyModelbuilderModel()Guaranteed not null if isAttributeBuilder is true.static ImmutableThirdPartyAttributeBuilderStrategycopyOf(AttributeBuilderReflection.ThirdPartyAttributeBuilderStrategy instance)Creates an immutable copy of aAttributeBuilderReflection.ThirdPartyAttributeBuilderStrategyvalue.booleanequals(java.lang.Object another)This instance is equal to all instances ofImmutableThirdPartyAttributeBuilderStrategythat have equal attribute values.private booleanequalTo(int synthetic, ImmutableThirdPartyAttributeBuilderStrategy another)AttributeBuilderDescriptorgetAttributeBuilderDescriptor()inthashCode()Computes a hash code from attributes:builderModel,attributeValueType,attributeBuilderDescriptor.static ImmutableThirdPartyAttributeBuilderStrategyof(AttributeBuilderThirdPartyModel builderModel, javax.lang.model.element.TypeElement attributeValueType)Construct a new immutableThirdPartyAttributeBuilderStrategyinstance.java.lang.StringtoString()Prints the immutable valueThirdPartyAttributeBuilderStrategywith attribute values.ImmutableThirdPartyAttributeBuilderStrategywithAttributeValueType(javax.lang.model.element.TypeElement value)Copy the current immutable object by setting a value for theattributeValueTypeattribute.ImmutableThirdPartyAttributeBuilderStrategywithBuilderModel(AttributeBuilderThirdPartyModel value)Copy the current immutable object by setting a value for thebuilderModelattribute.-
Methods inherited from class org.immutables.value.processor.meta.AttributeBuilderReflection.ThirdPartyAttributeBuilderStrategy
isAttributeBuilder, isPossibleCopyMethod, of
-
-
-
-
Field Detail
-
builderModel
@Nullable private final AttributeBuilderThirdPartyModel builderModel
-
attributeValueType
@Nullable private final javax.lang.model.element.TypeElement attributeValueType
-
attributeBuilderDescriptor
@Nullable private final transient AttributeBuilderDescriptor attributeBuilderDescriptor
-
-
Constructor Detail
-
ImmutableThirdPartyAttributeBuilderStrategy
private ImmutableThirdPartyAttributeBuilderStrategy(@Nullable AttributeBuilderThirdPartyModel builderModel, @Nullable javax.lang.model.element.TypeElement attributeValueType)
-
-
Method Detail
-
builderModel
@Nullable protected AttributeBuilderThirdPartyModel builderModel()
Description copied from class:AttributeBuilderReflection.ThirdPartyAttributeBuilderStrategyGuaranteed not null if isAttributeBuilder is true.- Specified by:
builderModelin classAttributeBuilderReflection.ThirdPartyAttributeBuilderStrategy- Returns:
- The value of the
builderModelattribute
-
attributeValueType
@Nullable protected javax.lang.model.element.TypeElement attributeValueType()
Description copied from class:AttributeBuilderReflection.ThirdPartyAttributeBuilderStrategyGuaranteed not null if isAttributeBuilder is true.- Specified by:
attributeValueTypein classAttributeBuilderReflection.ThirdPartyAttributeBuilderStrategy- Returns:
- The value of the
attributeValueTypeattribute
-
getAttributeBuilderDescriptor
@Nullable public AttributeBuilderDescriptor getAttributeBuilderDescriptor()
- Specified by:
getAttributeBuilderDescriptorin interfaceAttributeBuilderReflection.Strategy- Overrides:
getAttributeBuilderDescriptorin classAttributeBuilderReflection.ThirdPartyAttributeBuilderStrategy- Returns:
- The computed-at-construction value of the
attributeBuilderDescriptorattribute
-
withBuilderModel
public final ImmutableThirdPartyAttributeBuilderStrategy withBuilderModel(@Nullable AttributeBuilderThirdPartyModel value)
Copy the current immutable object by setting a value for thebuilderModelattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for builderModel (can benull)- Returns:
- A modified copy of the
thisobject
-
withAttributeValueType
public final ImmutableThirdPartyAttributeBuilderStrategy withAttributeValueType(@Nullable javax.lang.model.element.TypeElement value)
Copy the current immutable object by setting a value for theattributeValueTypeattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for attributeValueType (can benull)- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable java.lang.Object another)This instance is equal to all instances ofImmutableThirdPartyAttributeBuilderStrategythat have equal attribute values.- Overrides:
equalsin classjava.lang.Object- Returns:
trueifthisis equal toanotherinstance
-
equalTo
private boolean equalTo(int synthetic, ImmutableThirdPartyAttributeBuilderStrategy another)
-
hashCode
public int hashCode()
Computes a hash code from attributes:builderModel,attributeValueType,attributeBuilderDescriptor.- Overrides:
hashCodein classjava.lang.Object- Returns:
- hashCode value
-
toString
public java.lang.String toString()
Prints the immutable valueThirdPartyAttributeBuilderStrategywith attribute values.- Overrides:
toStringin classjava.lang.Object- Returns:
- A string representation of the value
-
of
public static ImmutableThirdPartyAttributeBuilderStrategy of(@Nullable AttributeBuilderThirdPartyModel builderModel, @Nullable javax.lang.model.element.TypeElement attributeValueType)
Construct a new immutableThirdPartyAttributeBuilderStrategyinstance.- Parameters:
builderModel- The value for thebuilderModelattributeattributeValueType- The value for theattributeValueTypeattribute- Returns:
- An immutable ThirdPartyAttributeBuilderStrategy instance
-
copyOf
public static ImmutableThirdPartyAttributeBuilderStrategy copyOf(AttributeBuilderReflection.ThirdPartyAttributeBuilderStrategy instance)
Creates an immutable copy of aAttributeBuilderReflection.ThirdPartyAttributeBuilderStrategyvalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable ThirdPartyAttributeBuilderStrategy instance
-
-