Siena (v.1.5.5) API documentation

siena
Class AttributeValue

java.lang.Object
  extended by siena.AttributeValue
All Implemented Interfaces:
java.io.Serializable

public class AttributeValue
extends java.lang.Object
implements java.io.Serializable

Value of an attribute in an event notification. An AttributeValue is a container for a typed vaule of an attribute in a notification. An AttributeValue can be of type String, byte[], int, long, double, and boolean.

Example:

 
       AttributeValue v = new
       AttributeValue("Antonio"); 
       System.out.println(v.stringValue());
       Notification e = new Notification(); 
       e.putAttribute("name", v);
   

See Also:
Notification, AttributeConstraint, Serialized Form

Field Summary
static int BOOL
          boolean type.
static int BYTEARRAY
          string of bytes
static int DOUBLE
          double type.
static int INT
          integer type.
static int LONG
          integer type.
static int NULL
          null type, the default type of a Siena attribute
static int STRING
          string of bytes an alias to BYTEARRAY provided only for backward compatibility
 
Constructor Summary
AttributeValue()
           
AttributeValue(AttributeValue x)
           
AttributeValue(boolean b)
           
AttributeValue(byte[] s)
           
AttributeValue(double d)
           
AttributeValue(long i)
           
AttributeValue(java.lang.String s)
           
 
Method Summary
 boolean booleanValue()
           
 byte[] byteArrayValue()
           
 double doubleValue()
           
 int getType()
           
 int hashCode()
           
 int intValue()
           
 boolean isEqualTo(AttributeValue x)
           
 long longValue()
           
 java.lang.String stringValue()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

NULL

public static final int NULL
null type, the default type of a Siena attribute

See Also:
Constant Field Values

BYTEARRAY

public static final int BYTEARRAY
string of bytes

See Also:
Constant Field Values

STRING

public static final int STRING
string of bytes an alias to BYTEARRAY provided only for backward compatibility

See Also:
Constant Field Values

LONG

public static final int LONG
integer type. corresponds to the Java long type.

See Also:
Constant Field Values

INT

public static final int INT
integer type. corresponds to the Java int type.

See Also:
Constant Field Values

DOUBLE

public static final int DOUBLE
double type. corresponds to the Java double type.

See Also:
Constant Field Values

BOOL

public static final int BOOL
boolean type. corresponds to the Java boolean type.

See Also:
Constant Field Values
Constructor Detail

AttributeValue

public AttributeValue()

AttributeValue

public AttributeValue(AttributeValue x)

AttributeValue

public AttributeValue(java.lang.String s)

AttributeValue

public AttributeValue(byte[] s)

AttributeValue

public AttributeValue(long i)

AttributeValue

public AttributeValue(boolean b)

AttributeValue

public AttributeValue(double d)
Method Detail

getType

public int getType()

intValue

public int intValue()

longValue

public long longValue()

doubleValue

public double doubleValue()

booleanValue

public boolean booleanValue()

stringValue

public java.lang.String stringValue()

byteArrayValue

public byte[] byteArrayValue()

isEqualTo

public boolean isEqualTo(AttributeValue x)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

Siena (v.1.5.5) API documentation

Copyright © 2000-2005 University of Colorado.
Copyright © 2005-2008 Antonio Carzaniga.
This documentation is maintained by Antonio Carzaniga