com.irisel.oms.olapi
Class CLBrowserBase

java.lang.Object
  extended by com.irisel.oms.olapi.CLBrowserBase
All Implemented Interfaces:
CLBrowser
Direct Known Subclasses:
CLBrowserImpl, CLEnterpriseBrowser

public abstract class CLBrowserBase
extends java.lang.Object
implements CLBrowser

Common implementation of Data Access API "CLBrowser" extended by 2-layer and 3-layer implementations. Abstract, because server side browser type is not determined.

Author:
Administrador
See Also:
CLBrowser, CLBrowserImpl, CLGuiomBrowser, CLEnterpriseBrowser, CLEJBBrowser, CLWSBrowserImpl

Nested Class Summary
 
Nested classes/interfaces inherited from interface com.irisel.oms.olapi.CLBrowser
CLBrowser.AuthState
 
Field Summary
 
Fields inherited from interface com.irisel.oms.olapi.CLBrowser
CONFIG_FILE, KEY_APP_PASS, KEY_APP_USER, KEY_DB_DATABASE, KEY_DB_PASS, KEY_DB_PORT, KEY_DB_SCHEMA, KEY_DB_SERV, KEY_DB_TYPE, KEY_DB_USER, KEY_OL_SCH_FILE
 
Constructor Summary
CLBrowserBase()
           
 
Method Summary
 CLBrowser.AuthState authenticate(java.lang.String user, java.lang.String pass)
           
 boolean changePassword(java.lang.String user, java.lang.String pass, java.lang.String newpass)
          Used to reset own's password Updates the internal tables and the database credentials For system account, updates the encrypted password.
abstract  long create(Instance i)
           
 DescriptionVO createDescriptionVO(java.lang.String lang, long descId, java.lang.String domain, java.lang.String name, java.lang.String description, java.lang.String shortDescription, java.lang.String comments)
           
 DescriptionVO createDescriptionVO(java.lang.String domain, java.lang.String name)
           
 DescriptionVO createDescriptionVO(java.lang.String domain, java.lang.String name, java.lang.String description)
           
 DescriptionVO createDescriptionVO(java.lang.String domain, java.lang.String name, java.lang.String description, java.lang.String shortDescription, java.lang.String comments)
           
abstract  boolean doRefresh()
           
 boolean doRefresh(java.lang.Boolean b)
           
 java.lang.String echo(java.lang.String challenge)
           
 DataInstanceSet executeQuery(SelectQuery q, java.lang.Boolean formattedValues)
           
abstract  DataInstanceSet executeQuery(java.lang.String classname, SelectQuery q)
          "@deprecated
 void flushPrivileges()
           
