|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.avalon.meta.info.verifier.TypeVerifier
Utility class to help verify that component respects the rules of an Avalon component.
Constructor Summary | |
TypeVerifier()
|
Method Summary | |
void |
verifyClass(String name,
Class clazz)
Verify that the supplied class is a valid class for a Component. |
void |
verifyImplementsServices(String name,
Class implementation,
Class[] services)
Verify that the supplied implementation implements the specified services. |
void |
verifyLifecycles(String name,
Class implementation)
Verify that the implementation class does not implement incompatible lifecycle interfaces. |
void |
verifyNonAbstract(String name,
Class clazz)
Verify that the component is not represented by abstract class. |
void |
verifyNonArray(String name,
Class clazz)
Verify that the component is not represented by an array class. |
void |
verifyNonInterface(String name,
Class clazz)
Verify that the component is not represented by interface class. |
void |
verifyNonPrimitive(String name,
Class clazz)
Verify that the component is not represented by primitive class. |
void |
verifyPublic(String name,
Class clazz)
Verify that the component is not represented by abstract class. |
void |
verifyPublicConstructor(String name,
Class clazz)
Verify that the component has a no-arg aka default constructor. |
void |
verifyService(String name,
Class clazz)
Verify that the supplied class is a valid class for a service. |
void |
verifyServiceIsaInterface(String name,
Class clazz)
Verify that the service implemented by specified component is an interface. |
void |
verifyServiceIsPublic(String name,
Class clazz)
Verify that the service implemented by specified component is public. |
void |
verifyServiceNotALifecycle(String name,
Class clazz)
Verify that the service implemented by specified component does not extend any lifecycle interfaces. |
void |
verifyServices(String name,
Class[] classes)
Verify that the supplied classes are valid classes for a service. |
void |
verifyType(String name,
Class implementation,
Class[] services)
Verify that the supplied implementation class and service classes are valid for a component. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TypeVerifier()
Method Detail |
public void verifyType(String name, Class implementation, Class[] services) throws VerifyException
name
- the name of componentimplementation
- the implementation class of componentservices
- the classes representing services
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyImplementsServices(String name, Class implementation, Class[] services) throws VerifyException
name
- the name of componentimplementation
- the class representign componentservices
- the services that the implementation must provide
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyClass(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representing component
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyServices(String name, Class[] classes) throws VerifyException
name
- the name of componentclasses
- the classes representign services
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyService(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign service
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyLifecycles(String name, Class implementation) throws VerifyException
name
- the name of componentimplementation
- the implementation class
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyServiceIsaInterface(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign service
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyServiceIsPublic(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign service
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyServiceNotALifecycle(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign service
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyPublicConstructor(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign component
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyNonAbstract(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign component
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyPublic(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign component
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyNonPrimitive(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign component
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyNonInterface(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign component
VerifyException
- if error thrown on failure and
component fails checkpublic void verifyNonArray(String name, Class clazz) throws VerifyException
name
- the name of componentclazz
- the class representign component
VerifyException
- if error thrown on failure and
component fails check
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |