|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectFileUtils
public class FileUtils
Constructor Summary | |
---|---|
FileUtils()
|
Method Summary | |
---|---|
static String |
getFileExtension(String filename)
Get the file extension from a file name. |
static boolean |
isAbsoluteURI(String uri)
Tell whether a given URI is absolute, i.e., whether it contains a scheme-part (e.g., "http:"). |
static boolean |
isOSCaseSensitive()
Tell whether the current operating system is case-sensitive with regard to file names. |
static boolean |
osSensitiveEndsWith(String str,
String suffix)
Tell whether a string ends with a particular suffix, with case sensitivity determined by the operating system. |
static boolean |
osSensitiveEquals(String s1,
String s2)
Compare two strings, with case sensitivity determined by the operating system. |
static String |
stripFileExtension(String filename)
|
static boolean |
uriEndsWith(String uri,
String ending)
Tell whether a URI ends in a given String. |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FileUtils()
Method Detail |
---|
public static boolean isAbsoluteURI(String uri)
uri
- the URI to test.
true
if the given URI is absolute.public static boolean uriEndsWith(String uri, String ending)
public static String getFileExtension(String filename)
filename
- the file name.
public static String stripFileExtension(String filename)
public static boolean isOSCaseSensitive()
public static boolean osSensitiveEquals(String s1, String s2)
s1
- the first String to compare.s2
- the second String to compare.
true
when:
isOSCaseSensitive()
public static boolean osSensitiveEndsWith(String str, String suffix)
str
- the String to test.suffix
- the suffix to look for.
true
when:
str
ends with suffix
, or,str
ends with
suffix
, ignoring case.isOSCaseSensitive()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |