public final class URLBasedResource extends AbstractResource
| Constructor and Description |
|---|
URLBasedResource(URL baseURL,
String contentPath) |
| Modifier and Type | Method and Description |
|---|---|
<T> T |
addAttachment(Class<T> clazz,
T value)
Attach an arbirtary object with this element.
|
<T> T |
getAttachment(Class<T> clazz)
Get the attached object for a given key
|
InputStream |
getContent() |
String |
getContentPath() |
URL |
getContentURL() |
<T> T |
removeAttachment(Class<T> clazz)
Remove an attached object for a given key
|
addCapability, addRequirement, getCapabilities, getIdentityCapability, getRequirements, isFragment, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddAttachment, getAttachment, removeAttachmentpublic URL getContentURL()
public String getContentPath()
public InputStream getContent()
getContent in interface XResourcegetContent in class AbstractResourcepublic <T> T addAttachment(Class<T> clazz, T value)
XAttachmentSupportaddAttachment in interface XAttachmentSupportclazz - key for the attachmentpublic <T> T getAttachment(Class<T> clazz)
XAttachmentSupportgetAttachment in interface XAttachmentSupportclazz - key for the attachmentpublic <T> T removeAttachment(Class<T> clazz)
XAttachmentSupportremoveAttachment in interface XAttachmentSupportclazz - key for the attachmentCopyright © 2012 JBoss by Red Hat. All Rights Reserved.