org.jpox.store
Class StatementExpressionIndex

java.lang.Object
  extended byorg.jpox.store.StatementExpressionIndex

public class StatementExpressionIndex
extends java.lang.Object

Maintain an index for the mapping field vs columns in a JDBC statement. Each field for a Request (in a Statement) must have one instance of this containing the field Number + Mapping + the columns

 
 e.g.
 CLASS                 FIELDNUMBER     MAPPING            TABLE                EXPRESSION INDEX (JDBC)
 -----------------     -----------     --------------     ----------------     ----------------
 class A           -->             -->                --> TABLE_A            
 {
    int fieldA;    --> 1           --> IntegerMapping --> COL_FIELDA       --> 1
    String fieldB; --> 2           --> StringMapping  --> COL_FIELDB_PART1 --> 2
                   -->             -->                --> COL_FIELDB_PART2 --> 3
    ...
 }
 

Version:
$Revision: 1.4 $

Constructor Summary
StatementExpressionIndex()
           
 
Method Summary
 java.lang.String getColumnName()
          Accessor for the column name (if any).
 int[] getExpressionIndex()
          Accessor for the expression index(es).
 JavaTypeMapping getMapping()
          Accessor for the mapping for the field.
 int[] getParameterIndex()
          Accessor for the parameter index(es).
 void setColumnName(java.lang.String colName)
          Mutator for the column name (alias).
 void setExpressionIndex(int[] is)
          Mutator for the JDBC expression index(es).
 void setMapping(JavaTypeMapping mapping)
          Mutator for the mapping for the field.
 void setParameterIndex(int[] is)
           
 java.lang.String toString()
          Method to return a string version of this object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StatementExpressionIndex

public StatementExpressionIndex()
Method Detail

getExpressionIndex

public int[] getExpressionIndex()
Accessor for the expression index(es).

Returns:
The expression index

getMapping

public JavaTypeMapping getMapping()
Accessor for the mapping for the field.

Returns:
The mapping

getColumnName

public java.lang.String getColumnName()
Accessor for the column name (if any).

Returns:
The column name.

setExpressionIndex

public void setExpressionIndex(int[] is)
Mutator for the JDBC expression index(es). This is the position in the JDBC result set.

Parameters:
is - The expression index

setMapping

public void setMapping(JavaTypeMapping mapping)
Mutator for the mapping for the field.

Parameters:
mapping - The mapping

setColumnName

public void setColumnName(java.lang.String colName)
Mutator for the column name (alias). Overrides the name of the field that the mapping refers to.

Parameters:
colName - The name of the column (alias).

getParameterIndex

public int[] getParameterIndex()
Accessor for the parameter index(es).

Returns:
The parameter index

setParameterIndex

public void setParameterIndex(int[] is)
Parameters:
is - The parameter index

toString

public java.lang.String toString()
Method to return a string version of this object.

Returns:
String version


Copyright © -2007 . All Rights Reserved.