jam.util
Class Utils
java.lang.Object
jam.util.Utils
public class Utils
- extends java.lang.Object
Constructor Summary |
Utils()
|
Method Summary |
static void |
centerComponent(java.awt.Component component,
java.awt.Component reference)
Center a component in reference to another,
if the reference is null or not visible the screen is used as reference |
static double |
getDoubleFromTextField(javax.swing.JTextField textField,
double defaultValue)
|
static java.lang.String |
getEnv(java.lang.String name)
|
static void |
showDefaultCursor(java.awt.Component component)
|
static void |
showPredefinedCursor(java.awt.Component component,
int cursor)
|
static void |
showWaitCursor(java.awt.Component component)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Utils
public Utils()
getDoubleFromTextField
public static double getDoubleFromTextField(javax.swing.JTextField textField,
double defaultValue)
- Returns:
- the value in a text field as a double.
If the text field contents do not represent a valid double then the
default value is inserted into the text field and returned.
centerComponent
public static void centerComponent(java.awt.Component component,
java.awt.Component reference)
- Center a component in reference to another,
if the reference is null or not visible the screen is used as reference
showWaitCursor
public static void showWaitCursor(java.awt.Component component)
showPredefinedCursor
public static void showPredefinedCursor(java.awt.Component component,
int cursor)
showDefaultCursor
public static void showDefaultCursor(java.awt.Component component)
getEnv
public static java.lang.String getEnv(java.lang.String name)
http://code.google.com/p/jam-lib/