Package db2000.J.eXtrafunctions
Class fCONVERSION
- java.lang.Object
-
- db2000.J.eXtrafunctions.fCONVERSION
-
public class fCONVERSION extends Object
conversion functions
-
-
Constructor Summary
Constructors Constructor Description fCONVERSION()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
Asc(String xCharacter)
returns a numeric code (ASCII) equivalent to the character specifiedstatic String
BinaryStringADJ(String xBinary)
returns a binary string adjustment (normalized format)static String
BinaryToHex(String xBinary)
converts an binary string to a hex stringstatic int
BinaryToInteger(String xBinary)
converts an binary string to a integerstatic Long
BinaryToLong(String xBinary)
converts an binary string to a longstatic boolean
CBool(Object xExpression)
returns an expression converted to a booleanstatic byte
CByte(Object xExpression)
returns an expression converted to a bytestatic char
CChar(Object xExpression)
returns an expression converted to a charstatic Date
CDate(Object xDate, String xDateFormat)
returns an expression converted to a date in the format determinedstatic double
CDbl(Object xValue)
returns a value converted to a doublestatic String
Chr(int xNumber)
returns a character equivalent to the numeric code specified (ASCII)static int
CInt(Object xValue)
returns a value converted to a integerstatic long
CLng(Object xValue)
returns a value converted to a longstatic String
CStr(Object xValue)
returns a value converted to a stringstatic double
DegreesToRadians(double xDegrees)
returns the value in radians from degreesstatic String
HexToBinary(String xHexValue)
converts an hex string to a binary stringstatic int
HexToInteger(String xHexValue)
converts an hex string to a integer valuestatic Long
HexToLong(String xHexValue)
converts an hex string to a long valuestatic int
Int(Object xExpression)
returns an expression converted to a integerstatic String
IntegerToHex(int xValue)
converts an integer value to a hex stringstatic String
LongToHex(long xValue)
converts an long value to a hex stringstatic double
RadiansToDegrees(double xRadians)
returns the value in degrees from radiansstatic Object
Val(Object xExpression)
returns a numeric value
-
-
-
Method Detail
-
Asc
public static int Asc(String xCharacter)
returns a numeric code (ASCII) equivalent to the character specified- Parameters:
xCharacter
- the character
-
BinaryStringADJ
public static String BinaryStringADJ(String xBinary)
returns a binary string adjustment (normalized format)- Parameters:
xBinary
- the binary string to be adjusted
-
BinaryToHex
public static String BinaryToHex(String xBinary)
converts an binary string to a hex string- Parameters:
xBinary
- the binary string to be converted
-
BinaryToInteger
public static int BinaryToInteger(String xBinary)
converts an binary string to a integer- Parameters:
xBinary
- the binary string to be converted
-
BinaryToLong
public static Long BinaryToLong(String xBinary)
converts an binary string to a long- Parameters:
xBinary
- the binary string to be converted
-
CBool
public static boolean CBool(Object xExpression)
returns an expression converted to a boolean- Parameters:
xExpression
- the expression to be converted
-
CByte
public static byte CByte(Object xExpression)
returns an expression converted to a byte- Parameters:
xExpression
- the expression to be converted
-
CChar
public static char CChar(Object xExpression)
returns an expression converted to a char- Parameters:
xExpression
- the expression to be converted
-
CDate
public static Date CDate(Object xDate, String xDateFormat)
returns an expression converted to a date in the format determined- Parameters:
xDate
- the expression that contains the datexDateFormat
- the date format (if Null or = "" the default is "dd/MM/yyyy")
-
CDbl
public static double CDbl(Object xValue)
returns a value converted to a double- Parameters:
xValue
- the value to be converted
-
Chr
public static String Chr(int xNumber)
returns a character equivalent to the numeric code specified (ASCII)- Parameters:
xNumber
- the numeric code
-
CInt
public static int CInt(Object xValue)
returns a value converted to a integer- Parameters:
xValue
- the value to be converted
-
CLng
public static long CLng(Object xValue)
returns a value converted to a long- Parameters:
xValue
- the value to be converted
-
CStr
public static String CStr(Object xValue)
returns a value converted to a string- Parameters:
xValue
- the value to be converted
-
DegreesToRadians
public static double DegreesToRadians(double xDegrees)
returns the value in radians from degrees
-
HexToBinary
public static String HexToBinary(String xHexValue)
converts an hex string to a binary string- Parameters:
xHexValue
- the hex string to be converted
-
HexToInteger
public static int HexToInteger(String xHexValue)
converts an hex string to a integer value- Parameters:
xHexValue
- the hex string to be converted
-
HexToLong
public static Long HexToLong(String xHexValue)
converts an hex string to a long value- Parameters:
xHexValue
- the hex string to be converted
-
Int
public static int Int(Object xExpression)
returns an expression converted to a integer- Parameters:
xExpression
- the expression to be converted
-
IntegerToHex
public static String IntegerToHex(int xValue)
converts an integer value to a hex string- Parameters:
xValue
- the number to be converted
-
LongToHex
public static String LongToHex(long xValue)
converts an long value to a hex string- Parameters:
xValue
- the number to be converted
-
RadiansToDegrees
public static double RadiansToDegrees(double xRadians)
returns the value in degrees from radians- Parameters:
xRadians
- the radians to be converted
-
-