abstract  AppVO getApp()
           
 AppVO getAppOld()
           
 java.lang.String getAuthType()
           
 ClassVO getClass(long classid)
           
 ClassVO getClass(java.lang.String classname)
           
 InstanceSet getConfigItems(java.lang.String configSet, java.lang.String configItem)
           
 java.lang.String getConfigItemValue(java.lang.String configSet, java.lang.String configItem)
           
 java.lang.String getConfigItemValue(java.lang.String configSet, java.lang.String configItem, java.lang.String defaultValue)
           
 java.lang.String getDatabaseName()
           
 java.lang.String getDbType()
           
 java.lang.String[] getDBTypes()
           
 RoleVO getDefaultRole()
           
 DescriptionVO getDescriptionVO(java.lang.Long descId)
           
 DescriptionVO getDescriptionVOFromDB(java.lang.Long id, java.lang.String lang)
           
 javax.swing.Icon getIcon(java.lang.String classname)
           
 Instance getInstance(Instance i)
           
 Instance getInstance(long classid, long oid)
           
 Instance getInstance(long classid, java.lang.String filter, java.lang.String value)
           
 Instance getInstance(java.lang.String classname, long oid)
           
 Instance getInstance(java.lang.String classname, java.lang.String filter, java.lang.String value)
          Returns the record set from classname table/view where filter=value.
 java.lang.Long getInstanceCount(java.lang.String classname, java.lang.String filter, int operator, java.lang.String value)
           
 InstanceSet getInstances(java.lang.String string)
           
 InstanceSet getInstanceSet(long classid, java.lang.String filter, java.lang.String value)
           
 InstanceSet getInstanceSet(java.lang.String classname, java.lang.String filter, int operator, java.lang.Object value)
          Selects instances by filter and with valid status (positive, not null)
 InstanceSet getInstanceSet(java.lang.String classname, java.lang.String filter, java.lang.String value)
           
 InstanceSet getInstanceSetValidStatus(java.lang.String classname, java.lang.String filter, int operator, java.lang.Object value, boolean bValidStatus)
          Selects instances by filter and with valid status (positive, not null)
 InstanceSet getInstanceSetValidStatus(java.lang.String classname, java.lang.String filter, java.lang.String value, boolean bValidStatus)
           
 ListVO getListById(long listId)
           
 ListVO getListByName(java.lang.String listName)
           
 ListVO getListByParent(ListElmVO listElmVO)
           
 ListVO[] getLists()
           
 java.lang.String getMode()
           
 java.lang.String getPass()
           
 com.irisel.oms.olapi.CLBrowserBase.PerfStats getPerfStats()
           
 java.lang.String getPort()
           
abstract  long getPrimaryKeys(java.lang.String type, java.lang.String classname, java.lang.Integer num)
           
 PropertyVO getProperty(java.lang.String classname, java.lang.String propertyname)
           
 RelationVO getRelation(ClassVO clsvo, PropertyVO propvo)
           
 RelationVO getRelation(java.lang.String relname)
           
 byte[] getResourceBytes(java.lang.String uri)
           
 ListVO getSelectedListVO(Instance inst, int col)
          Returns the ListVO matching a property field of an instance record.
 java.lang.String getServer()
           
 java.lang.String getUser()
           
 java.lang.String getUserRecord()
           
 void grantExecOnFunction(java.lang.String function, java.lang.String user)
           
abstract  void impersonate(java.lang.String user, java.lang.String pass)
           
 void initApp()
          Initializes model.
 boolean isEnableFilterInactiveStates()
           
 void logPerformance(java.lang.String operation, long duration)
           
 Instance newInstance(java.lang.String classname)
           
 boolean resetUserPassword(java.lang.String adminuser, java.lang.String adminpass, java.lang.String user, java.lang.String newpass)
          Used to reset own's password Updates the internal tables and the database credentials For system account, updates the encrypted password.
 void saveAppVO()
           
abstract  void saveAppVO(AppVO newAppVO)
           
 boolean saveList(ListVO listvo)
           
 void setAutomaticFields(Instance instance)
           
 void setConfigItemValue(java.lang.String config_set, java.lang.String config_item, java.lang.Object value)
           
 void setDatabaseName(java.lang.String dbname)
           
 void setDbType(java.lang.String dbType)
           
 void setDescription(ClassVO c, DescriptionVO v)
           
 void setDescription(PropertyVO p, DescriptionVO v)
           
 void setDescription(RelationVO r, DescriptionVO v)
           
 void setEnableFilterInactiveStates(boolean enableFilterInactiveStates)
           
 void setMode(java.lang.String mode)
           
 void setPass(java.lang.String pass)
           
 void setPort(java.lang.String port)
           
 void setSchema(java.lang.String schema)
           
 void setServer(java.lang.String server)
           
 void setUser(java.lang.String user)
           
 java.lang.String toString()
           
 boolean unlockAccount(java.lang.String adminuser, java.lang.String adminpass, java.lang.String user)
           
