jsdai.lang
Class ELogical

java.lang.Object
  extended byjsdai.lang.ELogical

public final class ELogical
extends java.lang.Object

The ELogical class represents the EXPRESS data type LOGICAL and defines its values FALSE, TRUE and UNKNOWN for its usage in Java similarly like it is done for ENUMERATION. This class is used only statically. There exist no instance of it.


Field Summary
static int FALSE
          The value 1 that stands for the logical value "false".
static int TRUE
          The value 2 that stands for the logical value "true".
static int UNKNOWN
          The value 3 that stands for the logical value "unknown".
static java.lang.String[] values
          The array of Strings {"FALSE", "TRUE", "UNKNOWN"} representing logical values "false", "true" and "unknown".
 
Method Summary
static int toInt(java.lang.String str)
          Converts the String representation of the value of the logical type to the corresponding integer constant.
static java.lang.String toString(int value)
          Converts the int representation of the value of the logical type to the corresponding String constant.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FALSE

public static final int FALSE
The value 1 that stands for the logical value "false".

See Also:
Constant Field Values

TRUE

public static final int TRUE
The value 2 that stands for the logical value "true".

See Also:
Constant Field Values

UNKNOWN

public static final int UNKNOWN
The value 3 that stands for the logical value "unknown".

See Also:
Constant Field Values

values

public static final java.lang.String[] values
The array of Strings {"FALSE", "TRUE", "UNKNOWN"} representing logical values "false", "true" and "unknown".

Method Detail

toInt

public static int toInt(java.lang.String str)
Converts the String representation of the value of the logical type to the corresponding integer constant. If the string passed through the method's parameter is different from each possible string representation of a logical value, then zero having a meaning "unset value" is returned; otherwise, method returns some integer from the interval [1,3].

Parameters:
str - a string specifying the logical value.
Returns:
an integer representing the logical value.
See Also:
toString(int)

toString

public static java.lang.String toString(int value)
Converts the int representation of the value of the logical type to the corresponding String constant. If the integer passed through the method's parameter belongs to the interval [1,3], then string counterpart of the logical value is returned; otherwise, method returns string constant "unset".

Parameters:
value - an integer specifying the logical value.
Returns:
a string representation of the logical value.
See Also:
toInt(java.lang.String)

Copyright © LKSoftWare GmbH, 1999-2008