public class MockResourceOracle extends ResourceOracleImpl
Constructor and Description |
---|
MockResourceOracle(Resource... resources) |
Modifier and Type | Method and Description |
---|---|
void |
add(Resource... resources) |
void |
addOrReplace(Resource... resources) |
void |
clear()
Frees up all existing resources and transient internal state.
|
Set<String> |
getPathNames()
Returns an unmodifiable set of unique abstract path names with constant
lookup time.
|
Resource |
getResource(String pathName)
Returns the resource for the given path name or null if there is no such resource.
|
Set<Resource> |
getResources()
Returns an unmodifiable set of unique resources with constant lookup time.
|
void |
remove(String... paths) |
void |
replace(Resource... resources) |
clearCache, createEntryForUrl, getPathPrefixes, getSourceModulesByTypeSourceName, preload, preload, scanResources, setPathPrefixes
getResourceAsStream
public MockResourceOracle(Resource... resources)
public void add(Resource... resources)
public void addOrReplace(Resource... resources)
public void clear()
ResourceOracle
clear
in interface ResourceOracle
clear
in class ResourceOracleImpl
public Set<String> getPathNames()
ResourceOracle
getPathNames
in interface ResourceOracle
getPathNames
in class ResourceOracleImpl
public Resource getResource(String pathName)
ResourceOracle
getResource
in interface ResourceOracle
getResource
in class ResourceOracleImpl
public Set<Resource> getResources()
ResourceOracle
getResources
in interface ResourceOracle
getResources
in class ResourceOracleImpl
public void remove(String... paths)
public void replace(Resource... resources)
Copyright © 2018. All rights reserved.