Class ImmutableProto.DeclaringPackage
- java.lang.Object
-
- org.immutables.value.processor.meta.Proto.Diagnosable
-
- org.immutables.value.processor.meta.Proto.AbstractDeclaring
-
- org.immutables.value.processor.meta.Proto.DeclaringPackage
-
- org.immutables.value.processor.meta.ImmutableProto.DeclaringPackage
-
- Enclosing class:
- ImmutableProto
@Immutable public static final class ImmutableProto.DeclaringPackage extends Proto.DeclaringPackage
Immutable implementation ofProto.DeclaringPackage.Use the builder to create immutable instances:
ImmutableProto.DeclaringPackage.builder().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableProto.DeclaringPackage.BuilderBuilds instances of typeDeclaringPackage.private classImmutableProto.DeclaringPackage.InitShim
-
Field Summary
Fields Modifier and Type Field Description private static longBUILDER_INCLUDE_LAZY_INIT_BITprivate static longBUILDER_INCLUDED_TYPES_LAZY_INIT_BITprivate com.google.common.base.Optional<FIncludeMirror>builderIncludeprivate java.util.List<javax.lang.model.element.TypeElement>builderIncludedTypesprivate static longDATATYPE_ENABLED_LAZY_INIT_BITprivate com.google.common.base.Optional<DataMirror>datatypeEnabledprivate com.google.common.base.Optional<java.lang.String[]>depluralizeprivate static longDEPLURALIZE_LAZY_INIT_BITprivate javax.lang.model.element.PackageElementelementprivate Proto.Environmentenvironmentprivate com.google.common.base.Optional<IncludeMirror>includeprivate static longINCLUDE_LAZY_INIT_BITprivate static longINCLUDED_TYPES_LAZY_INIT_BITprivate java.util.List<javax.lang.model.element.TypeElement>includedTypesprivate ImmutableProto.DeclaringPackage.InitShiminitShimprivate Proto.Interninginternerprivate static longIS_JACKSON_DESERIALIZED_ANNOTATED_LAZY_INIT_BITprivate static longIS_JACKSON_DESERIALIZED_LAZY_INIT_BITprivate static longIS_JACKSON_JSON_TYPE_INFO_LAZY_INIT_BITprivate static longIS_JACKSON_SERIALIZED_LAZY_INIT_BITprivate static longIS_SERIAL_STRUCTURAL_LAZY_INIT_BITprivate booleanisJacksonDeserializedprivate booleanisJacksonDeserializedAnnotatedprivate booleanisJacksonJsonTypeInfoprivate booleanisJacksonSerializedprivate booleanisSerialStructuralprivate static longJACKSON_SERIALIZE_MODE_LAZY_INIT_BITprivate Proto.JacksonModejacksonSerializeModeprivate longlazyInitBitmapprivate static longMETA_ANNOTATED_LAZY_INIT_BITprivate java.util.List<Proto.MetaAnnotated>metaAnnotatedprivate java.lang.Stringnameprivate static longNAMED_PARENT_PACKAGE_LAZY_INIT_BITprivate com.google.common.base.Optional<Proto.DeclaringPackage>namedParentPackageprivate static longOK_TYPE_ADAPTERS_LAZY_INIT_BITprivate com.google.common.base.Optional<OkTypeAdaptersMirror>okTypeAdaptersprivate static longSERIAL_VERSION_LAZY_INIT_BITprivate com.google.common.base.Optional<java.lang.Long>serialVersionprivate java.lang.StringsimpleNameprivate static byteSTAGE_INITIALIZEDprivate static byteSTAGE_INITIALIZINGprivate static byteSTAGE_UNINITIALIZEDprivate com.google.common.base.Optional<StyleInfo>styleprivate static longSTYLE_LAZY_INIT_BITprivate static longTYPE_ADAPTERS_LAZY_INIT_BITprivate com.google.common.base.Optional<TypeAdaptersMirror>typeAdapters
-
Constructor Summary
Constructors Modifier Constructor Description privateDeclaringPackage(Proto.Environment environment, Proto.Interning interner, javax.lang.model.element.PackageElement element)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableProto.DeclaringPackage.Builderbuilder()Creates a builder forDeclaringPackage.protected com.google.common.base.Optional<FIncludeMirror>builderInclude()(package private) java.util.List<javax.lang.model.element.TypeElement>builderIncludedTypes()static ImmutableProto.DeclaringPackagecopyOf(Proto.DeclaringPackage instance)Creates an immutable copy of aProto.DeclaringPackagevalue.com.google.common.base.Optional<DataMirror>datatypeEnabled()com.google.common.base.Optional<java.lang.String[]>depluralize()javax.lang.model.element.PackageElementelement()Element suitable for reporting as a source of declaration which might causing problems.(package private) Proto.Environmentenvironment()booleanequals(java.lang.Object another)This instance is equal to all instances ofDeclaringPackagethat have equal attribute values.private booleanequalTo(int synthetic, ImmutableProto.DeclaringPackage another)inthashCode()Computes a hash code from attributes:name.protected com.google.common.base.Optional<IncludeMirror>include()(package private) java.util.List<javax.lang.model.element.TypeElement>includedTypes()(package private) Proto.Interninginterner()used to intern packaged created internallybooleanisJacksonDeserialized()booleanisJacksonDeserializedAnnotated()booleanisJacksonJsonTypeInfo()booleanisJacksonSerialized()booleanisSerialStructural()Proto.JacksonModejacksonSerializeMode()(package private) java.util.List<Proto.MetaAnnotated>metaAnnotated()java.lang.Stringname()Name is the only equivalence attribute.(package private) com.google.common.base.Optional<Proto.DeclaringPackage>namedParentPackage()com.google.common.base.Optional<OkTypeAdaptersMirror>okTypeAdapters()com.google.common.base.Optional<java.lang.Long>serialVersion()java.lang.StringsimpleName()com.google.common.base.Optional<StyleInfo>style()java.lang.StringtoString()Prints the immutable valueDeclaringPackagewith attribute values.com.google.common.base.Optional<TypeAdaptersMirror>typeAdapters()ImmutableProto.DeclaringPackagewithElement(javax.lang.model.element.PackageElement value)Copy the current immutable object by setting a value for theelementattribute.ImmutableProto.DeclaringPackagewithEnvironment(Proto.Environment value)Copy the current immutable object by setting a value for theenvironmentattribute.ImmutableProto.DeclaringPackagewithInterner(Proto.Interning value)Copy the current immutable object by setting a value for theinternerattribute.-
Methods inherited from class org.immutables.value.processor.meta.Proto.DeclaringPackage
collectEncodings, packageOf
-
Methods inherited from class org.immutables.value.processor.meta.Proto.AbstractDeclaring
asPrefix, asType, getAnnotationInjections
-
Methods inherited from class org.immutables.value.processor.meta.Proto.Diagnosable
processing, report
-
-
-
-
Field Detail
-
environment
private final Proto.Environment environment
-
interner
private final Proto.Interning interner
-
element
private final javax.lang.model.element.PackageElement element
-
simpleName
private final transient java.lang.String simpleName
-
name
private final transient java.lang.String name
-
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 ImmutableProto.DeclaringPackage.InitShim initShim
-
lazyInitBitmap
private transient volatile long lazyInitBitmap
-
INCLUDE_LAZY_INIT_BIT
private static final long INCLUDE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
include
private transient com.google.common.base.Optional<IncludeMirror> include
-
BUILDER_INCLUDE_LAZY_INIT_BIT
private static final long BUILDER_INCLUDE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
builderInclude
private transient com.google.common.base.Optional<FIncludeMirror> builderInclude
-
TYPE_ADAPTERS_LAZY_INIT_BIT
private static final long TYPE_ADAPTERS_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
typeAdapters
private transient com.google.common.base.Optional<TypeAdaptersMirror> typeAdapters
-
OK_TYPE_ADAPTERS_LAZY_INIT_BIT
private static final long OK_TYPE_ADAPTERS_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
okTypeAdapters
private transient com.google.common.base.Optional<OkTypeAdaptersMirror> okTypeAdapters
-
INCLUDED_TYPES_LAZY_INIT_BIT
private static final long INCLUDED_TYPES_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
includedTypes
private transient java.util.List<javax.lang.model.element.TypeElement> includedTypes
-
BUILDER_INCLUDED_TYPES_LAZY_INIT_BIT
private static final long BUILDER_INCLUDED_TYPES_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
builderIncludedTypes
private transient java.util.List<javax.lang.model.element.TypeElement> builderIncludedTypes
-
META_ANNOTATED_LAZY_INIT_BIT
private static final long META_ANNOTATED_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
metaAnnotated
private transient java.util.List<Proto.MetaAnnotated> metaAnnotated
-
JACKSON_SERIALIZE_MODE_LAZY_INIT_BIT
private static final long JACKSON_SERIALIZE_MODE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
jacksonSerializeMode
private transient Proto.JacksonMode jacksonSerializeMode
-
IS_JACKSON_DESERIALIZED_ANNOTATED_LAZY_INIT_BIT
private static final long IS_JACKSON_DESERIALIZED_ANNOTATED_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
isJacksonDeserializedAnnotated
private transient boolean isJacksonDeserializedAnnotated
-
NAMED_PARENT_PACKAGE_LAZY_INIT_BIT
private static final long NAMED_PARENT_PACKAGE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
namedParentPackage
private transient com.google.common.base.Optional<Proto.DeclaringPackage> namedParentPackage
-
IS_JACKSON_SERIALIZED_LAZY_INIT_BIT
private static final long IS_JACKSON_SERIALIZED_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
isJacksonSerialized
private transient boolean isJacksonSerialized
-
IS_JACKSON_DESERIALIZED_LAZY_INIT_BIT
private static final long IS_JACKSON_DESERIALIZED_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
isJacksonDeserialized
private transient boolean isJacksonDeserialized
-
IS_JACKSON_JSON_TYPE_INFO_LAZY_INIT_BIT
private static final long IS_JACKSON_JSON_TYPE_INFO_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
isJacksonJsonTypeInfo
private transient boolean isJacksonJsonTypeInfo
-
IS_SERIAL_STRUCTURAL_LAZY_INIT_BIT
private static final long IS_SERIAL_STRUCTURAL_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
isSerialStructural
private transient boolean isSerialStructural
-
SERIAL_VERSION_LAZY_INIT_BIT
private static final long SERIAL_VERSION_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
serialVersion
private transient com.google.common.base.Optional<java.lang.Long> serialVersion
-
STYLE_LAZY_INIT_BIT
private static final long STYLE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
style
private transient com.google.common.base.Optional<StyleInfo> style
-
DEPLURALIZE_LAZY_INIT_BIT
private static final long DEPLURALIZE_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
depluralize
private transient com.google.common.base.Optional<java.lang.String[]> depluralize
-
DATATYPE_ENABLED_LAZY_INIT_BIT
private static final long DATATYPE_ENABLED_LAZY_INIT_BIT
- See Also:
- Constant Field Values
-
datatypeEnabled
private transient com.google.common.base.Optional<DataMirror> datatypeEnabled
-
-
Constructor Detail
-
DeclaringPackage
private DeclaringPackage(Proto.Environment environment, Proto.Interning interner, javax.lang.model.element.PackageElement element)
-
-
Method Detail
-
environment
Proto.Environment environment()
- Specified by:
environmentin classProto.Diagnosable- Returns:
- The value of the
environmentattribute
-
interner
Proto.Interning interner()
used to intern packaged created internally- Specified by:
internerin classProto.AbstractDeclaring
-
element
public javax.lang.model.element.PackageElement element()
Description copied from class:Proto.DiagnosableElement suitable for reporting as a source of declaration which might causing problems.- Specified by:
elementin classProto.DeclaringPackage- Returns:
- The value of the
elementattribute
-
simpleName
public java.lang.String simpleName()
- Overrides:
simpleNamein classProto.DeclaringPackage- Returns:
- The computed-at-construction value of the
simpleNameattribute
-
name
public java.lang.String name()
Name is the only equivalence attribute. Basically packages are interned by name.- Overrides:
namein classProto.DeclaringPackage- Returns:
- package name
-
withEnvironment
public final ImmutableProto.DeclaringPackage withEnvironment(Proto.Environment value)
Copy the current immutable object by setting a value for theenvironmentattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for environment- Returns:
- A modified copy of the
thisobject
-
withInterner
public final ImmutableProto.DeclaringPackage withInterner(Proto.Interning value)
Copy the current immutable object by setting a value for theinternerattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for interner- Returns:
- A modified copy of the
thisobject
-
withElement
public final ImmutableProto.DeclaringPackage withElement(javax.lang.model.element.PackageElement value)
Copy the current immutable object by setting a value for theelementattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for element- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable java.lang.Object another)This instance is equal to all instances ofDeclaringPackagethat have equal attribute values.- Overrides:
equalsin classjava.lang.Object- Returns:
trueifthisis equal toanotherinstance
-
equalTo
private boolean equalTo(int synthetic, ImmutableProto.DeclaringPackage another)
-
hashCode
public int hashCode()
Computes a hash code from attributes:name.- Overrides:
hashCodein classjava.lang.Object- Returns:
- hashCode value
-
toString
public java.lang.String toString()
Prints the immutable valueDeclaringPackagewith attribute values.- Overrides:
toStringin classjava.lang.Object- Returns:
- A string representation of the value
-
include
protected com.google.common.base.Optional<IncludeMirror> include()
Returns a lazily initialized value of the
includeattribute. 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:
includein classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
includeattribute
-
builderInclude
protected com.google.common.base.Optional<FIncludeMirror> builderInclude()
Returns a lazily initialized value of the
builderIncludeattribute. 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:
builderIncludein classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
builderIncludeattribute
-
typeAdapters
public com.google.common.base.Optional<TypeAdaptersMirror> typeAdapters()
Returns a lazily initialized value of the
typeAdaptersattribute. 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:
typeAdaptersin classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
typeAdaptersattribute
-
okTypeAdapters
public com.google.common.base.Optional<OkTypeAdaptersMirror> okTypeAdapters()
Returns a lazily initialized value of the
okTypeAdaptersattribute. 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:
okTypeAdaptersin classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
okTypeAdaptersattribute
-
includedTypes
java.util.List<javax.lang.model.element.TypeElement> includedTypes()
Returns a lazily initialized value of the
includedTypesattribute. 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:
includedTypesin classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
includedTypesattribute
-
builderIncludedTypes
java.util.List<javax.lang.model.element.TypeElement> builderIncludedTypes()
Returns a lazily initialized value of the
builderIncludedTypesattribute. 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:
builderIncludedTypesin classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
builderIncludedTypesattribute
-
metaAnnotated
java.util.List<Proto.MetaAnnotated> metaAnnotated()
Returns a lazily initialized value of the
metaAnnotatedattribute. 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:
metaAnnotatedin classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
metaAnnotatedattribute
-
jacksonSerializeMode
public Proto.JacksonMode jacksonSerializeMode()
Returns a lazily initialized value of the
jacksonSerializeModeattribute. 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:
jacksonSerializeModein classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
jacksonSerializeModeattribute
-
isJacksonDeserializedAnnotated
public boolean isJacksonDeserializedAnnotated()
Returns a lazily initialized value of the
isJacksonDeserializedAnnotatedattribute. 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:
isJacksonDeserializedAnnotatedin classProto.AbstractDeclaring- Returns:
- A lazily initialized value of the
isJacksonDeserializedAnnotatedattribute
-
namedParentPackage
com.google.common.base.Optional<Proto.DeclaringPackage> namedParentPackage()
Returns a lazily initialized value of the
namedParentPackageattribute. 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:
namedParentPackagein classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
namedParentPackageattribute
-
isJacksonSerialized
public boolean isJacksonSerialized()
Returns a lazily initialized value of the
isJacksonSerializedattribute. 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:
isJacksonSerializedin classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
isJacksonSerializedattribute
-
isJacksonDeserialized
public boolean isJacksonDeserialized()
Returns a lazily initialized value of the
isJacksonDeserializedattribute. 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:
isJacksonDeserializedin classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
isJacksonDeserializedattribute
-
isJacksonJsonTypeInfo
public boolean isJacksonJsonTypeInfo()
Returns a lazily initialized value of the
isJacksonJsonTypeInfoattribute. 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:
isJacksonJsonTypeInfoin classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
isJacksonJsonTypeInfoattribute
-
isSerialStructural
public boolean isSerialStructural()
Returns a lazily initialized value of the
isSerialStructuralattribute. 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:
isSerialStructuralin classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
isSerialStructuralattribute
-
serialVersion
public com.google.common.base.Optional<java.lang.Long> serialVersion()
Returns a lazily initialized value of the
serialVersionattribute. 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:
serialVersionin classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
serialVersionattribute
-
style
public com.google.common.base.Optional<StyleInfo> style()
Returns a lazily initialized value of the
styleattribute. 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:
stylein classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
styleattribute
-
depluralize
public com.google.common.base.Optional<java.lang.String[]> depluralize()
Returns a lazily initialized value of the
depluralizeattribute. 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:
depluralizein classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
depluralizeattribute
-
datatypeEnabled
public com.google.common.base.Optional<DataMirror> datatypeEnabled()
Returns a lazily initialized value of the
datatypeEnabledattribute. 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:
datatypeEnabledin classProto.DeclaringPackage- Returns:
- A lazily initialized value of the
datatypeEnabledattribute
-
copyOf
public static ImmutableProto.DeclaringPackage copyOf(Proto.DeclaringPackage instance)
Creates an immutable copy of aProto.DeclaringPackagevalue. 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 DeclaringPackage instance
-
builder
public static ImmutableProto.DeclaringPackage.Builder builder()
Creates a builder forDeclaringPackage.ImmutableProto.DeclaringPackage.builder() .environment(org.immutables.value.processor.meta.Proto.Environment) // requiredenvironment.interner(org.immutables.value.processor.meta.Proto.Interning) // requiredinterner.element(javax.lang.model.element.PackageElement) // requiredelement.build();- Returns:
- A new DeclaringPackage builder
-
-