ClassPathScanner
public
class
ClassPathScanner
extends Object
java.lang.Object | |
↳ | com.android.tradefed.util.ClassPathScanner |
Finds entries on classpath.
Adapted from vogar.target.ClassPathScanner
Summary
Nested classes | |
---|---|
class |
ClassPathScanner.ClassNameFilter
A |
class |
ClassPathScanner.ExternalClassNameFilter
A |
interface |
ClassPathScanner.IClassPathFilter
A filter for classpath entry paths Patterned afterFileFilter
|
Public constructors | |
---|---|
ClassPathScanner()
|
Public methods | |
---|---|
static
String[]
|
getClassPath()
Gets the class path from the System Property "java.class.path" and splits it up into the individual elements. |
|
getClassPathEntries(ClassPathScanner.IClassPathFilter filter)
Retrieves set of classpath entries that match given |
|
getClassPathEntriesFromJar(ClassPathScanner.IClassPathFilter filter)
Retrieves set of classpath entries that match given |
|
getEntriesFromDir(File classPathDir, ClassPathScanner.IClassPathFilter filter)
Gets the names of all entries contained in given class path directory, that match given filter |
|
getEntriesFromJar(File plainFile, ClassPathScanner.IClassPathFilter filter)
Gets the names of all entries contained in given jar file, that match given filter |
Public constructors
ClassPathScanner
public ClassPathScanner ()
Public methods
getClassPath
public static String[] getClassPath ()
Gets the class path from the System Property "java.class.path" and splits it up into the individual elements.
Returns | |
---|---|
String[] |
getClassPathEntries
publicgetClassPathEntries (ClassPathScanner.IClassPathFilter filter)
Retrieves set of classpath entries that match given IClassPathFilter
Parameters | |
---|---|
filter |
ClassPathScanner.IClassPathFilter |
Returns | |
---|---|
|
getClassPathEntriesFromJar
publicgetClassPathEntriesFromJar (ClassPathScanner.IClassPathFilter filter)
Retrieves set of classpath entries that match given IClassPathFilter
and returns them
with which JAR they come from. Used to validate origin of files.
Parameters | |
---|---|
filter |
ClassPathScanner.IClassPathFilter |
Returns | |
---|---|
|
getEntriesFromDir
publicgetEntriesFromDir (File classPathDir, ClassPathScanner.IClassPathFilter filter)
Gets the names of all entries contained in given class path directory, that match given filter
Parameters | |
---|---|
classPathDir |
File |
filter |
ClassPathScanner.IClassPathFilter |
Returns | |
---|---|
|
getEntriesFromJar
publicgetEntriesFromJar (File plainFile, ClassPathScanner.IClassPathFilter filter)
Gets the names of all entries contained in given jar file, that match given filter
Parameters | |
---|---|
plainFile |
File |
filter |
ClassPathScanner.IClassPathFilter |
Returns | |
---|---|
|
Nội dung và mã mẫu trên trang này phải tuân thủ các giấy phép như mô tả trong phần Giấy phép nội dung. Java và OpenJDK là nhãn hiệu hoặc nhãn hiệu đã đăng ký của Oracle và/hoặc đơn vị liên kết của Oracle.
Cập nhật lần gần đây nhất: 2020-09-08 UTC.