abstract  int update(Instance i)
           
 DescriptionVO updateDescriptionVO(DescriptionVO descvo, java.lang.String domain, java.lang.String name, java.lang.String description, java.lang.String shortDescription, java.lang.String comments)
           
 int updateModelVersion()
           
 ValidationVO validate(Instance instance)
           
 int verifyMandatory(Instance inst)
          Deprecated. use validate() instead
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.irisel.oms.olapi.CLBrowser
createDescriptionId, delete, doRefresh, executeQuery, executeText, executeTextNoReturn, findClass, getBytecode, getDescriptionVO, getDescriptionVO, getDescriptionVOFromDB, getDescriptionVOFromDB, getSchema, getSerial, getVersion, saveFile
 

Constructor Detail

CLBrowserBase

public CLBrowserBase()
Method Detail

getPerfStats

public com.irisel.oms.olapi.CLBrowserBase.PerfStats getPerfStats()
Specified by:
getPerfStats in interface CLBrowser

echo

public java.lang.String echo(java.lang.String challenge)
Specified by:
echo in interface CLBrowser

logPerformance

public void logPerformance(java.lang.String operation,
                           long duration)

authenticate

public CLBrowser.AuthState authenticate(java.lang.String user,
                                        java.lang.String pass)
                                 throws AuthenticationException,
                                        java.sql.SQLException,
                                        java.rmi.RemoteException
Specified by:
authenticate in interface CLBrowser
Throws:
AuthenticationException
java.sql.SQLException
java.rmi.RemoteException

changePassword

public boolean changePassword(java.lang.String user,
                              java.lang.String pass,
                              java.lang.String newpass)
                       throws AuthenticationException,
                              java.sql.SQLException,
                              java.rmi.RemoteException
Used to reset own's password Updates the internal tables and the database credentials For system account, updates the encrypted password. Flushes privileges

Specified by:
changePassword in interface CLBrowser
Throws:
AuthenticationException
java.sql.SQLException
java.rmi.RemoteException

resetUserPassword

public boolean resetUserPassword(java.lang.String adminuser,
                                 java.lang.String adminpass,
                                 java.lang.String user,
                                 java.lang.String newpass)
                          throws AuthenticationException,
                                 java.sql.SQLException,
                                 java.rmi.RemoteException
Used to reset own's password Updates the internal tables and the database credentials For system account, updates the encrypted password. Flushes privileges

Specified by:
resetUserPassword in interface CLBrowser
Throws:
AuthenticationException
java.sql.SQLException
java.rmi.RemoteException

unlockAccount

public boolean unlockAccount(java.lang.String adminuser,
                             java.lang.String adminpass,
                             java.lang.String user)
                      throws java.rmi.RemoteException,
                             java.sql.SQLException,
                             AuthenticationException
Specified by:
unlockAccount in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
AuthenticationException

grantExecOnFunction

public void grantExecOnFunction(java.lang.String function,
                                java.lang.String user)

flushPrivileges

public void flushPrivileges()

create

public abstract long create(Instance i)
                     throws java.sql.SQLException,
                            java.rmi.RemoteException,
                            DataException
Specified by:
create in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException
DataException

validate

public ValidationVO validate(Instance instance)
Specified by:
validate in interface CLBrowser
Returns:
-1 if no error found, or the index of the value that does not pass validation

updateDescriptionVO

public DescriptionVO updateDescriptionVO(DescriptionVO descvo,
                                         java.lang.String domain,
                                         java.lang.String name,
                                         java.lang.String description,
                                         java.lang.String shortDescription,
                                         java.lang.String comments)
                                  throws java.rmi.RemoteException
Specified by:
updateDescriptionVO in interface CLBrowser
Throws:
java.rmi.RemoteException

createDescriptionVO

public DescriptionVO createDescriptionVO(java.lang.String domain,
                                         java.lang.String name)
                                  throws java.rmi.RemoteException
Specified by:
createDescriptionVO in interface CLBrowser
Throws:
java.rmi.RemoteException

createDescriptionVO

public DescriptionVO createDescriptionVO(java.lang.String domain,
                                         java.lang.String name,
                                         java.lang.String description)
                                  throws java.rmi.RemoteException
Specified by:
createDescriptionVO in interface CLBrowser
Throws:
java.rmi.RemoteException

createDescriptionVO

public DescriptionVO createDescriptionVO(java.lang.String domain,
                                         java.lang.String name,
                                         java.lang.String description,
                                         java.lang.String shortDescription,
                                         java.lang.String comments)
                                  throws java.rmi.RemoteException
Specified by:
createDescriptionVO in interface CLBrowser
Throws:
java.rmi.RemoteException

createDescriptionVO

public DescriptionVO createDescriptionVO(java.lang.String lang,
                                         long descId,
                                         java.lang.String domain,
                                         java.lang.String name,
                                         java.lang.String description,
                                         java.lang.String shortDescription,
                                         java.lang.String comments)
                                  throws java.rmi.RemoteException
Specified by:
createDescriptionVO in interface CLBrowser
Throws:
java.rmi.RemoteException

setDescription

public void setDescription(ClassVO c,
                           DescriptionVO v)
                    throws java.rmi.RemoteException,
                           java.sql.SQLException,
                           DataException
Specified by:
setDescription in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
DataException

setDescription

public void setDescription(RelationVO r,
                           DescriptionVO v)
                    throws java.rmi.RemoteException,
                           java.sql.SQLException,
                           DataException
Specified by:
setDescription in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
DataException

setDescription

public void setDescription(PropertyVO p,
                           DescriptionVO v)
                    throws java.rmi.RemoteException,
                           java.sql.SQLException,
                           DataException
Specified by:
setDescription in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
DataException

doRefresh

public abstract boolean doRefresh()
                           throws java.sql.SQLException,
                                  java.rmi.RemoteException,
                                  QueryTreeException,
                                  ConnectionException,
                                  DataModelException
Specified by:
doRefresh in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException
QueryTreeException
ConnectionException
DataModelException

doRefresh

public boolean doRefresh(java.lang.Boolean b)
                  throws java.sql.SQLException,
                         java.rmi.RemoteException,
                         QueryTreeException,
                         ConnectionException,
                         DataModelException
Specified by:
doRefresh in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException
QueryTreeException
ConnectionException
DataModelException

executeQuery

public abstract DataInstanceSet executeQuery(java.lang.String classname,
                                             SelectQuery q)
                                      throws java.sql.SQLException,
                                             java.rmi.RemoteException
Description copied from interface: CLBrowser
"@deprecated

Specified by:
executeQuery in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

executeQuery

public DataInstanceSet executeQuery(SelectQuery q,
                                    java.lang.Boolean formattedValues)
                             throws java.sql.SQLException,
                                    java.rmi.RemoteException
Specified by:
executeQuery in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

getApp

public abstract AppVO getApp()
Specified by:
getApp in interface CLBrowser

getAppOld

public AppVO getAppOld()
                throws ConnectionException,
                       DataModelException
Throws:
ConnectionException
DataModelException

getAuthType

public java.lang.String getAuthType()
                             throws java.rmi.RemoteException,
                                    java.sql.SQLException,
                                    QueryTreeException
Specified by:
getAuthType in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
QueryTreeException

getClass

public ClassVO getClass(long classid)
Specified by:
getClass in interface CLBrowser

getClass

public ClassVO getClass(java.lang.String classname)
Specified by:
getClass in interface CLBrowser

getConfigItems

public InstanceSet getConfigItems(java.lang.String configSet,
                                  java.lang.String configItem)
                           throws java.rmi.RemoteException,
                                  java.sql.SQLException,
                                  QueryTreeException
Specified by:
getConfigItems in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
QueryTreeException

getConfigItemValue

public java.lang.String getConfigItemValue(java.lang.String configSet,
                                           java.lang.String configItem)
                                    throws java.rmi.RemoteException,
                                           java.sql.SQLException,
                                           QueryTreeException
Specified by:
getConfigItemValue in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
QueryTreeException

getConfigItemValue

public java.lang.String getConfigItemValue(java.lang.String configSet,
                                           java.lang.String configItem,
                                           java.lang.String defaultValue)
                                    throws java.rmi.RemoteException,
                                           java.sql.SQLException,
                                           QueryTreeException
Specified by:
getConfigItemValue in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
QueryTreeException

setConfigItemValue

public void setConfigItemValue(java.lang.String config_set,
                               java.lang.String config_item,
                               java.lang.Object value)

getDatabaseName

public java.lang.String getDatabaseName()
Specified by:
getDatabaseName in interface CLBrowser

getDBTypes

public java.lang.String[] getDBTypes()
                              throws ConfigException
Specified by:
getDBTypes in interface CLBrowser
Throws:
ConfigException

getDefaultRole

public RoleVO getDefaultRole()
Specified by:
getDefaultRole in interface CLBrowser

getIcon

public javax.swing.Icon getIcon(java.lang.String classname)
Specified by:
getIcon in interface CLBrowser

getInstance

public Instance getInstance(long classid,
                            java.lang.String filter,
                            java.lang.String value)
                     throws java.sql.SQLException,
                            java.rmi.RemoteException
Specified by:
getInstance in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

getInstance

public Instance getInstance(java.lang.String classname,
                            java.lang.String filter,
                            java.lang.String value)
                     throws java.sql.SQLException,
                            java.rmi.RemoteException
Returns the record set from classname table/view where filter=value. If no record found returns null.

Specified by:
getInstance in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

getInstanceSetValidStatus

public InstanceSet getInstanceSetValidStatus(java.lang.String classname,
                                             java.lang.String filter,
                                             int operator,
                                             java.lang.Object value,
                                             boolean bValidStatus)
                                      throws java.sql.SQLException,
                                             java.rmi.RemoteException
Selects instances by filter and with valid status (positive, not null)

Specified by:
getInstanceSetValidStatus in interface CLBrowser
Parameters:
classname -
filter -
operator -
value -
bValidStatus - - Filter negative and null status, if true
Returns:
Throws:
java.sql.SQLException
java.rmi.RemoteException

getInstanceSet

public InstanceSet getInstanceSet(java.lang.String classname,
                                  java.lang.String filter,
                                  int operator,
                                  java.lang.Object value)
                           throws java.sql.SQLException,
                                  java.rmi.RemoteException
Selects instances by filter and with valid status (positive, not null)

Specified by:
getInstanceSet in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

getInstanceSet

public InstanceSet getInstanceSet(long classid,
                                  java.lang.String filter,
                                  java.lang.String value)
                           throws java.sql.SQLException,
                                  java.rmi.RemoteException
Specified by:
getInstanceSet in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

getInstanceSet

public InstanceSet getInstanceSet(java.lang.String classname,
                                  java.lang.String filter,
                                  java.lang.String value)
                           throws java.sql.SQLException,
                                  java.rmi.RemoteException
Specified by:
getInstanceSet in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

getInstanceSetValidStatus

public InstanceSet getInstanceSetValidStatus(java.lang.String classname,
                                             java.lang.String filter,
                                             java.lang.String value,
                                             boolean bValidStatus)
                                      throws java.sql.SQLException,
                                             java.rmi.RemoteException
Specified by:
getInstanceSetValidStatus in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

getInstances

public InstanceSet getInstances(java.lang.String string)
                         throws java.rmi.RemoteException,
                                java.sql.SQLException
Specified by:
getInstances in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException

getInstance

public Instance getInstance(Instance i)
                     throws java.rmi.RemoteException,
                            java.sql.SQLException
Specified by:
getInstance in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException

getInstance

public Instance getInstance(long classid,
                            long oid)
                     throws java.rmi.RemoteException,
                            java.sql.SQLException
