public abstract class MockResourceLoader extends Object
| Modifier and Type | Class and Description |
|---|---|
class |
MockResourceLoader.VersionComparator |
| Modifier and Type | Field and Description |
|---|---|
static String |
VERSION_INVALID |
| Constructor and Description |
|---|
MockResourceLoader(String prefix) |
| Modifier and Type | Method and Description |
|---|---|
abstract MockResourceMeta |
createResourceMeta(String prefix,
String libraryName,
String libraryVersion,
String resourceName,
String resourceVersion) |
abstract String |
getLibraryVersion(String path)
Return the max available version found (if exists) or
return null if no version available.
|
String |
getPrefix() |
abstract InputStream |
getResourceInputStream(MockResourceMeta resourceMeta) |
abstract URL |
getResourceURL(MockResourceMeta resourceMeta)
Return the max available version found (if exists) or
return null if no version available.
|
abstract String |
getResourceVersion(String path) |
protected Comparator<String> |
getVersionComparator() |
abstract boolean |
libraryExists(String libraryName) |
void |
setPrefix(String prefix) |
protected void |
setVersionComparator(Comparator<String> versionComparator) |
public static final String VERSION_INVALID
public MockResourceLoader(String prefix)
public abstract String getLibraryVersion(String path)
public abstract URL getResourceURL(MockResourceMeta resourceMeta)
public abstract InputStream getResourceInputStream(MockResourceMeta resourceMeta)
public abstract MockResourceMeta createResourceMeta(String prefix, String libraryName, String libraryVersion, String resourceName, String resourceVersion)
public abstract boolean libraryExists(String libraryName)
protected Comparator<String> getVersionComparator()
protected void setVersionComparator(Comparator<String> versionComparator)
public String getPrefix()
public void setPrefix(String prefix)
Copyright © 2017 The Apache Software Foundation. All rights reserved.