org.apache.commons.classscan.builtin
Class DefaultMetaClassPathElement

java.lang.Object
  extended by org.apache.commons.classscan.builtin.DefaultMetaClassPathElement
All Implemented Interfaces:
HasName, MetaClassPathElement, HasResolve, SpiMetaClassPathElement

public class DefaultMetaClassPathElement
extends Object
implements SpiMetaClassPathElement


Constructor Summary
DefaultMetaClassPathElement(SpiMetaRegistry metaRegistry, ClassPathElement classPathElement)
           
 
Method Summary
 MetaClass getMetaClass(String className)
          Get metadata about a Class which is available in the code location.
 Collection<? extends MetaClass> getMetaClasses()
          Get metadata about the Classes which are available in the code location.
 String getName()
          Get the name of the location of the jar or folder.
 boolean resolve(SpiMetaClassLoader classLoader)
          Resolve names into model entries
 MetaClass resolveMetaClass(SpiMetaClassLoader classLoader, String className)
          Find and resolve a MetaClass.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultMetaClassPathElement

public DefaultMetaClassPathElement(SpiMetaRegistry metaRegistry,
                                   ClassPathElement classPathElement)
Method Detail

resolve

public boolean resolve(SpiMetaClassLoader classLoader)
Description copied from interface: HasResolve
Resolve names into model entries

Specified by:
resolve in interface HasResolve

resolveMetaClass

public MetaClass resolveMetaClass(SpiMetaClassLoader classLoader,
                                  String className)
Description copied from interface: SpiMetaClassPathElement
Find and resolve a MetaClass. Resolving a MetaClass changes String classnames and types into references to the MetaClasses.

Specified by:
resolveMetaClass in interface SpiMetaClassPathElement
Parameters:
classLoader - The metadata locus for a ClassLoader
className - The canonical name of the class to resolve
Returns:
The completely resolved MetaClass; or null, if resolution was unsuccessful.

getMetaClasses

public Collection<? extends MetaClass> getMetaClasses()
Description copied from interface: MetaClassPathElement
Get metadata about the Classes which are available in the code location.

Specified by:
getMetaClasses in interface MetaClassPathElement
Returns:
A read-only collection of class information

getMetaClass

public MetaClass getMetaClass(String className)
Description copied from interface: MetaClassPathElement
Get metadata about a Class which is available in the code location.

Specified by:
getMetaClass in interface MetaClassPathElement
Parameters:
className - The canonical className of the desired Class
Returns:
The class information; or null, if class of given name not available at this location

getName

public String getName()
Description copied from interface: MetaClassPathElement
Get the name of the location of the jar or folder. This name can be used as the parameter to the URI or URL constructor.

Specified by:
getName in interface HasName
Specified by:
getName in interface MetaClassPathElement


Copyright © 2012 The Apache Software Foundation. All Rights Reserved.