org.apache.commons.clazz.reflect
Class ReflectedGroupClazzLoader
java.lang.Object
org.apache.commons.clazz.ClazzLoader
org.apache.commons.clazz.common.GroupClazzLoader
org.apache.commons.clazz.reflect.ReflectedGroupClazzLoader
- public class ReflectedGroupClazzLoader
- extends GroupClazzLoader
A clazz loader that groups multiple ReflectedClazzLoaders.
Its primary purpose is to optimize the methods that are executed the same way
by all ReflectedClazzLoaders, specifically the
getClazzName() method, which is always the same as the
corresponding class name
- Version:
- $Id: ReflectedGroupClazzLoader.java,v 1.6 2004/02/19 23:58:37 scolebourne Exp $
- Author:
- Dmitri Plotnikov
|
Method Summary |
boolean |
canAddClazzLoader(org.apache.commons.clazz.ClazzLoader loader)
Returns true if the supplied loader "belongs" in the group and can be
added to it. |
String |
getClazzName(Object instance)
Returns the clazz name for the supplied instance. |
boolean |
isMember(Object instance)
Returns true iff this group has a member loader that has or can construct
a Clazz for the supplied instance. |
| Methods inherited from class org.apache.commons.clazz.ClazzLoader |
enableLogging, getClazz, getModel, getModelClazzLoader, isLoggingEnabled |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ReflectedGroupClazzLoader
public ReflectedGroupClazzLoader(org.apache.commons.clazz.ModelClazzLoader modelClazzLoader)
canAddClazzLoader
public boolean canAddClazzLoader(org.apache.commons.clazz.ClazzLoader loader)
- Description copied from class:
GroupClazzLoader
- Returns true if the supplied loader "belongs" in the group and can be
added to it. The default implementation returns true.
- Overrides:
canAddClazzLoader in class GroupClazzLoader
isMember
public boolean isMember(Object instance)
- Description copied from class:
GroupClazzLoader
- Returns true iff this group has a member loader that has or can construct
a Clazz for the supplied instance.
- Overrides:
isMember in class GroupClazzLoader
- See Also:
ClazzLoader.isMember(java.lang.Object)
getClazzName
public String getClazzName(Object instance)
- Description copied from class:
org.apache.commons.clazz.ClazzLoader
- Returns the clazz name for the supplied instance. Returns
null if it cannot produce a clazz name for the instance.
- Overrides:
getClazzName in class GroupClazzLoader
- See Also:
ClazzLoader.getClazzName(java.lang.Object)
Copyright © 2002-2005 The Apache Software Foundation. All Rights Reserved.