@ThreadSafe public class FileSystemResourceProvider extends Object implements IWritableResourceProvider
| Constructor and Description |
|---|
FileSystemResourceProvider() |
FileSystemResourceProvider(File aBasePath) |
FileSystemResourceProvider(String sBasePath) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
File |
getBasePath() |
IReadableResource |
getReadableResource(String sName)
Get the resource specified by the given name for reading.
|
IWritableResource |
getWritableResource(String sName)
Get the resource specified by the given name for writing.
|
int |
hashCode() |
boolean |
isCanReadRelativePaths() |
FileSystemResourceProvider |
setCanReadRelativePaths(boolean bCanReadRelativePaths) |
boolean |
supportsReading(String sName)
Check if this resource provider can handle the resource with the passed
name.
|
boolean |
supportsWriting(String sName)
Check if this resource provider can handle the resource with the passed
name.
|
String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitgetOutputStreamgetInputStreampublic final boolean isCanReadRelativePaths()
@Nonnull public final FileSystemResourceProvider setCanReadRelativePaths(boolean bCanReadRelativePaths)
public boolean supportsReading(@Nullable String sName)
IReadableResourceProvidertrue.supportsReading in interface IReadableResourceProvidersName - The name to check. May be null.true if the name is not null and can be
handled by this provider, false otherwise.public boolean supportsWriting(@Nullable String sName)
IWritableResourceProvidertrue.supportsWriting in interface IWritableResourceProvidersName - The name to check. May be null.true if the name is not null and can be
handled by this provider, false otherwise.@Nonnull public IReadableResource getReadableResource(@Nonnull String sName)
IReadableResourceProvidergetReadableResource in interface IReadableResourceProvidersName - The name of the resource to resolve.null.@Nonnull public IWritableResource getWritableResource(@Nonnull String sName)
IWritableResourceProvidergetWritableResource in interface IWritableResourceProvidersName - The name of the resource to resolve.null.Copyright © 2014–2022 Philip Helger. All rights reserved.