com.stratelia.webactiv.organization
Class DomainTable

java.lang.Object
  extended by com.stratelia.webactiv.organization.Table<DomainRow>
      extended by com.stratelia.webactiv.organization.DomainTable

public class DomainTable
extends Table<DomainRow>

A DomainTable object manages the ST_Domain table.


Constructor Summary
DomainTable(OrganizationSchema schema)
           
 
Method Summary
 void createDomain(DomainRow domain)
          Insert a new domain row.
protected  DomainRow fetchDomain(ResultSet rs)
          Fetch the current domain row from a resultSet.
protected  DomainRow fetchRow(ResultSet rs)
          Fetch the current domain row from a resultSet.
 DomainRow[] getAllDomains()
          Returns all the Domains.
 DomainRow getDomain(int id)
          Returns the domain whith the given id.
protected  void prepareInsert(String insertQuery, PreparedStatement insert, DomainRow row)
          Set all the parameters of the insert PreparedStatement built from the insertQuery in order to insert the given row.
protected  void prepareUpdate(String updateQuery, PreparedStatement update, DomainRow row)
          Set all the parameters of the update PreparedStatement built from the updateQuery in order to update the given row.
 void removeDomain(int id)
          Delete the domain
 void updateDomain(DomainRow domain)
          Updates a domain row.
 
Methods inherited from class com.stratelia.webactiv.organization.Table
addIdToQuery, addParamToQuery, addParamToQuery, addParamToQuery, aliasColumns, getCount, getCount, getIds, getIds, getIds, getIds, getInteger, getInteger, getMatchingRows, getNextId, getRows, getRows, getRows, getRows, getUniqueRow, getUniqueRow, getUniqueRow, insertRow, performPrepareStatementParams, truncate, updateRelation, updateRelation, updateRelation, updateRow
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DomainTable

public DomainTable(OrganizationSchema schema)
Method Detail

fetchDomain

protected DomainRow fetchDomain(ResultSet rs)
                         throws SQLException
Fetch the current domain row from a resultSet.

Parameters:
rs -
Returns:
the current domain row from a resultSet.
Throws:
SQLException

getDomain

public DomainRow getDomain(int id)
                    throws AdminPersistenceException
Returns the domain whith the given id.

Parameters:
id -
Returns:
the domain whith the given id.
Throws:
AdminPersistenceException

getAllDomains

public DomainRow[] getAllDomains()
                          throws AdminPersistenceException
Returns all the Domains.

Returns:
all the Domains.
Throws:
AdminPersistenceException

createDomain

public void createDomain(DomainRow domain)
                  throws AdminPersistenceException
Insert a new domain row.

Parameters:
domain -
Throws:
AdminPersistenceException

prepareInsert

protected void prepareInsert(String insertQuery,
                             PreparedStatement insert,
                             DomainRow row)
                      throws SQLException
Description copied from class: Table
Set all the parameters of the insert PreparedStatement built from the insertQuery in order to insert the given row.

Specified by:
prepareInsert in class Table<DomainRow>
Throws:
SQLException

updateDomain

public void updateDomain(DomainRow domain)
                  throws AdminPersistenceException
Updates a domain row.

Parameters:
domain -
Throws:
AdminPersistenceException

prepareUpdate

protected void prepareUpdate(String updateQuery,
                             PreparedStatement update,
                             DomainRow row)
                      throws SQLException
Description copied from class: Table
Set all the parameters of the update PreparedStatement built from the updateQuery in order to update the given row.

Specified by:
prepareUpdate in class Table<DomainRow>
Throws:
SQLException

removeDomain

public void removeDomain(int id)
                  throws AdminPersistenceException
Delete the domain

Parameters:
id -
Throws:
AdminPersistenceException

fetchRow

protected DomainRow fetchRow(ResultSet rs)
                      throws SQLException
Fetch the current domain row from a resultSet.

Specified by:
fetchRow in class Table<DomainRow>
Returns:
Throws:
SQLException


Copyright © 2016 Silverpeas. All Rights Reserved.