toolkit.db.api
Class JoinInfo

java.lang.Object
  extended by toolkit.db.api.JoinInfo

public class JoinInfo
extends java.lang.Object

JoinInfo wraps all information of related Joins.


Field Summary
static int FULL_OUTER_JOIN
           
static int INNER_JOIN
           
static int LEFT_OUTER_JOIN
           
static int OUTER_JOIN
           
static int RIGHT_OUTER_JOIN
           
static java.lang.String STR_FULL_OUTER_JOIN
           
static java.lang.String STR_INNER_JOIN
           
static java.lang.String STR_LEFT_OUTER_JOIN
           
static java.lang.String STR_OUTER_JOIN
           
static java.lang.String STR_RIGHT_OUTER_JOIN
           
static java.lang.String STR_UNION_JOIN
           
static int UNION_JOIN
           
 
Constructor Summary
JoinInfo(ColumnInfo columnFrom, java.lang.String sOperator, ColumnInfo columnTo, int iJoinType, boolean bSQL92, boolean bSelfJoin)
          Constructor.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Compares this JoinInfo to the specified object.
 ColumnInfo getColumnFrom()
          Gets the FROM column's ColumnInfo.
 ColumnInfo getColumnTo()
          Gets the ColumnInfo of the TO column.
 int getJoinType()
          Gets the outer join type.
 java.lang.String getOperator()
          Gets the value of the OPERATOR's string.
 boolean isFullOuterJoin()
          Gets whether this is a full outer join table.
 boolean isLeftOuterJoin()
          Gets whether this is a left outer join table.
 boolean isOuterJoin()
          Gets whether this is an outer join table.
 boolean isRightOuterJoin()
          Gets whether this is a right outer join table.
 boolean isSelfJoin()
          Gets whether this is a self join.
 boolean isSQL92()
          Gets whether this join applies SQL92 standard.
 java.lang.String toString()
          Returns a string representing this JoinInfo's values.
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

INNER_JOIN

public static final int INNER_JOIN
See Also:
Constant Field Values

RIGHT_OUTER_JOIN

public static final int RIGHT_OUTER_JOIN
See Also:
Constant Field Values

FULL_OUTER_JOIN

public static final int FULL_OUTER_JOIN
See Also:
Constant Field Values

LEFT_OUTER_JOIN

public static final int LEFT_OUTER_JOIN
See Also:
Constant Field Values

OUTER_JOIN

public static final int OUTER_JOIN
See Also:
Constant Field Values

UNION_JOIN

public static final int UNION_JOIN
See Also:
Constant Field Values

STR_INNER_JOIN

public static final java.lang.String STR_INNER_JOIN
See Also:
Constant Field Values

STR_RIGHT_OUTER_JOIN

public static final java.lang.String STR_RIGHT_OUTER_JOIN
See Also:
Constant Field Values

STR_FULL_OUTER_JOIN

public static final java.lang.String STR_FULL_OUTER_JOIN
See Also:
Constant Field Values

STR_LEFT_OUTER_JOIN

public static final java.lang.String STR_LEFT_OUTER_JOIN
See Also:
Constant Field Values

STR_OUTER_JOIN

public static final java.lang.String STR_OUTER_JOIN
See Also:
Constant Field Values

STR_UNION_JOIN

public static final java.lang.String STR_UNION_JOIN
See Also:
Constant Field Values
Constructor Detail

JoinInfo

public JoinInfo(ColumnInfo columnFrom,
                java.lang.String sOperator,
                ColumnInfo columnTo,
                int iJoinType,
                boolean bSQL92,
                boolean bSelfJoin)
Constructor.

Parameters:
columnFrom - The FROM column of the join.
sOperator - The sOperator of the join condition. The valid value can be "=", ">", "<", etc.
columnTo - The TO column of the join.
iJoinType - The join type, whose values are: INNER_JOIN = 0; RIGHT_OUTER_JOIN = 1; FULL_OUTER_JOIN = 2; LEFT_OUTER_JOIN = 4; OUTER_JOIN = 7; UNION_JOIN = 8;
bSQL92 - Whether this join applies SQL92 standard.
bSelfJoin - Whether this is a self join.
Method Detail

getColumnFrom

public ColumnInfo getColumnFrom()
Gets the FROM column's ColumnInfo.

Returns:
the ColumnInfo of the FROM column.

getOperator

public java.lang.String getOperator()
Gets the value of the OPERATOR's string.

Returns:
the OPERATOR value.

getColumnTo

public ColumnInfo getColumnTo()
Gets the ColumnInfo of the TO column.

Returns:
the ColumnInfo of the TO column.

getJoinType

public int getJoinType()
Gets the outer join type.

Returns:
the type of the outer join.

isOuterJoin

public boolean isOuterJoin()
Gets whether this is an outer join table.

Returns:
true if this is an outer join table, false otherwise.

isLeftOuterJoin

public boolean isLeftOuterJoin()
Gets whether this is a left outer join table.

Returns:
true if this is a left outer join table, false otherwise.

isRightOuterJoin

public boolean isRightOuterJoin()
Gets whether this is a right outer join table.

Returns:
true if this is a right outer join table, false otherwise.

isFullOuterJoin

public boolean isFullOuterJoin()
Gets whether this is a full outer join table.

Returns:
true if this is a full outer join table, false otherwise.

isSQL92

public boolean isSQL92()
Gets whether this join applies SQL92 standard.

Returns:
true if this join applies SQL92 standard, false otherwise.

isSelfJoin

public boolean isSelfJoin()
Gets whether this is a self join.

Returns:
true if this is a self join, false otherwise.

equals

public boolean equals(java.lang.Object obj)
Compares this JoinInfo to the specified object.

Overrides:
equals in class java.lang.Object
Returns:
true if the JoinInfo are the same, false otherwise.

toString

public java.lang.String toString()
Returns a string representing this JoinInfo's values. The format is as follows:

  className@hashCode[ mappingNameOfFromColumn | operator | mappingNameOfToColumn | 
                      joinTypeString | isSQL92 | isSelfJoin ]
        

Overrides:
toString in class java.lang.Object
Returns:
a string representing of this JoinInfo.