Package com.oss.asn1
Class BOOLEAN
java.lang.Object
com.oss.asn1.AbstractData
com.oss.asn1.BOOLEAN
- All Implemented Interfaces:
Serializable
,Cloneable
The BOOLEAN class represents the ASN.1 BOOLEAN type.
- Since:
- ASN.1/Java 1.0-beta A
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final BOOLEAN
Constant used to specify the FALSE BOOLEAN value.static final BOOLEAN
Constant used to specify the TRUE BOOLEAN value.Fields inherited from class com.oss.asn1.AbstractData
EQUALS, GREATER_THAN, LESS_THAN
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Get the value of 'this' object as a boolean.final boolean
Compare 'this' object to another BOOLEAN object to see if their contents are the same.int
hashCode()
Returns a hash code for this objectfinal void
setValue
(boolean value) Set the value of 'this' object to a boolean.Methods inherited from class com.oss.asn1.AbstractData
clone, delete, equals, isEncodable, isPDU, isValid, toString, toString
-
Field Details
-
TRUE
Constant used to specify the TRUE BOOLEAN value. -
FALSE
Constant used to specify the FALSE BOOLEAN value.
-
-
Constructor Details
-
BOOLEAN
public BOOLEAN()The default constructor. -
BOOLEAN
public BOOLEAN(boolean value) Construct from a BOOLEAN type.- Parameters:
value
- the BOOLEAN to set 'this' object to.
-
-
Method Details
-
setValue
public final void setValue(boolean value) Set the value of 'this' object to a boolean.- Parameters:
value
- the value to set 'this' object to.
-
booleanValue
public final boolean booleanValue()Get the value of 'this' object as a boolean.- Returns:
- boolean value of 'this' object.
-
equalTo
Compare 'this' object to another BOOLEAN object to see if their contents are the same.- Parameters:
that
- the BOOLEAN object to compare 'this' object to.- Returns:
- true if contents of both objects are the same.
-
hashCode
public int hashCode()Returns a hash code for this object- Overrides:
hashCode
in classAbstractData
- Returns:
- a hash code for this object
-