public abstract class AbstractExtensible extends Object implements Extensible
| Constructor and Description |
|---|
AbstractExtensible() |
AbstractExtensible(int initialAttachmentsSize,
int initialPropertiesSize) |
| Modifier and Type | Method and Description |
|---|---|
<T> T |
addAttachment(Class<T> clazz,
Object obj)
Add arbitrary attachments
|
<T> T |
getAttachment(Class<T> clazz)
Get an arbitrary attachment
|
Collection<Object> |
getAttachments()
Get arbitrary attachments
|
Set<String> |
getProperties()
Get the set of property names
|
Object |
getProperty(String key)
Get an property
|
<T> T |
removeAttachment(Class<T> key)
Remove arbitrary attachments
|
void |
removeProperty(String key)
Remove a property
|
void |
setProperties(Map<String,Object> props)
Set a map of properties
|
void |
setProperty(String key,
Object value)
Set a property
|
public AbstractExtensible()
public AbstractExtensible(int initialAttachmentsSize,
int initialPropertiesSize)
public Collection<Object> getAttachments()
ExtensiblegetAttachments in interface Extensiblepublic <T> T getAttachment(Class<T> clazz)
ExtensiblegetAttachment in interface ExtensibleT - class type of attachmentsclazz - identifierpublic <T> T addAttachment(Class<T> clazz, Object obj)
ExtensibleaddAttachment in interface ExtensibleT - class typeclazz - identifierobj - valuepublic <T> T removeAttachment(Class<T> key)
ExtensibleremoveAttachment in interface ExtensibleT - class type of attachmentskey - identifierpublic Set<String> getProperties()
ExtensiblegetProperties in interface Extensiblepublic Object getProperty(String key)
ExtensiblegetProperty in interface Extensiblekey - property identifierpublic void removeProperty(String key)
ExtensibleremoveProperty in interface Extensiblekey - property identifierpublic void setProperty(String key, Object value)
ExtensiblesetProperty in interface Extensiblekey - property identifiervalue - property valuepublic void setProperties(Map<String,Object> props)
ExtensiblesetProperties in interface Extensibleprops - map to retainCopyright © 2015 JBoss, by Red Hat. All rights reserved.