edu.swri.swiftvis.util
Class EditableDouble
java.lang.Object
edu.swri.swiftvis.util.EditableDouble
- All Implemented Interfaces:
- java.io.Serializable
public final class EditableDouble
- extends java.lang.Object
- implements java.io.Serializable
This class can be used to store doubles that need to be edited in a GUI. Using this class
prevents the programmer from having to write handler code dealing with parsing the number
and handling it if it is incorrect. It also makes it so that when the value is changed the
GUI component is updates.
- Author:
- Mark Lewis
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
value
private double value
field
private transient javax.swing.JTextField field
listener
private transient EditableDouble.Listener listener
errorHandling
private transient boolean errorHandling
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
EditableDouble
public EditableDouble(double val)
getValue
public double getValue()
setValue
public void setValue(double val)
getTextField
public javax.swing.JTextField getTextField(EditableDouble.Listener edl)
valueChanged
private void valueChanged()