|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectariba.util.core.ServerUtil
public class ServerUtil
Field Summary | |
---|---|
static java.lang.String |
HTTPSProxyPassword
|
static boolean |
isMicrosoftVM
|
static boolean |
isUnix
|
static boolean |
isWin32
|
static boolean |
isWin32Enabled
Useful for asking if it is legal to call a win32 specific api |
static boolean |
UseSecureRandomNumberGenerator
|
Constructor Summary | |
---|---|
ServerUtil()
|
Method Summary | |
---|---|
static boolean |
compareFilenames(java.lang.String firstFilename,
java.lang.String secondFilename)
|
static boolean |
compareInputStreams(java.io.InputStream firstStream,
java.io.InputStream secondStream)
|
static boolean |
compareInputStreams(java.io.InputStream firstStream,
java.io.InputStream secondStream,
byte[] buffer1,
byte[] buffer2)
|
static java.util.List |
fileExtension(java.lang.String mimeType)
Returns the list of file extension names for the given mime type. |
static java.lang.String |
filterMapValue(java.util.Map map,
java.lang.String key,
char fillChar)
filterValue is useful for dumping out a Map for display in which a particular key's value is not suitable for display (e.g. |
static java.lang.String |
filterMapValue(java.lang.String input,
java.lang.String filterKey,
char fillChar)
Params: input: a string, assumed to be a result of Map.toString() filterKey: the key for which the value is to be "filtered" fillChar: the value for which the value is to be overwritten Returns null if the key was not found |
static java.lang.String |
mimeType(java.lang.String fileExtension)
|
static java.lang.String |
mimeType(java.lang.String currentType,
java.lang.String fileExtension)
if we don't have a current type or the current type is the default, then try to map it by file extension. |
static int |
nextRandomInt()
|
static long |
nextRandomLong()
|
static int |
nextSecureInt()
|
static long |
nextSecureLong()
|
static int |
parseInt(char[] charArray,
int charArrayLength)
Assuming the specified charArray represents an integer, returns that integer's value. |
static int |
parseInt(char[] charArray,
int charArrayLength,
int radix)
Assuming the specified charArray represents an integer, returns that integer's value. |
static int |
parseInt(int offset,
int scanLength,
char[] charArray,
int charArrayLength)
Assuming the specified charArray represents an integer, returns that integer's value. |
static int |
parseInt(int offset,
int scanLength,
char[] charArray,
int charArrayLength,
int radix)
Assuming the specified charArray represents an integer, returns that integer's value. |
static java.lang.String |
quoteQuotes(java.lang.String s,
char quote)
|
static java.util.Random |
randomNumberGenerator()
|
static java.util.Random |
secureRandomNumberGenerator()
|
static void |
setSystemProperty(java.lang.String key,
java.lang.String value)
|
static java.lang.String[] |
simpleParse(java.lang.String line,
java.lang.String delimeter)
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String HTTPSProxyPassword
public static final boolean isWin32
public static final boolean isUnix
public static final boolean isMicrosoftVM
public static final boolean isWin32Enabled
public static boolean UseSecureRandomNumberGenerator
Constructor Detail |
---|
public ServerUtil()
Method Detail |
---|
public static java.lang.String quoteQuotes(java.lang.String s, char quote)
public static boolean compareFilenames(java.lang.String firstFilename, java.lang.String secondFilename)
public static boolean compareInputStreams(java.io.InputStream firstStream, java.io.InputStream secondStream)
public static boolean compareInputStreams(java.io.InputStream firstStream, java.io.InputStream secondStream, byte[] buffer1, byte[] buffer2)
public static java.lang.String mimeType(java.lang.String currentType, java.lang.String fileExtension)
public static java.lang.String mimeType(java.lang.String fileExtension)
public static java.util.List fileExtension(java.lang.String mimeType)
mimeType
- the mime type
Mapping.reverseMap
public static void setSystemProperty(java.lang.String key, java.lang.String value)
public static java.lang.String filterMapValue(java.util.Map map, java.lang.String key, char fillChar)
public static java.lang.String filterMapValue(java.lang.String input, java.lang.String filterKey, char fillChar)
public static java.lang.String[] simpleParse(java.lang.String line, java.lang.String delimeter)
public static int parseInt(int offset, int scanLength, char[] charArray, int charArrayLength) throws java.lang.NumberFormatException
java.lang.NumberFormatException
- If the charArray does not contain a
parsable integer.public static int parseInt(char[] charArray, int charArrayLength, int radix) throws java.lang.NumberFormatException
java.lang.NumberFormatException
- If the charArray does not contain a
parsable integer.public static int parseInt(char[] charArray, int charArrayLength) throws java.lang.NumberFormatException
java.lang.NumberFormatException
- If the charArray does not contain a
parsable integer.public static int parseInt(int offset, int scanLength, char[] charArray, int charArrayLength, int radix) throws java.lang.NumberFormatException
java.lang.NumberFormatException
- If the charArray does not contain a
parsable integer.public static final java.util.Random secureRandomNumberGenerator()
public static final int nextSecureInt()
public static final long nextSecureLong()
public static final java.util.Random randomNumberGenerator()
public static final int nextRandomInt()
public static final long nextRandomLong()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |