Quadcap Embeddable Database

com.quadcap.sql.types.ValueTimestamp Class Reference

Inheritance diagram for com.quadcap.sql.types.ValueTimestamp:

com.quadcap.sql.types.ValueDateTime Externalizable Externable com.quadcap.sql.types.Value Externalizable List of all members.

Detailed Description

A TIMESTAMP value.

Author:
Stan Bailes

Definition at line 60 of file ValueTimestamp.java.

Public Member Functions

 ValueTimestamp ()
 ValueTimestamp (Timestamp val)
 ValueTimestamp (long val)
 ValueTimestamp (String str) throws antlr.RecognitionException
String toString ()
Value unop (int op) throws ValueException
Value binop (int op, Value l) throws ValueException
 Two-level virtual operator dispatch.

Value binop (int op, ValueString r) throws ValueException
Value binop (int op, ValueInterval r) throws ValueException
void readExternal (ObjectInput in) throws IOException, ClassNotFoundException
void writeExternal (ObjectOutput out) throws IOException
Object asJavaObject ()
void fromJavaObject (Object obj) throws ValueException
Type getType ()
Value convert (TypeTimestamp type)
Value convert (TypeDate type)
Value convert (TypeTime type)
void serializeKey (KeyStream out) throws IOException
Extern getExtern ()
void setExtern (Extern extern)

Package Attributes

int nanos = 0
 Extern = null

Static Package Attributes

SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss")


Constructor & Destructor Documentation

com.quadcap.sql.types.ValueTimestamp.ValueTimestamp  ) 
 

Definition at line 66 of file ValueTimestamp.java.

Referenced by com.quadcap.sql.types.ValueTimestamp.binop().

com.quadcap.sql.types.ValueTimestamp.ValueTimestamp Timestamp  val  ) 
 

Definition at line 68 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.nanos.

com.quadcap.sql.types.ValueTimestamp.ValueTimestamp long  val  ) 
 

Definition at line 73 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.nanos.

com.quadcap.sql.types.ValueTimestamp.ValueTimestamp String  str  )  throws antlr.RecognitionException
 

Definition at line 78 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.df, and com.quadcap.sql.types.ValueTimestamp.nanos.


Member Function Documentation

Object com.quadcap.sql.types.ValueTimestamp.asJavaObject  )  [virtual]
 

Reimplemented from com.quadcap.sql.types.ValueDateTime.

Definition at line 168 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.nanos.

Value com.quadcap.sql.types.ValueTimestamp.binop int  op,
ValueInterval  r
throws ValueException
 

Reimplemented from com.quadcap.sql.types.Value.

Definition at line 131 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueDateTime.getCal(), and com.quadcap.sql.types.ValueTimestamp.ValueTimestamp().

Value com.quadcap.sql.types.ValueTimestamp.binop int  op,
ValueString  r
throws ValueException
 

Reimplemented from com.quadcap.sql.types.Value.

Definition at line 123 of file ValueTimestamp.java.

References com.quadcap.sql.types.Value.binop(), and com.quadcap.sql.types.ValueTimestamp.ValueTimestamp().

Value com.quadcap.sql.types.ValueTimestamp.binop int  op,
Value  l
throws ValueException [virtual]
 

Two-level virtual operator dispatch.

Each subtype implements the same basic template for this abstract function:

 Value binop(int op, Value l) {
    return l.binop(op, this);
 }

 
Then, type overloading allows for each type to implement all ops for which it can be the left hand side for all allowed types on the right hand side: Value binop(int op, ValueInteger l); Value binop(int op, ValueLong l); ...

Implements com.quadcap.sql.types.ValueDateTime.

Definition at line 119 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.binop().

Referenced by com.quadcap.sql.types.ValueTimestamp.binop().

Value com.quadcap.sql.types.ValueTimestamp.convert TypeTime  type  ) 
 

Reimplemented from com.quadcap.sql.types.Value.

Definition at line 199 of file ValueTimestamp.java.

Value com.quadcap.sql.types.ValueTimestamp.convert TypeDate  type  ) 
 

Reimplemented from com.quadcap.sql.types.Value.

