|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.gjt.btools.utilities.ResourceUtils
Provides utilities for accessing both local and remote resources.
Constructor Summary | |
ResourceUtils()
|
Method Summary | |
static java.lang.String |
combineLocations(java.lang.String first,
java.lang.String second)
Combines the two given resource location strings, which may possibly use different path separators. |
static java.lang.String |
pathSeparator(java.lang.String location)
Determines the path separator used in the given resource location string. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ResourceUtils()
Method Detail |
public static java.lang.String combineLocations(java.lang.String first, java.lang.String second)
The two location strings will simply be concatenated, with the exception of some tidying up of path separators.
For instance, if first is http://my.server/dira/ and second is dirb\dirc\file.name, then the resulting string will be http://my.server/dira/dirb/dirc/file.name.
first
- the first resource location string; this may or may
not end with a trailing path separator.second
- the second resource location string.
public static java.lang.String pathSeparator(java.lang.String location)
Separators /, \ and :: are supported. If the separator cannot be determined, a default of / is returned.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |