org.opensubsystems.inventory.persist.db
Class ItemUnitIdentificationViewDatabaseSchema

java.lang.Object
  extended by org.opensubsystems.core.persist.db.DatabaseSchemaImpl
      extended by org.opensubsystems.patterns.listdata.persist.db.impl.ListDatabaseSchemaImpl
          extended by org.opensubsystems.inventory.persist.db.ItemUnitIdentificationViewDatabaseSchema
All Implemented Interfaces:
org.opensubsystems.core.persist.db.DatabaseOperations, org.opensubsystems.core.persist.db.DatabaseSchema, org.opensubsystems.patterns.listdata.persist.db.ListDatabaseSchema

public class ItemUnitIdentificationViewDatabaseSchema
extends org.opensubsystems.patterns.listdata.persist.db.impl.ListDatabaseSchemaImpl

Database specific operations related to retrieval of combined items, units and identifications.

Version:
$Id: ItemUnitIdentificationViewDatabaseSchema.java,v 1.8 2007/01/28 06:54:43 bastafidli Exp $
Author:
Miro Halas
Code reviewer:
TODO: Review this code
Code reviewed:

Field Summary
static java.lang.String ITEM_UNIT_IDENTIFICATION_VIEW_SCHEMA_NAME
          Name identifies this schema in the database.
static int ITEM_UNIT_IDENTIFICATIONVIEW_SCHEMA_VERSION
          Version of this schema in the database.
static int[] ITEMUNITIDENT_MANDATORY_RETRIEVE_COLUMNS
          Columns which always have to be retrieved from the database
static int[] ITEMUNITIDENT_SORT_COLUMNS
          Static variable for array of all columns codes that can be used for sorting.
 
Fields inherited from class org.opensubsystems.patterns.listdata.persist.db.impl.ListDatabaseSchemaImpl
m_mapFilterableColumns, m_mapListableTableNames, m_mapMandatoryRetrieveColumns, m_mapSortableColumns
 
Fields inherited from class org.opensubsystems.core.persist.db.DatabaseSchemaImpl
DATABASE_SCHEMA_PREFIX, DATABASE_SCHEMA_PREFIX_DEFAULT, m_arrDependentSchemas, m_bIsInDomain, m_iSchemaVersion, m_strSchemaName, NL
 
Fields inherited from interface org.opensubsystems.core.persist.db.DatabaseOperations
DBOP_DELETE, DBOP_INSERT, DBOP_SELECT, DBOP_UPDATE
 
Constructor Summary
ItemUnitIdentificationViewDatabaseSchema()
          Default constructor.
 
Method Summary
 void create(java.sql.Connection cntDBConnection, java.lang.String strUserName)
          Create the schema.
static java.lang.String getColumn(int iColumnId)
          Get name for specified column code or null if the column is not recognized.
 java.lang.StringBuffer getColumns(boolean specific, int[] columns, java.lang.Object[] prefixes, java.lang.Object[] postfixes, java.lang.StringBuffer buffer)
          
 java.lang.String getSelectItemUnitIdentificationViewById(int[] columns)
          Get query to retrieve item unit identification view by id
 
Methods inherited from class org.opensubsystems.patterns.listdata.persist.db.impl.ListDatabaseSchemaImpl
getFilterbleColumns, getMandatoryRetrieveColumns, getSelectList, getSortableColumns
 
Methods inherited from class org.opensubsystems.core.persist.db.DatabaseSchemaImpl
getDependentSchemas, getJoinFromWhere, getName, getOwnerColumnNames, getSchemaPrefix, getVersion, handleSQLException, isExistingIndex, isInDomain, upgrade, upgradeView
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.opensubsystems.patterns.listdata.persist.db.ListDatabaseSchema
getJoinFromWhere, isExistingIndex
 
Methods inherited from interface org.opensubsystems.core.persist.db.DatabaseSchema
getDependentSchemas, getName, getVersion, handleSQLException, isInDomain, upgrade
 

Field Detail

ITEM_UNIT_IDENTIFICATION_VIEW_SCHEMA_NAME

public static final java.lang.String ITEM_UNIT_IDENTIFICATION_VIEW_SCHEMA_NAME
Name identifies this schema in the database.

See Also:
Constant Field Values

ITEM_UNIT_IDENTIFICATIONVIEW_SCHEMA_VERSION

public static final int ITEM_UNIT_IDENTIFICATIONVIEW_SCHEMA_VERSION
Version of this schema in the database.

See Also:
Constant Field Values

ITEMUNITIDENT_MANDATORY_RETRIEVE_COLUMNS

public static final int[] ITEMUNITIDENT_MANDATORY_RETRIEVE_COLUMNS
Columns which always have to be retrieved from the database


ITEMUNITIDENT_SORT_COLUMNS

public static final int[] ITEMUNITIDENT_SORT_COLUMNS
Static variable for array of all columns codes that can be used for sorting.

Constructor Detail

ItemUnitIdentificationViewDatabaseSchema

public ItemUnitIdentificationViewDatabaseSchema()
                                         throws org.opensubsystems.core.error.OSSException
Default constructor.

Throws:
org.opensubsystems.core.error.OSSException - - error occured.
Method Detail

getSelectItemUnitIdentificationViewById

public java.lang.String getSelectItemUnitIdentificationViewById(int[] columns)
                                                         throws org.opensubsystems.core.error.OSSException
Get query to retrieve item unit identification view by id

Parameters:
columns - - columns to retrieve
Returns:
String - query
Throws:
org.opensubsystems.core.error.OSSException - - an error has occured

getColumns

public java.lang.StringBuffer getColumns(boolean specific,
                                         int[] columns,
                                         java.lang.Object[] prefixes,
                                         java.lang.Object[] postfixes,
                                         java.lang.StringBuffer buffer)
                                  throws org.opensubsystems.core.error.OSSException

Throws:
org.opensubsystems.core.error.OSSException

getColumn

public static java.lang.String getColumn(int iColumnId)
Get name for specified column code or null if the column is not recognized.

Parameters:
iColumnId - - column code to get the name for
Returns:
String - column name or null if the column is not recognized

create

public void create(java.sql.Connection cntDBConnection,
                   java.lang.String strUserName)
            throws java.sql.SQLException
Create the schema.

Parameters:
cntDBConnection - - valid connection to database
strUserName - - name of user who will be accessing this table
Throws:
java.sql.SQLException - - an error while creating schema


Copyright © 2003 - 2006 OpenSubsystems s.r.o.