|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.composite.composites.BaseComposite
net.sf.composite.composites.CompositeDecorator
public class CompositeDecorator
Wraps a SimpleComposite so that it implements the ListableComposite and SpecializableComposite interfaces.
| Constructor Summary | |
|---|---|
CompositeDecorator()
Creates a new composite decorator. |
|
CompositeDecorator(SimpleComposite composite)
Creates a new composite that decorates the given composite. |
|
| Method Summary | |
|---|---|
java.lang.Object[] |
getComponents()
Retrieves the components of the underlying composite. |
SimpleComposite |
getComposite()
|
boolean |
isSpecializable(java.lang.Class type)
Indicates whether this composite can expose the given interface by dynamically creating a new composite. |
void |
setComponents(java.lang.Object[] components)
Sets the components of the underlying compmosite |
void |
setComposite(SimpleComposite composite)
|
java.lang.Object |
specialize(java.lang.Class type)
Uses the components in this composite to dynamically create a composite that implements type. |
| Methods inherited from class net.sf.composite.composites.BaseComposite |
|---|
containsComponentOfType, getComponentsOfType, getComponentType, getComponentValidator, getSpecializer, initializeImpl, setComponent, setComponentValidator, setSpecializer, validate |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CompositeDecorator()
setComposite(SimpleComposite)method
must be called
public CompositeDecorator(SimpleComposite composite)
composite - the composite to be decorated.| Method Detail |
|---|
public boolean isSpecializable(java.lang.Class type)
throws SpecializationException
SpecializableComposite
isSpecializable in interface SpecializableCompositeisSpecializable in class BaseCompositetype - the interface to be exposed
SpecializationException - if an error occurrs
public java.lang.Object specialize(java.lang.Class type)
throws SpecializationException
SpecializableCompositetype.
specialize in interface SpecializableCompositespecialize in class BaseCompositetype - the interface to be exposed
SpecializationException - if an error occurs while creating the new, specialized,
composite that implements the requested interfacepublic SimpleComposite getComposite()
public void setComposite(SimpleComposite composite)
public java.lang.Object[] getComponents()
getComponents in interface SimpleCompositegetComponents in class BaseCompositepublic void setComponents(java.lang.Object[] components)
setComponents in interface SimpleCompositesetComponents in class BaseCompositecomponents - the new components that will make up the underlying composite
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||