|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectproper.relaggs.RelaggsAttribute
public class RelaggsAttribute
Title: RelaggsAttribute
Description: Represents a table attribute.
Copyright: 2002 Susanne Streuer
ChangeLog:
Field Summary | |
---|---|
static int |
TYPE_CHAR
Constant representing a short text (less than 256 digits) [char, varchar, tinyblob, tinytext]. |
static int |
TYPE_DATE
Constant representing a date [date]. |
static int |
TYPE_DATETIME
Constant representing a date and a time [timestamp, datetime]. |
static int |
TYPE_ENUM
Constant representing an enumeration [enum]. |
static int |
TYPE_INT
Constant representing an integer [tinyint, smallint, mediumint, int, integer, bigint, year]. |
static int |
TYPE_REAL
Constant representing a real [float, double, real, decimal, numeric]. |
static int |
TYPE_SET
Constant representing a set [set]. |
static int |
TYPE_TEXT
Constant representing a long text (more than 255 digits) [blob, mediumblob, longblob, text, mediumtext, longtext]. |
static int |
TYPE_TIME
Constant representing a time [time]. |
static int |
TYPE_UNKNOWN
Constant representing an unknown data type. |
Constructor Summary | |
---|---|
RelaggsAttribute(java.lang.String name,
java.lang.String jdbc_type,
java.lang.String type_name,
int type_size)
Creates a new RelaggsAttribute. |
Method Summary | |
---|---|
int |
compareTo(java.lang.Object o)
Compares this attribute to the given object. |
boolean |
equals(java.lang.Object obj)
Returns true if the given object is a RelaggsAttribute and its name equals the name of this attribute. |
java.lang.String |
getAggregateFunctions(java.lang.String table_name,
java.lang.String table_short_name,
boolean is_primary_key)
Returns a SQL statement containing the standard aggregate functions of the attribute according to its type. |
java.lang.String |
getName()
Returns the name of the attribute. |
int |
getType()
Returns the type constant of the attribute. |
java.lang.String |
getTypeCreate()
Returns the SQL create description of the attribute type (type_name and type_size). FracPete: changed to ANSI types |
java.lang.String |
getTypeName()
Returns the name of the attribute's type. |
java.lang.String |
toString()
Returns the name of the attribute. |
Methods inherited from class java.lang.Object |
---|
getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int TYPE_UNKNOWN
public static final int TYPE_INT
public static final int TYPE_REAL
public static final int TYPE_CHAR
public static final int TYPE_TEXT
public static final int TYPE_DATE
public static final int TYPE_DATETIME
public static final int TYPE_TIME
public static final int TYPE_ENUM
public static final int TYPE_SET
Constructor Detail |
---|
public RelaggsAttribute(java.lang.String name, java.lang.String jdbc_type, java.lang.String type_name, int type_size)
name
- the name of the attributejdbc_type
- the JDBC type of the attributetype_name
- the type name of the attributetype_size
- the size of the attribute, e.g., 20 for VARCHAR(20)Method Detail |
---|
public java.lang.String getTypeName()
public java.lang.String getTypeCreate()
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String getName()
public int getType()
public java.lang.String getAggregateFunctions(java.lang.String table_name, java.lang.String table_short_name, boolean is_primary_key)
table_name
- the name of the table which includes this attributetable_short_name
- the short name of the table which includes this attributeis_primary_key
- true if the attribute is the primary key of the table; else falsepublic int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |