Top Description Fields Constructors Methods
org.codehaus.groovy.reflection.v7

public Class GroovyClassValueJava7<T>

extends ClassValue<T>
implements GroovyClassValue<T>
Class Inheritance
All Implemented Interfaces
org.codehaus.groovy.reflection.GroovyClassValue
Imports
org.codehaus.groovy.reflection.GroovyClassValue

GroovyClassValue implementaion that simply delegates to Java 7's java.lang.ClassValue
See Also
java.lang.ClassValue

Field Summary

Modifier and TypeField and Description
private final GroovyClassValue.ComputeValue<T>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
protected T
computeValue(Class<?>
the type whose class value must be computed
type
)

Implements abstract java.lang.ClassValue.computeValue.

Computes the given class's derived value for this ClassValue.
Inherited from java.lang.ClassValue:
getremove

Field Detail

computeValueback to summary
private final GroovyClassValue.ComputeValue<T> computeValue

Constructor Detail

GroovyClassValueJava7back to summary
public GroovyClassValueJava7(GroovyClassValue.ComputeValue<T> computeValue)

Method Detail

computeValueback to summary
protected T computeValue(Class<?> type)

Implements abstract java.lang.ClassValue.computeValue.

Doc from java.lang.ClassValue.computeValue.

Computes the given class's derived value for this ClassValue.

This method will be invoked within the first thread that accesses the value with the get method.

Normally, this method is invoked at most once per class, but it may be invoked again if there has been a call to remove.

If this method throws an exception, the corresponding call to get will terminate abnormally with that exception, and no class value will be recorded.

Parameters
type:Class<?>

the type whose class value must be computed

Returns:T

the newly computed value associated with this ClassValue, for the given class or interface

Annotations
@Override