|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.cosylab.gui.components.numberfield.AngleNumberDescriptor com.cosylab.gui.components.numberfield.HMSNumberDescriptor com.cosylab.gui.components.numberfield.Rad2HMSNumberDescriptor
public class Rad2HMSNumberDescriptor
Visualize double value in radians by converting it to hours and displays it in format XX:XX:XX.
Field Summary | |
---|---|
static java.lang.String |
DESCRIPTION
|
static java.lang.String |
NAME
|
Constructor Summary | |
---|---|
Rad2HMSNumberDescriptor()
Constructs a new Rad2HMSNNumberDescritptor. |
Method Summary | |
---|---|
java.lang.Number |
parseNumber(java.lang.String number)
Parses string and creates Number . |
java.lang.String |
printString(java.lang.Number number)
Converts provided Number to a string, which is used for
displaying the value. |
static double |
toHours(double rad)
Converts angle in radians to angle in hours. |
static double |
toRadians(double hour)
Converts angle in hours to angle in radians. |
Methods inherited from class com.cosylab.gui.components.numberfield.AngleNumberDescriptor |
---|
getDegreeSeparator, getFormat, getMinuteSeparator, getNumberType, getSecondSeparator, isUseFullFormat, main, printEditString, setDegreeSeparator, setFormat, setMinuteSeparator, setNumberType, setSecondSeparator, setUseFullFormat |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String NAME
NumberDescriptor
,
Constant Field Valuespublic static final java.lang.String DESCRIPTION
NumberDescriptor
,
Constant Field ValuesConstructor Detail |
---|
public Rad2HMSNumberDescriptor()
Method Detail |
---|
public static final double toHours(double rad)
rad
- angle in radians
public static double toRadians(double hour)
hour
- angle in hours
public java.lang.String printString(java.lang.Number number)
NumberDescriptor
Number
to a string, which is used for
displaying the value.
printString
in interface NumberDescriptor
printString
in class AngleNumberDescriptor
number
- a number to be transformed to string
String
representing a number.public java.lang.Number parseNumber(java.lang.String number)
NumberDescriptor
Number
. If string is not
presentation of a number and can not be parsed, then null must be
returned.
parseNumber
in interface NumberDescriptor
parseNumber
in class AngleNumberDescriptor
number
- a string representing a number
Number
or null
if string
can not be parsed
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |