|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.discovery.tools.SPInterface
public class SPInterface
Represents a Service Programming Interface (spi). - SPI's name - SPI's (provider) class - SPI's (alternate) override property name In addition, while there are many cases where this is NOT usefull, for those in which it is: - expected constructor argument types and parameters values.
Constructor Summary | |
---|---|
SPInterface(Class provider)
Construct object representing Class provider . |
|
SPInterface(Class provider,
Class[] constructorParamClasses,
Object[] constructorParams)
Construct object representing Class provider . |
|
SPInterface(Class spi,
String propertyName)
Construct object representing Class provider . |
|
SPInterface(Class spi,
String propertyName,
Class[] constructorParamClasses,
Object[] constructorParams)
Construct object representing Class provider . |
Method Summary | |
---|---|
String |
getPropertyName()
|
Class |
getSPClass()
|
String |
getSPName()
|
Object |
newInstance(Class impl)
Instantiate a new |
void |
verifyAncestory(Class impl)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SPInterface(Class provider)
provider
.
provider
- The SPI classpublic SPInterface(Class spi, String propertyName)
provider
.
spi
- The SPI classpropertyName
- when looking for the name of a class implementing
the provider class, a discovery strategy may involve looking for
(system or other) properties having either the name of the class
(provider) or the propertyName
.public SPInterface(Class provider, Class[] constructorParamClasses, Object[] constructorParams)
provider
.
provider
- The SPI classconstructorParamClasses
- classes representing the
constructor argument types.constructorParams
- objects representing the
constructor arguments.public SPInterface(Class spi, String propertyName, Class[] constructorParamClasses, Object[] constructorParams)
provider
.
spi
- The SPI classpropertyName
- when looking for the name of a class implementing
the provider class, a discovery strategy may involve looking for
(system or other) properties having either the name of the class
(provider) or the propertyName
.constructorParamClasses
- classes representing the
constructor argument types.constructorParams
- objects representing the
constructor arguments.Method Detail |
---|
public String getSPName()
public Class getSPClass()
public String getPropertyName()
public Object newInstance(Class impl) throws DiscoveryException, InstantiationException, IllegalAccessException, NoSuchMethodException, InvocationTargetException
DiscoveryException
InstantiationException
IllegalAccessException
NoSuchMethodException
InvocationTargetException
public void verifyAncestory(Class impl)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |