public interface TransientAttachments
Modifier and Type | Method and Description |
---|---|
<T> T |
getTransientAttachment(Class<T> expectedType)
Get an attachment from the parameter,
uses the expected type as both the name
and to cast the resulting object.
|
Object |
getTransientAttachment(String name)
Get a transient attachment from the parameter.
|
void |
setTransientAttachment(String name,
Object attachment)
Set an transient attachment against the parameter.
|
Object getTransientAttachment(String name)
name
- the namesetTransientAttachment(String, Object)
<T> T getTransientAttachment(Class<T> expectedType)
T
- the expected typeexpectedType
- the expected typeClassCastException
- when the object is not of the expected typevoid setTransientAttachment(String name, Object attachment)
name
- the nameattachment
- the attachment, pass null to remove an attachmentIllegalArgumentException
- for a null nameCopyright © 2013 JBoss, a division of Red Hat, Inc.. All Rights Reserved.