Specified by:
getInstance in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException

getInstance

public Instance getInstance(java.lang.String classname,
                            long oid)
                     throws java.rmi.RemoteException,
                            java.sql.SQLException
Specified by:
getInstance in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException

getInstanceCount

public java.lang.Long getInstanceCount(java.lang.String classname,
                                       java.lang.String filter,
                                       int operator,
                                       java.lang.String value)
                                throws java.rmi.RemoteException,
                                       java.sql.SQLException
Specified by:
getInstanceCount in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException

getListById

public ListVO getListById(long listId)
                   throws ListNotFoundException
Specified by:
getListById in interface CLBrowser
Throws:
ListNotFoundException

getListByName

public ListVO getListByName(java.lang.String listName)
                     throws ListNotFoundException
Specified by:
getListByName in interface CLBrowser
Throws:
ListNotFoundException

getListByParent

public ListVO getListByParent(ListElmVO listElmVO)
Specified by:
getListByParent in interface CLBrowser

getLists

public ListVO[] getLists()
Specified by:
getLists in interface CLBrowser

getMode

public java.lang.String getMode()
Specified by:
getMode in interface CLBrowser

getPass

public java.lang.String getPass()

getPort

public java.lang.String getPort()
Specified by:
getPort in interface CLBrowser

getPrimaryKeys

public abstract long getPrimaryKeys(java.lang.String type,
                                    java.lang.String classname,
                                    java.lang.Integer num)
                             throws java.sql.SQLException,
                                    java.rmi.RemoteException
Specified by:
getPrimaryKeys in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

getProperty

public PropertyVO getProperty(java.lang.String classname,
                              java.lang.String propertyname)
Specified by:
getProperty in interface CLBrowser

getRelation

public RelationVO getRelation(java.lang.String relname)
Specified by:
getRelation in interface CLBrowser

getRelation

public RelationVO getRelation(ClassVO clsvo,
                              PropertyVO propvo)
Specified by:
getRelation in interface CLBrowser

getServer

public java.lang.String getServer()
Specified by:
getServer in interface CLBrowser

getUser

public java.lang.String getUser()

getUserRecord

public java.lang.String getUserRecord()

impersonate

public abstract void impersonate(java.lang.String user,
                                 java.lang.String pass)
                          throws AuthenticationException,
                                 java.rmi.RemoteException,
                                 QueryTreeException,
                                 DataModelException,
                                 ConnectionException,
                                 java.sql.SQLException
Specified by:
impersonate in interface CLBrowser
Throws:
AuthenticationException
java.rmi.RemoteException
QueryTreeException
DataModelException
ConnectionException
java.sql.SQLException

initApp

public void initApp()
             throws java.rmi.RemoteException,
                    QueryTreeException,
                    ConnectionException,
                    DataModelException
Initializes model. Must be called after setting browser for the first time

Throws:
java.rmi.RemoteException
QueryTreeException
ConnectionException
DataModelException

saveAppVO

public void saveAppVO()
               throws SchemaUpdateException,
                      DataModelException,
                      java.rmi.RemoteException
Specified by:
saveAppVO in interface CLBrowser
Throws:
SchemaUpdateException
DataModelException
java.rmi.RemoteException

saveAppVO

public abstract void saveAppVO(AppVO newAppVO)
                        throws DataModelException,
                               java.rmi.RemoteException,
                               SchemaUpdateException
Specified by:
saveAppVO in interface CLBrowser
Throws:
DataModelException
java.rmi.RemoteException
SchemaUpdateException

saveList

public boolean saveList(ListVO listvo)
                 throws java.rmi.RemoteException,
                        java.sql.SQLException,
                        DataException,
                        QuerySaveException
Specified by:
saveList in interface CLBrowser
Throws:
java.rmi.RemoteException
java.sql.SQLException
DataException
QuerySaveException

