@HashCodeAndEqualsPlugin.Enhance public static class TypePool.Default.LazyTypeDescription.TypeContainment.WithinType extends java.lang.Object implements TypePool.Default.LazyTypeDescription.TypeContainment
TypePool.Default.LazyTypeDescription.TypeContainment.SelfContained, TypePool.Default.LazyTypeDescription.TypeContainment.WithinMethod, TypePool.Default.LazyTypeDescription.TypeContainment.WithinType
Modifier and Type | Field and Description |
---|---|
private boolean |
localType
true if the type is a local type unless it is an anonymous type. |
private java.lang.String |
name
The type's binary name.
|
Modifier | Constructor and Description |
---|---|
protected |
WithinType(java.lang.String internalName,
boolean localType)
Creates a new type containment for a type that is declared within another type.
|
Modifier and Type | Method and Description |
---|---|
MethodDescription.InDefinedShape |
getEnclosingMethod(TypePool typePool)
Returns the enclosing method or
null if no such method exists. |
TypeDescription |
getEnclosingType(TypePool typePool)
Returns the enclosing type or
null if no such type exists. |
boolean |
isLocalType()
Returns
true if the type is a local type unless it is an anonymous type. |
boolean |
isSelfContained()
Returns
true if the type is self-contained. |
private final java.lang.String name
private final boolean localType
true
if the type is a local type unless it is an anonymous type.protected WithinType(java.lang.String internalName, boolean localType)
internalName
- The type's internal name.localType
- true
if the type is a local type unless it is an anonymous type.public MethodDescription.InDefinedShape getEnclosingMethod(TypePool typePool)
null
if no such method exists.getEnclosingMethod
in interface TypePool.Default.LazyTypeDescription.TypeContainment
typePool
- The type pool to be used for looking up linked types.null
.public TypeDescription getEnclosingType(TypePool typePool)
null
if no such type exists.getEnclosingType
in interface TypePool.Default.LazyTypeDescription.TypeContainment
typePool
- The type pool to be used for looking up linked types.null
.public boolean isSelfContained()
true
if the type is self-contained.isSelfContained
in interface TypePool.Default.LazyTypeDescription.TypeContainment
true
if the type is self-contained.public boolean isLocalType()
true
if the type is a local type unless it is an anonymous type.isLocalType
in interface TypePool.Default.LazyTypeDescription.TypeContainment
true
if the type is a local type unless it is an anonymous type