ClassPathScanner

public class ClassPathScanner
extends Object

java.lang.Object
   ↳ com.android.tradefed.util.ClassPathScanner


חיפוש רשומות בנתיב המחלקה.

מבוסס על vogar.target.ClassPathScanner

סיכום

כיתות מוטמעות

class ClassPathScanner.ClassNameFilter

IClassPathFilter שמסנן ומשנה שמות של מחלקות Java. 

class ClassPathScanner.ExternalClassNameFilter

ClassNameFilter שמבצע דחייה של מחלקות פנימיות 

interface ClassPathScanner.IClassPathFilter

מסנן לנתיבי רשומות ב-classpath

הדפס של FileFilter 

‫constructors ציבוריים

ClassPathScanner()

‫methods ציבוריים

static String[] getClassPath()

מקבל את נתיב הכיתה ממאפיין המערכת java.class.path ומפצל אותו לרכיבים נפרדים.

Set<String> getClassPathEntries(ClassPathScanner.IClassPathFilter filter)

מחזירה קבוצה של רשומות בנתיב המחלקות שתואמות ל-IClassPathFilter

Map<String, String> getClassPathEntriesFromJar(ClassPathScanner.IClassPathFilter filter)

מאחזרת קבוצה של רשומות בנתיב המחלקה שתואמות ל-IClassPathFilter הנתון ומחזירה אותן עם קובץ ה-JAR שממנו הן מגיעות.

Set<String> getEntriesFromDir(File classPathDir, ClassPathScanner.IClassPathFilter filter)

מקבל את השמות של כל הרשומות שנמצאות בספרייה של נתיב המחלקה הנתון, שתואמות למסנן הנתון

Map<String, String> getEntriesFromJar(File plainFile, ClassPathScanner.IClassPathFilter filter)

מחזירה את השמות של כל הרשומות שכלולות בקובץ jar נתון, שתואמות למסנן נתון

‫constructors ציבוריים

ClassPathScanner

public ClassPathScanner ()

‫methods ציבוריים

getClassPath

public static String[] getClassPath ()

מקבל את נתיב הכיתה ממאפיין המערכת java.class.path ומפצל אותו לרכיבים נפרדים.

החזרות
String[]

getClassPathEntries

public Set<String> getClassPathEntries (ClassPathScanner.IClassPathFilter filter)

מחזירה קבוצה של רשומות בנתיב המחלקות שתואמות ל-IClassPathFilter

פרמטרים
filter ClassPathScanner.IClassPathFilter

החזרות
Set<String>

getClassPathEntriesFromJar

public Map<String, String> getClassPathEntriesFromJar (ClassPathScanner.IClassPathFilter filter)

מאחזרת קבוצה של רשומות בנתיב המחלקה שתואמות ל-IClassPathFilter הנתון ומחזירה אותן עם קובץ ה-JAR שממנו הן מגיעות. משמש לאימות המקור של הקבצים.

פרמטרים
filter ClassPathScanner.IClassPathFilter

החזרות
Map<String, String>

getEntriesFromDir

public Set<String> getEntriesFromDir (File classPathDir, 
                ClassPathScanner.IClassPathFilter filter)

מקבל את השמות של כל הרשומות שנמצאות בספרייה של נתיב המחלקה הנתון, שתואמות למסנן הנתון

פרמטרים
classPathDir File

filter ClassPathScanner.IClassPathFilter

החזרות
Set<String>

הקפצת הודעות שגיאה (throw)
java.io.IOException
IOException

getEntriesFromJar

public Map<String, String> getEntriesFromJar (File plainFile, 
                ClassPathScanner.IClassPathFilter filter)

מחזירה את השמות של כל הרשומות שכלולות בקובץ jar נתון, שתואמות למסנן נתון

פרמטרים
plainFile File

filter ClassPathScanner.IClassPathFilter

החזרות
Map<String, String>

הקפצת הודעות שגיאה (throw)
java.io.IOException
IOException