|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object | +--ru.novosoft.dc.core.util.Utilities
The class contains miscellaneous static utility methods.
| Method Summary | |
static int |
clearBit(int value,
int bitNumber)
Set a specified bit in the value to 0 and return the result. |
static boolean |
equal(java.lang.Object obj1,
java.lang.Object obj2)
Compare objects to be both null or equal to each other (use the equals() method) and return true if any of this conditions fulfilled. |
static boolean |
hasBit(int value,
int bitNumber)
Return true if a specified bit is equal to 1. |
static boolean |
isEqual(java.util.Properties properties,
java.lang.String name,
java.lang.String value)
Return true if a property is specified and its value is equal to the given value. |
static boolean |
isTrue(java.util.Properties properties,
java.lang.String name)
Return true if a property is specified and its value is equal to "true". |
static int |
setBit(int value,
int bitNumber)
Set a specified bit in the value to 1 and return the result. |
static java.lang.String |
toANSIString(java.lang.String s)
Convert a string to ANSI string representation. |
static int |
toInt(java.lang.Object obj)
Convert an object to an integer value and return it. |
static int |
toInt(java.lang.Object obj,
int defaultValue)
Try to convert an object to an integer value and return the result or the defaultValue if conversion fails. |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Method Detail |
public static java.lang.String toANSIString(java.lang.String s)
public static final boolean equal(java.lang.Object obj1,
java.lang.Object obj2)
public static int toInt(java.lang.Object obj)
public static final int toInt(java.lang.Object obj,
int defaultValue)
public static final int setBit(int value,
int bitNumber)
value - a value to set a bit inbitNumber - a bit number (from 0 to 31)
public static final int clearBit(int value,
int bitNumber)
value - a value to set a bit inbitNumber - a bit number (from 0 to 31)
public static final boolean hasBit(int value,
int bitNumber)
value - a value to test a bit inbitNumber - a bit number (from 0 to 31)
public static boolean isTrue(java.util.Properties properties,
java.lang.String name)
public static boolean isEqual(java.util.Properties properties,
java.lang.String name,
java.lang.String value)
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||