public abstract class ClasspathServiceBase extends Object implements ClasspathService
ClasspathService
. Keeps the classpath entries mapped to their paths for
access convenience purposes, relies onto ClasspathEntriesResolver
in preparing such mappings.ClasspathService.ClasspathEntryNotFoundException
Constructor and Description |
---|
ClasspathServiceBase(ClasspathServiceConfiguration configuration,
ClasspathEntriesResolver classpathEntriesResolver) |
Modifier and Type | Method and Description |
---|---|
protected void |
addMappings(Map<String,ClasspathEntry> newMappings) |
protected void |
clearAllMappings() |
protected Map<String,ClasspathEntry> |
getClasspathEntryMappings() |
ClasspathServiceConfiguration |
getConfiguration()
Get configuration of the current
service . |
ClasspathEntry |
getEntryAt(String path)
Get
classpath entry corresponding to a given path. |
ClasspathDirectory |
getParent(ClasspathEntry classpathEntry)
Get parent directory of a
classpath entry . |
ClasspathDirectory |
getRoot()
Get the root directory of the current service classpath hierarchy structure.
|
boolean |
hasEntry(String path)
Check whether current service classpath structure contains an
entry
which corresponds to a given path. |
protected Map<String,ClasspathEntry> |
resolveResources() |
public ClasspathServiceBase(ClasspathServiceConfiguration configuration, ClasspathEntriesResolver classpathEntriesResolver)
protected Map<String,ClasspathEntry> resolveResources()
public ClasspathDirectory getRoot()
ClasspathService
/
.getRoot
in interface ClasspathService
public ClasspathServiceConfiguration getConfiguration()
ClasspathService
service
.getConfiguration
in interface ClasspathService
public ClasspathDirectory getParent(ClasspathEntry classpathEntry)
ClasspathService
classpath entry
.getParent
in interface ClasspathService
public ClasspathEntry getEntryAt(String path)
ClasspathService
classpath entry
corresponding to a given path.getEntryAt
in interface ClasspathService
path
- absolute path of a classpath entryClasspathEntry
objectpublic boolean hasEntry(String path)
ClasspathService
entry
which corresponds to a given path.hasEntry
in interface ClasspathService
protected final void addMappings(Map<String,ClasspathEntry> newMappings)
protected final void clearAllMappings()
protected final Map<String,ClasspathEntry> getClasspathEntryMappings()
Copyright © 2003–2018 Magnolia International Ltd.. All rights reserved.