|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SpecializableComposite
A composite that may be exposable as types in addition to those explicitly specified in the class declaration. For example, if some subset of the components of a composite all implement some interface that is not implemented by the composite itself, a new composite can be created that implements this interface that all the components implement. All that is needed is a method of choosing which component should perform the requested operation. This method of choosing is not specified by this interface; rather, this interface simply indicates that this composite may expose additional interfaces if those interfaces are implemented by some subset of the components of this composite.
Method Summary | |
---|---|
boolean |
isSpecializable(java.lang.Class type)
Indicates whether this composite can expose the given interface by dynamically creating a new composite. |
java.lang.Object |
specialize(java.lang.Class type)
Uses the components in this composite to dynamically create a composite that implements type . |
Method Detail |
---|
java.lang.Object specialize(java.lang.Class type) throws SpecializationException
type
.
type
- the interface to be exposed
SpecializationException
- if an error occurs while creating the new, specialized,
composite that implements the requested interfaceboolean isSpecializable(java.lang.Class type) throws SpecializationException
type
- the interface to be exposed
SpecializationException
- if an error occurrs
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |