Top Description Methods
org.glassfish.hk2.api

public Interface HK2Invocation


This is an interface that is also implemented by the org.aopalliance.intercept.MethodInvocation object passed to the invoke method of org.aopalliance.intercept.MethodInterceptor and the org.aopalliance.intercept.ConstructorInvocation object passed to the invoke method of org.aopalliance.intercept.ConstructorInterceptor. It allows HK2 users of the AOP interception feature to easily pass data between interceptors on the same invocatio stack
Author
jwells

Method Summary

Modifier and TypeMethod and Description
public Object

Returns:

The user data previously associated with this key, or null if there was no user data associated with this key
getUserData
(String
The key for which to get data. May not be null
key
)

Gets the user data associated with the given key

public void
setUserData(String
a non-null identifier for user data to be associated with the invocation frame
key
,
Object
possibly null data. If non-null it will replace any value previously associated with the key. If null it will remove the key from the map
data
)

Sets the user data to be associated with the invocation frame.

Method Detail

getUserDataback to summary
public Object getUserData(String key)

Gets the user data associated with the given key

Parameters
key:String

The key for which to get data. May not be null

Returns:Object

The user data previously associated with this key, or null if there was no user data associated with this key

setUserDataback to summary
public void setUserData(String key, Object data)

Sets the user data to be associated with the invocation frame. The key may not be null. If data is null then the data associated with the key is removed

Parameters
key:String

a non-null identifier for user data to be associated with the invocation frame

data:Object

possibly null data. If non-null it will replace any value previously associated with the key. If null it will remove the key from the map