setDatabaseName

public void setDatabaseName(java.lang.String dbname)
Specified by:
setDatabaseName in interface CLBrowser

setSchema

public void setSchema(java.lang.String schema)
Specified by:
setSchema in interface CLBrowser

setMode

public void setMode(java.lang.String mode)

setPass

public void setPass(java.lang.String pass)

setPort

public void setPort(java.lang.String port)
Specified by:
setPort in interface CLBrowser

setServer

public void setServer(java.lang.String server)
Specified by:
setServer in interface CLBrowser

setUser

public void setUser(java.lang.String user)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

update

public abstract int update(Instance i)
                    throws java.sql.SQLException,
                           java.rmi.RemoteException,
                           DataException
Specified by:
update in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException
DataException

updateModelVersion

public int updateModelVersion()
                       throws java.sql.SQLException,
                              QueryTreeException,
                              QuerySaveException,
                              java.rmi.RemoteException,
                              DataModelException,
                              ConnectionException
Specified by:
updateModelVersion in interface CLBrowser
Throws:
java.sql.SQLException
QueryTreeException
QuerySaveException
java.rmi.RemoteException
DataModelException
ConnectionException

verifyMandatory

public int verifyMandatory(Instance inst)
                    throws DataModelException
Deprecated. use validate() instead

Specified by:
verifyMandatory in interface CLBrowser
Throws:
DataModelException

newInstance

public Instance newInstance(java.lang.String classname)
Specified by:
newInstance in interface CLBrowser

getSelectedListVO

public ListVO getSelectedListVO(Instance inst,
                                int col)
                         throws ListNotFoundException
Returns the ListVO matching a property field of an instance record. In OMS metadata, when a property has type=1 (List), type2 holds the list name and level. Second, third level lists depend on the selection of the first level lists, assigned to another property in the same instance. When, in the same record, two sets of properties are associated to the same list, the second set levels will be 101,102,103... Example: In a flight ticket, origin country, origin airport, destination country, destination airport are two sets of airport list. The first level would be made of airport countries, the second level lists are the list of airports within a given country. The property level for origin country would be level 1, origin airport would be level 2. Destination country would be level 101, destination airport would be level 102. In general, for N-th set, the first level will be (n-1)*100+1.

Specified by:
getSelectedListVO in interface CLBrowser
Parameters:
inst - is a data instance (record from db)
col - is the column number (starting from 0)
Returns:
the list for that column in the context of the values of the record.
Throws:
ListNotFoundException

getResourceBytes

public byte[] getResourceBytes(java.lang.String uri)
Specified by:
getResourceBytes in interface CLBrowser

getDescriptionVO

public DescriptionVO getDescriptionVO(java.lang.Long descId)
                               throws java.rmi.RemoteException
Specified by:
getDescriptionVO in interface CLBrowser
Throws:
java.rmi.RemoteException

getDescriptionVOFromDB

public DescriptionVO getDescriptionVOFromDB(java.lang.Long id,
                                            java.lang.String lang)
                                     throws java.sql.SQLException,
                                            java.rmi.RemoteException
Specified by:
getDescriptionVOFromDB in interface CLBrowser
Throws:
java.sql.SQLException
java.rmi.RemoteException

setAutomaticFields

public void setAutomaticFields(Instance instance)
Specified by:
setAutomaticFields in interface CLBrowser

isEnableFilterInactiveStates

public boolean isEnableFilterInactiveStates()
Specified by:
isEnableFilterInactiveStates in interface CLBrowser

setEnableFilterInactiveStates

public void setEnableFilterInactiveStates(boolean enableFilterInactiveStates)
Specified by:
setEnableFilterInactiveStates in interface CLBrowser

getDbType

public java.lang.String getDbType()
Specified by:
getDbType in interface CLBrowser

setDbType

public void setDbType(java.lang.String dbType)
Specified by:
setDbType in interface CLBrowser