Class InputFieldLong
java.lang.Object
nl.tudelft.simulation.dsol.swing.gui.inputparameters.AbstractInputField
nl.tudelft.simulation.dsol.swing.gui.inputparameters.InputFieldString
nl.tudelft.simulation.dsol.swing.gui.inputparameters.InputFieldLong
- All Implemented Interfaces:
InputField
Swing InputField for Long.
Copyright (c) 2003-2024 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information www.simulation.tudelft.nl. The source code and binary code of this software is proprietary information of Delft University of Technology.
Copyright (c) 2003-2024 Delft University of Technology, Jaffalaan 5, 2628 BX Delft, the Netherlands. All rights reserved. See for project information www.simulation.tudelft.nl. The source code and binary code of this software is proprietary information of Delft University of Technology.
- Author:
- Alexander Verbraeck
-
Field Summary
Fields inherited from class nl.tudelft.simulation.dsol.swing.gui.inputparameters.InputFieldString
textField
Fields inherited from class nl.tudelft.simulation.dsol.swing.gui.inputparameters.AbstractInputField
key, parameter
-
Constructor Summary
ConstructorDescriptionInputFieldLong
(JPanel panel, InputParameterLong parameter) Create a long field on the screen. -
Method Summary
Modifier and TypeMethodDescriptionlong
Return the numeric value of the field.static long
getLongValue
(String s, String shortName) Return the numeric value of the field.Methods inherited from class nl.tudelft.simulation.dsol.swing.gui.inputparameters.InputFieldString
getStringValue
Methods inherited from class nl.tudelft.simulation.dsol.swing.gui.inputparameters.AbstractInputField
getKey
-
Constructor Details
-
InputFieldLong
Create a long field on the screen.- Parameters:
panel
- JPanel; panel to add the field toparameter
- InputParameterLong; the parameter
-
-
Method Details
-
getParameter
- Specified by:
getParameter
in interfaceInputField
- Overrides:
getParameter
in classAbstractInputField
- Returns:
- the input parameter for the field.
-
getLongValue
Return the numeric value of the field.- Returns:
- the long value of the field in the gui.
- Throws:
InputParameterException
- on invalid input
-
getLongValue
Return the numeric value of the field.- Parameters:
s
- String; the String to testshortName
- String; the name of the field to test- Returns:
- the long value of the field in the gui.
- Throws:
InputParameterException
- on invalid input
-