Definition at line 195 of file ValueTimestamp.java.

Value com.quadcap.sql.types.ValueTimestamp.convert TypeTimestamp  type  ) 
 

Reimplemented from com.quadcap.sql.types.Value.

Definition at line 191 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.convert().

Referenced by com.quadcap.sql.types.ValueTimestamp.convert().

void com.quadcap.sql.types.ValueTimestamp.fromJavaObject Object  obj  )  throws ValueException [virtual]
 

Implements com.quadcap.sql.types.Value.

Definition at line 174 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.fromJavaObject(), and com.quadcap.sql.types.ValueTimestamp.nanos.

Referenced by com.quadcap.sql.types.ValueTimestamp.fromJavaObject().

Extern com.quadcap.sql.types.ValueTimestamp.getExtern  ) 
 

Definition at line 210 of file ValueTimestamp.java.

Type com.quadcap.sql.types.ValueTimestamp.getType  )  [virtual]
 

Implements com.quadcap.sql.types.ValueDateTime.

Definition at line 187 of file ValueTimestamp.java.

void com.quadcap.sql.types.ValueTimestamp.readExternal ObjectInput  in  )  throws IOException, ClassNotFoundException
 

Reimplemented from com.quadcap.sql.types.ValueDateTime.

Definition at line 154 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.nanos, and com.quadcap.sql.types.ValueTimestamp.readExternal().

Referenced by com.quadcap.sql.types.ValueTimestamp.readExternal().

void com.quadcap.sql.types.ValueTimestamp.serializeKey KeyStream  out  )  throws IOException [virtual]
 

Reimplemented from com.quadcap.sql.types.ValueDateTime.

Definition at line 203 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.nanos, and com.quadcap.sql.types.ValueTimestamp.serializeKey().

Referenced by com.quadcap.sql.types.ValueTimestamp.serializeKey().

void com.quadcap.sql.types.ValueTimestamp.setExtern Extern  extern  ) 
 

Definition at line 211 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.setExtern().

Referenced by com.quadcap.sql.types.ValueTimestamp.setExtern().

String com.quadcap.sql.types.ValueTimestamp.toString  ) 
 

Reimplemented from com.quadcap.sql.types.ValueDateTime.

Definition at line 103 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.df.

Value com.quadcap.sql.types.ValueTimestamp.unop int  op  )  throws ValueException
 

Reimplemented from com.quadcap.sql.types.ValueDateTime.

Definition at line 109 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.unop().

Referenced by com.quadcap.sql.types.ValueTimestamp.unop().

void com.quadcap.sql.types.ValueTimestamp.writeExternal ObjectOutput  out  )  throws IOException
 

Reimplemented from com.quadcap.sql.types.ValueDateTime.

Definition at line 161 of file ValueTimestamp.java.

References com.quadcap.sql.types.ValueTimestamp.nanos, and com.quadcap.sql.types.ValueTimestamp.writeExternal().

Referenced by com.quadcap.sql.types.ValueTimestamp.writeExternal().


Member Data Documentation

SimpleDateFormat com.quadcap.sql.types.ValueTimestamp.df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss") [static, package]
 

Definition at line 64 of file ValueTimestamp.java.

Referenced by com.quadcap.sql.types.ValueTimestamp.toString(), and com.quadcap.sql.types.ValueTimestamp.ValueTimestamp().

com.quadcap.sql.types.ValueTimestamp.Extern = null [package]
 

Definition at line 209 of file ValueTimestamp.java.

int com.quadcap.sql.types.ValueTimestamp.nanos = 0 [package]
 

Definition at line 62 of file ValueTimestamp.java.

Referenced by com.quadcap.sql.types.ValueTimestamp.asJavaObject(), com.quadcap.sql.types.ValueTimestamp.fromJavaObject(), com.quadcap.sql.types.ValueTimestamp.readExternal(), com.quadcap.sql.types.ValueTimestamp.serializeKey(), com.quadcap.sql.types.ValueTimestamp.ValueTimestamp(), and com.quadcap.sql.types.ValueTimestamp.writeExternal().