public class AbstractDynamicPackageRequirement extends AbstractPackageRequirement
XPackageRequirement
.Constructor and Description |
---|
AbstractDynamicPackageRequirement(AbstractModule module,
String name,
Map<String,String> dirs,
Map<String,Object> atts) |
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
|
Object |
getAttribute(String key)
Get the value of the given attribute
|
Map<String,Object> |
getAttributes()
Get the attributes
|
String |
getDirective(String key)
Get the value of the given directive
|
Map<String,String> |
getDirectives()
Get the directives
|
XModule |
getModule()
Get associated module.
|
String |
getName()
Get the name for this capability.
|
XCapability |
getWiredCapability()
Get the wired capbillity for this requirement.
|
boolean |
isDynamic()
True if this is a dynamic requirement.
|
boolean |
isOptional()
True if this requirement is optional
|
boolean |
matchPackageName(XPackageCapability cap) |
<T> T |
removeAttachment(Class<T> clazz)
Remove an attached object for a given key
|
String |
toString() |
getBundleSymbolicName, getBundleVersion, getResolution, getVersionRange, match
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
isDynamic
getModule, getWiredCapability, isOptional
getAttribute, getAttributes
getDirective, getDirectives
addAttachment, getAttachment, removeAttachment
public boolean matchPackageName(XPackageCapability cap)
matchPackageName
in class AbstractPackageRequirement
public String toString()
toString
in class AbstractPackageRequirement
public XModule getModule()
XRequirement
getModule
in interface XRequirement
public boolean isOptional()
XRequirement
isOptional
in interface XRequirement
public boolean isDynamic()
XRequirement
isDynamic
in interface XRequirement
public XCapability getWiredCapability()
XRequirement
getWiredCapability
in interface XRequirement
public Object getAttribute(String key)
XAttributeSupport
getAttribute
in interface XAttributeSupport
public Map<String,Object> getAttributes()
XAttributeSupport
getAttributes
in interface XAttributeSupport
public String getDirective(String key)
XDirectiveSupport
getDirective
in interface XDirectiveSupport
public Map<String,String> getDirectives()
XDirectiveSupport
getDirectives
in interface XDirectiveSupport
public <T> T addAttachment(Class<T> clazz, T value)
XAttachmentSupport
addAttachment
in interface XAttachmentSupport
clazz
- key for the attachmentpublic <T> T getAttachment(Class<T> clazz)
XAttachmentSupport
getAttachment
in interface XAttachmentSupport
clazz
- key for the attachmentpublic <T> T removeAttachment(Class<T> clazz)
XAttachmentSupport
removeAttachment
in interface XAttachmentSupport
clazz
- key for the attachmentCopyright © 2012 JBoss by Red Hat. All Rights Reserved.