dbobjects
Class MyTable

java.lang.Object
  |
  +--dbobjects.DBObject
        |
        +--dbobjects.MyTable

public class MyTable
extends DBObject


Inner classes inherited from class dbobjects.DBObject
DBObject.DBBigInteger, DBObject.DBChar, DBObject.DBDate, DBObject.DBDecimal, DBObject.DBDouble, DBObject.DBField, DBObject.DBFloat, DBObject.DBInteger, DBObject.DBLongVarChar, DBObject.DBNoType, DBObject.DBNumeric, DBObject.DBReal, DBObject.DBSmallInt, DBObject.DBTime, DBObject.DBTimestamp, DBObject.DBTinyInt, DBObject.DBVarChar
 
Constructor Summary
MyTable()
          Default Constructor.
MyTable(java.lang.Integer id)
          Construct a(n) MyTable object from the database given the primary key..
MyTable(java.lang.Integer id, java.lang.String name, java.lang.String description)
          Construct a(n) MyTable object from the given parameters.
 
Method Summary
 int create()
          Creates a(n) MyTable record in the database - uses default database connection.
 int create(java.sql.Connection con)
          Creates a(n) MyTable record in the database - uses supplied database connection.
 int destroy()
          Deletes a(n) MyTable record in the database - uses default database connection.
 int destroy(java.sql.Connection con)
          Deletes a(n) MyTable record in the database - uses supplied database connection.
 java.lang.Object getColumn(java.lang.String column)
          Get the value of a column from the database column name.
 java.lang.String getDescription()
          Get the description for the my_table record.
 java.lang.Integer getId()
          Get the id for the my_table record.
 java.lang.String getName()
          Get the name for the my_table record.
 void setColumn(java.lang.String column, java.lang.Object value)
          Set the value of a column from the database column name.
 void setDescription(java.lang.String description)
          Set the description for the my_table record.
 void setId(java.lang.Integer id)
          Set the id for the my_table record.
 void setName(java.lang.String name)
          Set the name for the my_table record.
 java.lang.String toString()
           
 int update()
          Updates a(n) MyTable record in the database - uses default database connection.
 int update(java.sql.Connection con)
          Updates a(n) MyTable record in the database - uses supplied database connection.
 
Methods inherited from class dbobjects.DBObject
getConnection, log, psSetObject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MyTable

public MyTable()
Default Constructor.

MyTable

public MyTable(java.lang.Integer id,
               java.lang.String name,
               java.lang.String description)
Construct a(n) MyTable object from the given parameters.

MyTable

public MyTable(java.lang.Integer id)
Construct a(n) MyTable object from the database given the primary key..
Method Detail

getId

public java.lang.Integer getId()
Get the id for the my_table record.
Returns:
The id for the my_table record.

setId

public void setId(java.lang.Integer id)
Set the id for the my_table record.
Parameters:
id - The value to set the id to.

getName

public java.lang.String getName()
Get the name for the my_table record.
Returns:
The name for the my_table record.

setName

public void setName(java.lang.String name)
Set the name for the my_table record.
Parameters:
name - The value to set the name to.

getDescription

public java.lang.String getDescription()
Get the description for the my_table record.
Returns:
The description for the my_table record.

setDescription

public void setDescription(java.lang.String description)
Set the description for the my_table record.
Parameters:
description - The value to set the description to.

getColumn

public java.lang.Object getColumn(java.lang.String column)
Get the value of a column from the database column name.
Returns:
The value for the given column.

setColumn

public void setColumn(java.lang.String column,
                      java.lang.Object value)
Set the value of a column from the database column name.

create

public int create()
Creates a(n) MyTable record in the database - uses default database connection.
Returns:
The number of rows inserted.

create

public int create(java.sql.Connection con)
Creates a(n) MyTable record in the database - uses supplied database connection.
Returns:
The number of rows inserted.

update

public int update()
Updates a(n) MyTable record in the database - uses default database connection.
Returns:
The number of rows updated.

update

public int update(java.sql.Connection con)
Updates a(n) MyTable record in the database - uses supplied database connection.
Returns:
The number of rows updated.

destroy

public int destroy()
Deletes a(n) MyTable record in the database - uses default database connection.
Returns:
The number of rows deleted.

destroy

public int destroy(java.sql.Connection con)
Deletes a(n) MyTable record in the database - uses supplied database connection.
Returns:
The number of rows deleted.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object
Returns:
The string representation of the object.