类 ClassLoaderFiles
- java.lang.Object
- org.springframework.boot.devtools.restart.classloader.ClassLoaderFiles
- 所有已实现的接口:
Serializable,ClassLoaderFileRepository
public class ClassLoaderFiles extends Object implements ClassLoaderFileRepository, Serializable
ClassLoaderFileRepositorythat maintains a collection ofClassLoaderFileitems grouped by source folders.- 从以下版本开始:
- 1.3.0
- 另请参阅:
ClassLoaderFile,ClassLoaderRepository, 序列化表格
嵌套类概要
嵌套类 修饰符和类型 类 说明 static classClassLoaderFiles.SourceFolderAn individual source folder that is being managed by the collection.
字段概要
从接口继承的字段 org.springframework.boot.devtools.restart.classloader.ClassLoaderFileRepository
NONE
构造器概要
构造器 构造器 说明 ClassLoaderFiles()Create a newClassLoaderFilesinstance.ClassLoaderFiles(ClassLoaderFiles classLoaderFiles)Create a newClassLoaderFilesinstance.
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 voidaddAll(ClassLoaderFiles files)Add all elements items from the specifiedClassLoaderFilesto this instance.voidaddFile(String sourceFolder, String name, ClassLoaderFile file)Add a singleClassLoaderFileto the collection.voidaddFile(String name, ClassLoaderFile file)Add a singleClassLoaderFileto the collection.ClassLoaderFilegetFile(String name)Return aClassLoaderFilefor the given name ornullif no file is contained in this collection.protected ClassLoaderFiles.SourceFoldergetOrCreateSourceFolder(String name)Get or create aClassLoaderFiles.SourceFolderwith the given name.Collection<ClassLoaderFiles.SourceFolder>getSourceFolders()Return allSourceFoldersthat have been added to the collection.intsize()Return the size of the collection.
构造器详细资料
ClassLoaderFiles
public ClassLoaderFiles()
Create a newClassLoaderFilesinstance.
ClassLoaderFiles
public ClassLoaderFiles(ClassLoaderFiles classLoaderFiles)
Create a newClassLoaderFilesinstance.- 参数:
classLoaderFiles- the source classloader files.
方法详细资料
addAll
public void addAll(ClassLoaderFiles files)
Add all elements items from the specifiedClassLoaderFilesto this instance.- 参数:
files- the files to add
addFile
public void addFile(String name, ClassLoaderFile file)
Add a singleClassLoaderFileto the collection.- 参数:
name- the name of the filefile- the file to add
addFile
public void addFile(String sourceFolder, String name, ClassLoaderFile file)
Add a singleClassLoaderFileto the collection.- 参数:
sourceFolder- the source folder of the filename- the name of the filefile- the file to add
getOrCreateSourceFolder
protected final ClassLoaderFiles.SourceFolder getOrCreateSourceFolder(String name)
Get or create aClassLoaderFiles.SourceFolderwith the given name.- 参数:
name- the name of the folder- 返回:
- an existing or newly added
ClassLoaderFiles.SourceFolder
getSourceFolders
public Collection<ClassLoaderFiles.SourceFolder> getSourceFolders()
Return allSourceFoldersthat have been added to the collection.- 返回:
- a collection of
ClassLoaderFiles.SourceFolderitems
size
public int size()
Return the size of the collection.- 返回:
- the size of the collection
getFile
public ClassLoaderFile getFile(String name)
从接口复制的说明:ClassLoaderFileRepositoryReturn aClassLoaderFilefor the given name ornullif no file is contained in this collection.- 指定者:
getFile在接口中ClassLoaderFileRepository- 参数:
name- the name of the file- 返回:
- a
ClassLoaderFileornull