org.apache.commons.classscan
Interface ClassPathElement

All Superinterfaces:
Iterable<ClassFile>
All Known Subinterfaces:
SpiClassPathElement
All Known Implementing Classes:
FileClassPathElement, JarClassPathElement

public interface ClassPathElement
extends Iterable<ClassFile>

A single location in a ClassPath. The location might be a jar or a directory. In enterprise application environments, the location might be an exploded ear or a war.


Method Summary
 String getLocation()
          Get the location of the class bytes.
 ResourceFile getResource(String fileName)
          Get a file with a particular name
 Iterator<ClassFile> iterator()
          Get a Iterator over the files specified by this instance
 

Method Detail

iterator

Iterator<ClassFile> iterator()
Get a Iterator over the files specified by this instance

Specified by:
iterator in interface Iterable<ClassFile>

getLocation

String getLocation()
Get the location of the class bytes. This value is intended to be used as an argument to the URL constructor.


getResource

ResourceFile getResource(String fileName)
Get a file with a particular name

Parameters:
fileName - The name of the desired file (this may be a path such as META-INF/resources/com.example.group.interface)
Returns:
null, if not found; otherwise the ResourceFile


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