Package org.immutables.value.processor
Class ImmutableOkTypeAdapterTypes
- java.lang.Object
-
- org.immutables.value.processor.OkJsons.OkTypeAdapterTypes
-
- org.immutables.value.processor.ImmutableOkTypeAdapterTypes
-
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable final class ImmutableOkTypeAdapterTypes extends OkJsons.OkTypeAdapterTypesImmutable implementation ofOkJsons.OkTypeAdapterTypes.Use the builder to create immutable instances:
ImmutableOkTypeAdapterTypes.builder().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableOkTypeAdapterTypes.BuilderBuilds instances of typeImmutableOkTypeAdapterTypes.
-
Field Summary
Fields Modifier and Type Field Description private Proto.AbstractDeclaringdefinedByprivate OkJsons.EnumAllDefinitionsenumsprivate java.lang.StringpackageGeneratedprivate com.google.common.collect.ImmutableList<ValueType>types-
Fields inherited from class org.immutables.value.processor.OkJsons.OkTypeAdapterTypes
decider, requireAdapters
-
-
Constructor Summary
Constructors Modifier Constructor Description privateImmutableOkTypeAdapterTypes(Proto.AbstractDeclaring definedBy, java.lang.String packageGenerated, com.google.common.collect.ImmutableList<ValueType> types)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableOkTypeAdapterTypes.Builderbuilder()Creates a builder forImmutableOkTypeAdapterTypes.static ImmutableOkTypeAdapterTypescopyOf(OkJsons.OkTypeAdapterTypes instance)Creates an immutable copy of aOkJsons.OkTypeAdapterTypesvalue.(package private) Proto.AbstractDeclaringdefinedBy()(package private) OkJsons.EnumAllDefinitionsenums()booleanequals(java.lang.Object another)This instance is equal to all instances ofImmutableOkTypeAdapterTypesthat have equal attribute values.private booleanequalTo(int synthetic, ImmutableOkTypeAdapterTypes another)inthashCode()Computes a hash code from attributes:definedBy,packageGenerated,types,enums.(package private) java.lang.StringpackageGenerated()java.lang.StringtoString()Prints the immutable valueOkTypeAdapterTypeswith attribute values.(package private) com.google.common.collect.ImmutableList<ValueType>types()ImmutableOkTypeAdapterTypeswithDefinedBy(Proto.AbstractDeclaring value)Copy the current immutable object by setting a value for thedefinedByattribute.ImmutableOkTypeAdapterTypeswithPackageGenerated(java.lang.String value)Copy the current immutable object by setting a value for thepackageGeneratedattribute.ImmutableOkTypeAdapterTypeswithTypes(java.lang.Iterable<? extends ValueType> elements)Copy the current immutable object with elements that replace the content oftypes.ImmutableOkTypeAdapterTypeswithTypes(ValueType... elements)Copy the current immutable object with elements that replace the content oftypes.
-
-
-
Field Detail
-
definedBy
private final Proto.AbstractDeclaring definedBy
-
packageGenerated
private final java.lang.String packageGenerated
-
types
private final com.google.common.collect.ImmutableList<ValueType> types
-
enums
private final transient OkJsons.EnumAllDefinitions enums
-
-
Constructor Detail
-
ImmutableOkTypeAdapterTypes
private ImmutableOkTypeAdapterTypes(Proto.AbstractDeclaring definedBy, java.lang.String packageGenerated, com.google.common.collect.ImmutableList<ValueType> types)
-
-
Method Detail
-
definedBy
Proto.AbstractDeclaring definedBy()
- Specified by:
definedByin classOkJsons.OkTypeAdapterTypes- Returns:
- The value of the
definedByattribute
-
packageGenerated
java.lang.String packageGenerated()
- Specified by:
packageGeneratedin classOkJsons.OkTypeAdapterTypes- Returns:
- The value of the
packageGeneratedattribute
-
types
com.google.common.collect.ImmutableList<ValueType> types()
- Specified by:
typesin classOkJsons.OkTypeAdapterTypes- Returns:
- The value of the
typesattribute
-
enums
OkJsons.EnumAllDefinitions enums()
- Overrides:
enumsin classOkJsons.OkTypeAdapterTypes- Returns:
- The computed-at-construction value of the
enumsattribute
-
withDefinedBy
public final ImmutableOkTypeAdapterTypes withDefinedBy(Proto.AbstractDeclaring value)
Copy the current immutable object by setting a value for thedefinedByattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for definedBy- Returns:
- A modified copy of the
thisobject
-
withPackageGenerated
public final ImmutableOkTypeAdapterTypes withPackageGenerated(java.lang.String value)
Copy the current immutable object by setting a value for thepackageGeneratedattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for packageGenerated- Returns:
- A modified copy of the
thisobject
-
withTypes
public final ImmutableOkTypeAdapterTypes withTypes(ValueType... elements)
Copy the current immutable object with elements that replace the content oftypes.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withTypes
public final ImmutableOkTypeAdapterTypes withTypes(java.lang.Iterable<? extends ValueType> elements)
Copy the current immutable object with elements that replace the content oftypes. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of types elements to set- Returns:
- A modified copy of
thisobject
-
equals
public boolean equals(@Nullable java.lang.Object another)This instance is equal to all instances ofImmutableOkTypeAdapterTypesthat have equal attribute values.- Overrides:
equalsin classjava.lang.Object- Returns:
trueifthisis equal toanotherinstance
-
equalTo
private boolean equalTo(int synthetic, ImmutableOkTypeAdapterTypes another)
-
hashCode
public int hashCode()
Computes a hash code from attributes:definedBy,packageGenerated,types,enums.- Overrides:
hashCodein classjava.lang.Object- Returns:
- hashCode value
-
toString
public java.lang.String toString()
Prints the immutable valueOkTypeAdapterTypeswith attribute values.- Overrides:
toStringin classjava.lang.Object- Returns:
- A string representation of the value
-
copyOf
public static ImmutableOkTypeAdapterTypes copyOf(OkJsons.OkTypeAdapterTypes instance)
Creates an immutable copy of aOkJsons.OkTypeAdapterTypesvalue. 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 OkTypeAdapterTypes instance
-
builder
public static ImmutableOkTypeAdapterTypes.Builder builder()
Creates a builder forImmutableOkTypeAdapterTypes.ImmutableOkTypeAdapterTypes.builder() .definedBy(org.immutables.value.processor.meta.Proto.AbstractDeclaring) // requireddefinedBy.packageGenerated(String) // requiredpackageGenerated.addTypes|addAllTypes(org.immutables.value.processor.meta.ValueType) //typeselements .build();- Returns:
- A new ImmutableOkTypeAdapterTypes builder
-
-