This class handles caching internally and its advisable to not store
references directly to objects of this class. The static factory method
ClassInfo#getClassInfo(Class) should be used to retrieve an instance
from the cache. Internally the Class associated with a ClassInfo
instance is kept as WeakReference, so it not safe to reference
and instance without the Class being either strongly or softly reachable.
| Modifier and Type | Class and Description |
|---|---|
| public static interface | |
| private static class | |
| private static class | |
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private final ClassInfo. | |
| private final ClassInfo. | |
| private final WeakReference | |
| pack-priv MetaMethod[] | |
| private static final ClassInfo. | |
| private static final GroovyClassValue | |
| public final int | |
| private final LockableObject | |
| private static final ManagedConcurrentLinkedQueue | |
| pack-priv MetaMethod[] | |
| private ManagedConcurrentMap | |
| private static final ReferenceBundle | |
| private MetaClass | |
| private final AtomicInteger | |
| private static final ReferenceBundle | |
| private ManagedReference |
| Modifier and Type | Method and Description |
|---|---|
| public static void | |
| private static CachedClass | |
| public void | |
| public static int | |
| public static Collection | |
| private static Collection | |
| public ClassLoaderForClassArtifacts | |
| public CachedClass | |
| public static ClassInfo | |
| public final MetaClass | Returns: aMetaClass instanceReturns the |
| public MetaClass | |
| public MetaClass | |
| private MetaClass | |
| public ExpandoMetaClass | |
| public MetaClass | |
| public MetaClass | |
| public final Class | Returns: theClass associated with this ClassInfo, else nullReturns the |
| public int | |
| public MetaClass | |
| public boolean | |
| public void | |
| private static boolean | |
| private static boolean | |
| private static boolean | isValidWeakMetaClass(MetaClass metaClass, MetaClassRegistry.
if EMC.enableGlobally() is OFF, return whatever the cached answer is. |
| public void | |
| public static void | |
| public static void | |
| private void | |
| public void | |
| public void | |
| public void | |
| public static int | |
| public void |
| artifactClassLoader | back to summary |
|---|---|
| private final ClassInfo. | |
| cachedClassRef | back to summary |
|---|---|
| private final ClassInfo. | |
| classRef | back to summary |
|---|---|
| private final WeakReference<Class<?>> classRef | |
| dgmMetaMethods | back to summary |
|---|---|
| pack-priv MetaMethod[] dgmMetaMethods | |
| globalClassSet | back to summary |
|---|---|
| private static final ClassInfo. | |
| globalClassValue | back to summary |
|---|---|
| private static final GroovyClassValue<ClassInfo> globalClassValue | |
| hash | back to summary |
|---|---|
| public final int hash | |
| lock | back to summary |
|---|---|
| private final LockableObject lock | |
| modifiedExpandos | back to summary |
|---|---|
| private static final ManagedConcurrentLinkedQueue<ClassInfo> modifiedExpandos | |
| newMetaMethods | back to summary |
|---|---|
| pack-priv MetaMethod[] newMetaMethods | |
| perInstanceMetaClassMap | back to summary |
|---|---|
| private ManagedConcurrentMap<Object, MetaClass> perInstanceMetaClassMap | |
| softBundle | back to summary |
|---|---|
| private static final ReferenceBundle softBundle | |
| strongMetaClass | back to summary |
|---|---|
| private MetaClass strongMetaClass | |
| version | back to summary |
|---|---|
| private final AtomicInteger version | |
| weakBundle | back to summary |
|---|---|
| private static final ReferenceBundle weakBundle | |
| weakMetaClass | back to summary |
|---|---|
| private ManagedReference<MetaClass> weakMetaClass | |
| ClassInfo | back to summary |
|---|---|
| pack-priv ClassInfo(Class<T> klazz) | |
| clearModifiedExpandos | back to summary |
|---|---|
| public static void clearModifiedExpandos() | |
| createCachedClass | back to summary |
|---|---|
| private static CachedClass createCachedClass(Class<T> klazz, ClassInfo classInfo) | |
| finalizeReference | back to summary |
|---|---|
| public void finalizeReference() Implements org.
| |
| fullSize | back to summary |
|---|---|
| public static int fullSize() | |
| getAllClassInfo | back to summary |
|---|---|
| public static Collection | |
| getAllGlobalClassInfo | back to summary |
|---|---|
| private static Collection | |
| getArtifactClassLoader | back to summary |
|---|---|
| public ClassLoaderForClassArtifacts getArtifactClassLoader() | |
| getCachedClass | back to summary |
|---|---|
| public CachedClass getCachedClass() | |
| getClassInfo | back to summary |
|---|---|
| public static ClassInfo getClassInfo(Class<T> cls) | |
| getMetaClass | back to summary |
|---|---|
| public final MetaClass getMetaClass() Returns the
It is not safe to call this method without a
| |
| getMetaClass | back to summary |
|---|---|
| public MetaClass getMetaClass(Object obj) | |
| getMetaClassForClass | back to summary |
|---|---|
| public MetaClass getMetaClassForClass() | |
| getMetaClassUnderLock | back to summary |
|---|---|
| private MetaClass getMetaClassUnderLock() | |
| getModifiedExpando | back to summary |
|---|---|
| public ExpandoMetaClass getModifiedExpando() | |
| getPerInstanceMetaClass | back to summary |
|---|---|
| public MetaClass getPerInstanceMetaClass(Object obj) | |
| getStrongMetaClass | back to summary |
|---|---|
| public MetaClass getStrongMetaClass() | |
| getTheClass | back to summary |
|---|---|
| public final Class Returns the
This method can return
| |
| getVersion | back to summary |
|---|---|
| public int getVersion() | |
| getWeakMetaClass | back to summary |
|---|---|
| public MetaClass getWeakMetaClass() | |
| hasPerInstanceMetaClasses | back to summary |
|---|---|
| public boolean hasPerInstanceMetaClasses() | |
| incVersion | back to summary |
|---|---|
| public void incVersion() | |
| isSAM | back to summary |
|---|---|
| private static boolean isSAM(Class<?> c) | |
| isValidWeakMetaClass | back to summary |
|---|---|
| private static boolean isValidWeakMetaClass(MetaClass metaClass) | |
| isValidWeakMetaClass | back to summary |
|---|---|
| private static boolean isValidWeakMetaClass(MetaClass metaClass, MetaClassRegistry. if EMC.enableGlobally() is OFF, return whatever the cached answer is. but if EMC.enableGlobally() is ON and the cached answer is not an EMC, come up with a fresh answer | |
| lock | back to summary |
|---|---|
| public void lock() | |
| onAllClassInfo | back to summary |
|---|---|
| public static void onAllClassInfo(ClassInfo. | |
| remove | back to summary |
|---|---|
| public static void remove(Class<?> cls) Removes a
| |
| replaceWeakMetaClassRef | back to summary |
|---|---|
| private void replaceWeakMetaClassRef(ManagedReference<MetaClass> newRef) | |
| setPerInstanceMetaClass | back to summary |
|---|---|
| public void setPerInstanceMetaClass(Object obj, MetaClass metaClass) | |
| setStrongMetaClass | back to summary |
|---|---|
| public void setStrongMetaClass(MetaClass answer) | |
| setWeakMetaClass | back to summary |
|---|---|
| public void setWeakMetaClass(MetaClass answer) | |
| size | back to summary |
|---|---|
| public static int size() | |
| unlock | back to summary |
|---|---|
| public void unlock() | |
| Modifier and Type | Method and Description |
|---|---|
| public void |
| onClassInfo | back to summary |
|---|---|
| public void onClassInfo(ClassInfo classInfo) | |
| Modifier and Type | Field and Description |
|---|---|
| private final ManagedConcurrentLinkedQueue |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public int | |
| public int | |
| public Collection |
| items | back to summary |
|---|---|
| private final ManagedConcurrentLinkedQueue<ClassInfo> items | |
| GlobalClassSet | back to summary |
|---|---|
| private GlobalClassSet() | |
| add | back to summary |
|---|---|
| public void add(ClassInfo value) | |
| fullSize | back to summary |
|---|---|
| public int fullSize() | |
| size | back to summary |
|---|---|
| public int size() | |
| values | back to summary |
|---|---|
| public Collection | |
| Modifier and Type | Field and Description |
|---|---|
| private final ClassInfo | |
| private static final long |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public CachedClass |
| info | back to summary |
|---|---|
| private final ClassInfo info | |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID Hides org. | |
| LazyCachedClassRef | back to summary |
|---|---|
| pack-priv LazyCachedClassRef(ReferenceBundle bundle, ClassInfo info) | |
| initValue | back to summary |
|---|---|
| public CachedClass initValue() Implements abstract org. | |
| Modifier and Type | Field and Description |
|---|---|
| private final ClassInfo | |
| private static final long |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public ClassLoaderForClassArtifacts |
| info | back to summary |
|---|---|
| private final ClassInfo info | |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID Hides org. | |
| LazyClassLoaderRef | back to summary |
|---|---|
| pack-priv LazyClassLoaderRef(ReferenceBundle bundle, ClassInfo info) | |
| initValue | back to summary |
|---|---|
| public ClassLoaderForClassArtifacts initValue() Implements abstract org. | |