Class ImmutableConstitution
- java.lang.Object
-
- org.immutables.value.processor.meta.Constitution
-
- org.immutables.value.processor.meta.ImmutableConstitution
-
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable public final class ImmutableConstitution extends ConstitutionImmutable implementation ofConstitution.Use the builder to create immutable instances:
ImmutableConstitution.builder().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableConstitution.AppliedNameFormsImmutable implementation ofConstitution.AppliedNameForms.static classImmutableConstitution.BuilderBuilds instances of typeImmutableConstitution.private classImmutableConstitution.InitShimstatic classImmutableConstitution.NameFormsImmutable implementation ofConstitution.NameForms.-
Nested classes/interfaces inherited from class org.immutables.value.processor.meta.Constitution
Constitution.AbstractNameForms, Constitution.InnerBaseClassDefinition, Constitution.InnerBuilderDefinition, Constitution.InnerModifiableDefinition
-
-
Field Summary
-
Constructor Summary
Constructors Modifier Constructor Description privateImmutableConstitution(Proto.Protoclass protoclass)
-
Method Summary
-
Methods inherited from class org.immutables.value.processor.meta.Constitution
definingPackage, hasEnclosingNonvalue, hasTopLevelBuilder, hasTopLevelImmutable, isFactory, isImplementationHidden, isImplementationPrimary, isNested, isNestedFactoryOrConstructor, isOutsideBuilder, isOutsideBuilderNotNested, isSimple, returnsAbstractValueType, style
-
-
-
-
Field Detail
-
protoclass
private final Proto.Protoclass protoclass
-
implementationVisibility
private final transient Visibility implementationVisibility
-
builderVisibility
private final transient Visibility builderVisibility
-
implementationPackage
private final transient java.lang.String implementationPackage
-
names
private final transient Styles.UsingName.TypeNames names
-
hasImmutableInBuilder
private final transient boolean hasImmutableInBuilder
-
STAGE_INITIALIZING
private static final byte STAGE_INITIALIZING
- See Also:
- Constant Field Values
-
STAGE_UNINITIALIZED
private static final byte STAGE_UNINITIALIZED
- See Also:
- Constant Field Values
-
STAGE_INITIALIZED
private static final byte STAGE_INITIALIZED
- See Also:
- Constant Field Values
-
initShim
private transient volatile ImmutableConstitution.InitShim initShim
-
lazyInitBitmap
private transient volatile long lazyInitBitmap
-
GENERICS_LAZY_INIT_BIT
private static final long GENERICS_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
generics
private transient Generics generics
-
TYPE_PREFERABLY_ABSTRACT_LAZY_INIT_BIT
private static final long TYPE_PREFERABLY_ABSTRACT_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typePreferablyAbstract
private transient Constitution.NameForms typePreferablyAbstract
-
TYPE_DOCUMENT_LAZY_INIT_BIT
private static final long TYPE_DOCUMENT_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeDocument
private transient Constitution.NameForms typeDocument
-
TYPE_MODIFIABLE_LAZY_INIT_BIT
private static final long TYPE_MODIFIABLE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeModifiable
private transient Constitution.NameForms typeModifiable
-
FACTORY_CREATE_LAZY_INIT_BIT
private static final long FACTORY_CREATE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
factoryCreate
private transient Constitution.AppliedNameForms factoryCreate
-
TYPE_VALUE_LAZY_INIT_BIT
private static final long TYPE_VALUE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeValue
private transient Constitution.NameForms typeValue
-
TYPE_ABSTRACT_LAZY_INIT_BIT
private static final long TYPE_ABSTRACT_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeAbstract
private transient Constitution.NameForms typeAbstract
-
TYPE_IMMUTABLE_LAZY_INIT_BIT
private static final long TYPE_IMMUTABLE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeImmutable
private transient Constitution.NameForms typeImmutable
-
TYPE_IMMUTABLE_ENCLOSING_SIMPLE_NAME_LAZY_INIT_BIT
private static final long TYPE_IMMUTABLE_ENCLOSING_SIMPLE_NAME_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeImmutableEnclosingSimpleName
private transient java.lang.String typeImmutableEnclosingSimpleName
-
FACTORY_BUILDER_LAZY_INIT_BIT
private static final long FACTORY_BUILDER_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
factoryBuilder
private transient Constitution.AppliedNameForms factoryBuilder
-
FACTORY_OF_LAZY_INIT_BIT
private static final long FACTORY_OF_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
factoryOf
private transient Constitution.AppliedNameForms factoryOf
-
FACTORY_INSTANCE_LAZY_INIT_BIT
private static final long FACTORY_INSTANCE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
factoryInstance
private transient Constitution.AppliedNameForms factoryInstance
-
FACTORY_COPY_OF_LAZY_INIT_BIT
private static final long FACTORY_COPY_OF_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
factoryCopyOf
private transient Constitution.AppliedNameForms factoryCopyOf
-
TYPE_ENCLOSING_FACTORY_LAZY_INIT_BIT
private static final long TYPE_ENCLOSING_FACTORY_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeEnclosingFactory
private transient Constitution.NameForms typeEnclosingFactory
-
TYPE_ENCLOSING_LAZY_INIT_BIT
private static final long TYPE_ENCLOSING_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeEnclosing
private transient Constitution.NameForms typeEnclosing
-
TYPE_WITH_LAZY_INIT_BIT
private static final long TYPE_WITH_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeWith
private transient Constitution.NameForms typeWith
-
TYPE_BUILDER_LAZY_INIT_BIT
private static final long TYPE_BUILDER_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeBuilder
private transient Constitution.NameForms typeBuilder
-
TYPE_IMPLEMENTATION_BUILDER_LAZY_INIT_BIT
private static final long TYPE_IMPLEMENTATION_BUILDER_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeImplementationBuilder
private transient Constitution.NameForms typeImplementationBuilder
-
INNER_BUILDER_LAZY_INIT_BIT
private static final long INNER_BUILDER_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
innerBuilder
private transient Constitution.InnerBuilderDefinition innerBuilder
-
INNER_MODIFIABLE_LAZY_INIT_BIT
private static final long INNER_MODIFIABLE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
innerModifiable
private transient Constitution.InnerModifiableDefinition innerModifiable
-
-
Constructor Detail
-
ImmutableConstitution
private ImmutableConstitution(Proto.Protoclass protoclass)
-
-
Method Detail
-
protoclass
public Proto.Protoclass protoclass()
- Specified by:
protoclassin classConstitution- Returns:
- The value of the
protoclassattribute
-
implementationVisibility
public Visibility implementationVisibility()
- Overrides:
implementationVisibilityin classConstitution- Returns:
- The computed-at-construction value of the
implementationVisibilityattribute
-
builderVisibility
public Visibility builderVisibility()
- Overrides:
builderVisibilityin classConstitution- Returns:
- The computed-at-construction value of the
builderVisibilityattribute
-
implementationPackage
public java.lang.String implementationPackage()
- Overrides:
implementationPackagein classConstitution- Returns:
- The computed-at-construction value of the
implementationPackageattribute
-
names
public Styles.UsingName.TypeNames names()
- Overrides:
namesin classConstitution- Returns:
- The computed-at-construction value of the
namesattribute
-
hasImmutableInBuilder
public boolean hasImmutableInBuilder()
- Overrides:
hasImmutableInBuilderin classConstitution- Returns:
- The computed-at-construction value of the
hasImmutableInBuilderattribute
-
withProtoclass
public final ImmutableConstitution withProtoclass(Proto.Protoclass value)
Copy the current immutable object by setting a value for theprotoclassattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for protoclass- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable java.lang.Object another)This instance is equal to all instances ofImmutableConstitutionthat have equal attribute values.- Overrides:
equalsin classjava.lang.Object- Returns:
trueifthisis equal toanotherinstance
-
equalTo
private boolean equalTo(int synthetic, ImmutableConstitution another)
-
hashCode
public int hashCode()
Computes a hash code from attributes:protoclass,implementationVisibility,builderVisibility,implementationPackage,names,hasImmutableInBuilder.- Overrides:
hashCodein classjava.lang.Object- Returns:
- hashCode value
-
toString
public java.lang.String toString()
Prints the immutable valueConstitutionwith attribute values.- Overrides:
toStringin classjava.lang.Object- Returns:
- A string representation of the value
-
generics
public Generics generics()
Returns a lazily initialized value of the
genericsattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
genericsin classConstitution- Returns:
- A lazily initialized value of the
genericsattribute
-
typePreferablyAbstract
public Constitution.NameForms typePreferablyAbstract()
Returns a lazily initialized value of the
typePreferablyAbstractattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typePreferablyAbstractin classConstitution- Returns:
- A lazily initialized value of the
typePreferablyAbstractattribute
-
typeDocument
public Constitution.NameForms typeDocument()
Returns a lazily initialized value of the
typeDocumentattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeDocumentin classConstitution- Returns:
- A lazily initialized value of the
typeDocumentattribute
-
typeModifiable
public Constitution.NameForms typeModifiable()
Returns a lazily initialized value of the
typeModifiableattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeModifiablein classConstitution- Returns:
- A lazily initialized value of the
typeModifiableattribute
-
factoryCreate
public Constitution.AppliedNameForms factoryCreate()
Returns a lazily initialized value of the
factoryCreateattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
factoryCreatein classConstitution- Returns:
- A lazily initialized value of the
factoryCreateattribute
-
typeValue
public Constitution.NameForms typeValue()
Value is the canonical outside look of the value type. It should be eitherConstitution.typeAbstract()orConstitution.typeImmutable(). For factory it is a special surrogate.Returns a lazily initialized value of the
typeValueattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeValuein classConstitution- Returns:
- A lazily initialized value of the
typeValueattribute
-
typeAbstract
public Constitution.NameForms typeAbstract()
Actual abstract value type that is definitive model for the value type.Returns a lazily initialized value of the
typeAbstractattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeAbstractin classConstitution- Returns:
- A lazily initialized value of the
typeAbstractattribute
-
typeImmutable
public Constitution.NameForms typeImmutable()
Actual immutable value type generated implementation.Returns a lazily initialized value of the
typeImmutableattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeImmutablein classConstitution- Returns:
- A lazily initialized value of the
typeImmutableattribute
-
typeImmutableEnclosingSimpleName
java.lang.String typeImmutableEnclosingSimpleName()
Walks to the enclosing type's simple names and applies naming convention. This shortcut/fix shows deficiency of model (it's probably more complicated than needed).Returns a lazily initialized value of the
typeImmutableEnclosingSimpleNameattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeImmutableEnclosingSimpleNamein classConstitution- Returns:
- A lazily initialized value of the
typeImmutableEnclosingSimpleNameattribute
-
factoryBuilder
public Constitution.AppliedNameForms factoryBuilder()
Returns a lazily initialized value of the
factoryBuilderattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
factoryBuilderin classConstitution- Returns:
- A lazily initialized value of the
factoryBuilderattribute
-
factoryOf
public Constitution.AppliedNameForms factoryOf()
Returns a lazily initialized value of the
factoryOfattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
factoryOfin classConstitution- Returns:
- A lazily initialized value of the
factoryOfattribute
-
factoryInstance
public Constitution.AppliedNameForms factoryInstance()
Returns a lazily initialized value of the
factoryInstanceattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
factoryInstancein classConstitution- Returns:
- A lazily initialized value of the
factoryInstanceattribute
-
factoryCopyOf
public Constitution.AppliedNameForms factoryCopyOf()
Returns a lazily initialized value of the
factoryCopyOfattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
factoryCopyOfin classConstitution- Returns:
- A lazily initialized value of the
factoryCopyOfattribute
-
typeEnclosingFactory
public Constitution.NameForms typeEnclosingFactory()
Returns a lazily initialized value of the
typeEnclosingFactoryattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeEnclosingFactoryin classConstitution- Returns:
- A lazily initialized value of the
typeEnclosingFactoryattribute
-
typeEnclosing
public Constitution.NameForms typeEnclosing()
Returns a lazily initialized value of the
typeEnclosingattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeEnclosingin classConstitution- Returns:
- A lazily initialized value of the
typeEnclosingattribute
-
typeWith
public Constitution.NameForms typeWith()
Returns a lazily initialized value of the
typeWithattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeWithin classConstitution- Returns:
- A lazily initialized value of the
typeWithattribute
-
typeBuilder
public Constitution.NameForms typeBuilder()
Returns a lazily initialized value of the
typeBuilderattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeBuilderin classConstitution- Returns:
- A lazily initialized value of the
typeBuilderattribute
-
typeImplementationBuilder
public Constitution.NameForms typeImplementationBuilder()
Returns a lazily initialized value of the
typeImplementationBuilderattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
typeImplementationBuilderin classConstitution- Returns:
- A lazily initialized value of the
typeImplementationBuilderattribute
-
innerBuilder
public Constitution.InnerBuilderDefinition innerBuilder()
Returns a lazily initialized value of the
innerBuilderattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
innerBuilderin classConstitution- Returns:
- A lazily initialized value of the
innerBuilderattribute
-
innerModifiable
public Constitution.InnerModifiableDefinition innerModifiable()
Returns a lazily initialized value of the
innerModifiableattribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
innerModifiablein classConstitution- Returns:
- A lazily initialized value of the
innerModifiableattribute
-
copyOf
public static ImmutableConstitution copyOf(Constitution instance)
Creates an immutable copy of aConstitutionvalue. 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 Constitution instance
-
builder
public static ImmutableConstitution.Builder builder()
Creates a builder forImmutableConstitution.ImmutableConstitution.builder() .protoclass(org.immutables.value.processor.meta.Proto.Protoclass) // requiredprotoclass.build();- Returns:
- A new ImmutableConstitution builder
-
-