| Modifier and Type | Class and Description |
|---|---|
| public static class | LoadedTypeInitializer.
A compound loaded type initializer that combines several type initializers. |
| public static class | LoadedTypeInitializer.
A type initializer for setting a value for a static field. |
| public static enum | LoadedTypeInitializer.
A loaded type initializer that does not do anything. |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | Returns: true if this initializer is alive.Indicates if this initializer is alive and needs to be invoked. |
| public void |
| isAlive | back to summary |
|---|---|
| public boolean isAlive() Indicates if this initializer is alive and needs to be invoked. This is only meant as a mark. A loaded type initializer that is not alive might still be called and must therefore not throw an exception but rather provide an empty implementation.
| |
| onLoad | back to summary |
|---|---|
| public void onLoad(Class<?> type) Callback that is invoked on the creation of an instrumented type. If the loaded type initializer is alive, this method should be implemented empty instead of throwing an exception.
| |
| Modifier and Type | Field and Description |
|---|---|
| private final List | loadedTypeInitializers
The loaded type initializers that are represented by this compound type initializer. |
| private static final long | serialVersionUID
This class's serial version UID. |
| Access | Constructor and Description |
|---|---|
| public | Compound(LoadedTypeInitializer...
A number of loaded type initializers in their invocation order. loadedTypeInitializer)Creates a new compound loaded type initializer. |
| public | Compound(List<? extends LoadedTypeInitializer>
A number of loaded type initializers in their invocation order. loadedTypeInitializers)Creates a new compound loaded type initializer. |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | isAlive()
Implements org. |
| public void | onLoad(Class<?>
The manifestation of the instrumented type. type)Implements org. |
| loadedTypeInitializers | back to summary |
|---|---|
| private final List<LoadedTypeInitializer> loadedTypeInitializers The loaded type initializers that are represented by this compound type initializer.
| |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID This class's serial version UID. | |
| Compound | back to summary |
|---|---|
| public Compound(LoadedTypeInitializer... loadedTypeInitializer) Creates a new compound loaded type initializer.
| |
| Compound | back to summary |
|---|---|
| public Compound(List<? extends LoadedTypeInitializer> loadedTypeInitializers) Creates a new compound loaded type initializer.
| |
| isAlive | back to summary |
|---|---|
| public boolean isAlive() Implements org. Doc from org. Indicates if this initializer is alive and needs to be invoked. This is only meant as a mark. A loaded type initializer that is not alive might still be called and must therefore not throw an exception but rather provide an empty implementation.
| |
| onLoad | back to summary |
|---|---|
| public void onLoad(Class<?> type) Implements org. Doc from org. Callback that is invoked on the creation of an instrumented type. If the loaded type initializer is alive, this method should be implemented empty instead of throwing an exception.
| |
| Modifier and Type | Field and Description |
|---|---|
| private final transient Object | accessControlContext
The access control context to use for loading classes or |
| private final String | fieldName
The name of the field. |
| private static final long | serialVersionUID
This class's serial version UID. |
| private final Object | value
The value of the field. |
| Access | Constructor and Description |
|---|---|
| public | ForStaticField(String
the name of the field. fieldName, Object The value to be set. value)Creates a new |
| Modifier and Type | Method and Description |
|---|---|
| private static < The type of the action's resolved value. T> T | Returns: The action's resolved value.The action to execute from a privileged context. action, Object The access control context or context)null if the current VM does not support it.A proxy for |
| private static Object | Returns: The current access control context ornull if the current VM does not support it.A proxy for |
| public boolean | isAlive()
Implements org. |
| public void | onLoad(Class<?>
The manifestation of the instrumented type. type)Implements org. |
| private Object | Returns: A resolved instance of this instance that includes an appropriate access control context.Resolves this instance after deserialization to assure the access control context is set. |
| accessControlContext | back to summary |
|---|---|
| private final transient Object accessControlContext The access control context to use for loading classes or | |
| fieldName | back to summary |
|---|---|
| private final String fieldName The name of the field. | |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID This class's serial version UID. | |
| value | back to summary |
|---|---|
| private final Object value The value of the field.
| |
| ForStaticField | back to summary |
|---|---|
| public ForStaticField(String fieldName, Object value) Creates a new | |
| doPrivileged | back to summary |
|---|---|
| private static <T> T doPrivileged(PrivilegedAction<T> action, Object context) A proxy for
| |
| getContext | back to summary |
|---|---|
| private static Object getContext() A proxy for
| |
| isAlive | back to summary |
|---|---|
| public boolean isAlive() Implements org. Doc from org. Indicates if this initializer is alive and needs to be invoked. This is only meant as a mark. A loaded type initializer that is not alive might still be called and must therefore not throw an exception but rather provide an empty implementation.
| |
| onLoad | back to summary |
|---|---|
| public void onLoad(Class<?> type) Implements org. Doc from org. Callback that is invoked on the creation of an instrumented type. If the loaded type initializer is alive, this method should be implemented empty instead of throwing an exception.
| |
| readResolve | back to summary |
|---|---|
| private Object readResolve() Resolves this instance after deserialization to assure the access control context is set.
| |
| Modifier and Type | Field and Description |
|---|---|
| public static final LoadedTypeInitializer. | INSTANCE
The singleton instance. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | isAlive()
Implements org. |
| public void | onLoad(Class<?>
The manifestation of the instrumented type. type)Implements org. |
| public static LoadedTypeInitializer. | |
| public static LoadedTypeInitializer. |
| INSTANCE | back to summary |
|---|---|
| public static final LoadedTypeInitializer. The singleton instance. | |
| NoOp | back to summary |
|---|---|
| private NoOp() | |
| isAlive | back to summary |
|---|---|
| public boolean isAlive() Implements org. Doc from org. Indicates if this initializer is alive and needs to be invoked. This is only meant as a mark. A loaded type initializer that is not alive might still be called and must therefore not throw an exception but rather provide an empty implementation.
| |
| onLoad | back to summary |
|---|---|
| public void onLoad(Class<?> type) Implements org. Doc from org. Callback that is invoked on the creation of an instrumented type. If the loaded type initializer is alive, this method should be implemented empty instead of throwing an exception.
| |
| valueOf | back to summary |
|---|---|
| public static LoadedTypeInitializer. | |
| values | back to summary |
|---|---|
| public static LoadedTypeInitializer. | |