Enterprise Information Portal APIs

com.ibm.mm.sdk.server
Class DKDatastoreDES

java.lang.Object
  |
  +--com.ibm.mm.sdk.server.dkAbstractDatastore
        |
        +--com.ibm.mm.sdk.server.DKDatastoreDES
All Implemented Interfaces:
DKConstant, DKConstantDES, dkDatastore, dkDatastoreIntDES, DKMessageId, DKMessageIdDES, dkQueryEvaluator, dkQueryManager

public class DKDatastoreDES
extends dkAbstractDatastore
implements dkDatastoreIntDES, DKConstantDES, DKMessageIdDES

DKDatastoreDES is the specific version of dkDatastore to implement the Lotus Domino Extended Search datastore. It provides Documents, Parts and Folders storage and retrieval mechanisms, as well as search and other document processing capabilities supported by DES.


Field Summary
 com.ibm.bts.es.cliSrv.EsDatabaseAccessRMI _ics_rmiref
           
 
Fields inherited from interface com.ibm.mm.sdk.common.DKConstantDES
DK_DES_APPID_HANDLE, DK_DES_APPINFO_HANDLE, DK_DES_BROKER_HANDLE, DK_DES_CMBROOT, DK_DES_DATASOURCE, DK_DES_DLL_NAME, DK_DES_DSTYPE, DK_DES_GQL_QL_TYPE, DK_DES_INIFILE, DK_DES_ITEMID_SEPARATOR, DK_DES_PORT, DK_DES_PROPERTY_DISPNAME, DK_DES_PROPERTY_HELPTEXT, DK_DES_PROPERTY_LANGUAGE, DK_DES_PROPERTY_RETRIEVABLE, DK_DES_PROPERTY_SEARCHABLE, DK_DES_PROPERTY_SEARCHOPERATOR, DK_DES_PROPERTY_VALUECOUNT, DK_DES_REPOSITORIES_HANDLE, DK_DES_RMIREF_HANDLE, DK_DES_SESSION_HANDLE, DK_FILESYSTEM_ENTITY, DK_NOTES_ENTITY, DK_NOTESPUMP_ENTITY, DK_WEB_ENTITY
 
Fields inherited from interface com.ibm.mm.sdk.common.DKConstant
    For details, see the class or interface
 
Fields inherited from interface com.ibm.mm.sdk.common.DKMessageIdDES
DK_DES_MSG_MSGID_NOT_FOUND
 
Fields inherited from interface com.ibm.mm.sdk.common.DKMessageId
    For details, see the class or interface
 
Constructor Summary
DKDatastoreDES()
          Constructs the datastore and initializes the datastore with the default CC2MIME object.
DKDatastoreDES(java.lang.String configuration)
          Constructs the datastore and initializes the datastore with the DKCC2Mime object based on the configuration string
 
Method Summary
 void addExtension(java.lang.String extensionName, dkExtension extensionObj)
          Adds a new extension object.
 void addObject(dkDataObject ddo)
          Adds this ddo to this datastore.
 void addStoredQueryAndSchedule(java.lang.String queryStr, DKNVPair[] options)
          addStoredQueryAndSchedule will save or add a query in ES database.
 void commit()
          Commits a datastore transaction
 void connect(java.lang.String datastore_name, java.lang.String userName, java.lang.String authentication, java.lang.String connect_string)
          Connects to a datastore by initializing ES objects.
 DKHandle connection()
          Gets the connection handle for a datastore
 DKDDO createDDO(java.lang.String objectType, int Flags)
          Creates a new DDO with a basic pid for DES
 dkQuery createQuery(DKCQExpr qe)
          Creates a query object.
 dkQuery createQuery(java.lang.String command, short commandLangType, DKNVPair[] params)
          Creates a query object.
 dkDatastoreDef datastoreDef()
          Get datastore definition
 java.lang.String datastoreName()
          Gets the name of this datastore object.
 java.lang.String datastoreType()
          Gets the datastore type for this datastore object
 void deleteObject(dkDataObject ddo)
          Deletes this ddo from this datastore.
 void deleteQueryFolders(java.lang.String[] folderNames)
          deleteQueryFolders will delete the specified query folder
 void deleteStoredQueries(java.lang.String folderName, java.lang.String[] queryNames)
          deleteStoredQueries will delete the specified stored query in ES DB
 void deleteStoredQueryResultIDs(java.lang.String folderName, java.lang.String queryName, java.lang.String[] resultIDs)
          deleteStoredQueryResultIDs will delete specified resultIDs
 void destroy()
          datastore destroy - datastore cleanup if needed
 void disconnect()
          Disconnects from a datastore.
 java.lang.Object evaluate(DKCQExpr qe)
          evaluates the query.
 java.lang.Object evaluate(dkQuery query)
          evaluates the query.
 java.lang.Object evaluate(java.lang.String command, short commandLangType, DKNVPair[] params)
          evaluates the query.
 dkResultSetCursor execute(DKCQExpr cqe)
          executes the query in the DKCQExpr
 dkResultSetCursor execute(dkQuery query)
          executes the query.
 dkResultSetCursor execute(java.lang.String command, short commandLangType, DKNVPair[] params)
          executes the query.
 void executeWithCallback(DKCQExpr qe, dkCallback callbackObj)
          execute the query with callback function.
 void executeWithCallback(dkQuery query, dkCallback callbackObj)
          execute the query with callback function.
 void executeWithCallback(java.lang.String command, short commandLangType, DKNVPair[] params, dkCallback callbackObj)
          execute the query with callback function.
 DKNVPair[] getActions(java.lang.String entityName)
          getActions will return a DKNVpair with Action names (as key) and the URLS (as value) for the specified source in the specified application
 java.lang.String getConnStrFromDESRMICfgFile()
          Will return the DES rmi port and rmi reference names for DES from information in desrmi.cfg file located in the application run directory.
 java.lang.String getEntitySourceType(java.lang.String entityName)
          getEntitySourceType will return the link type of specified source
 dkExtension getExtension(java.lang.String extensionName)
          Gets the extension object from a given extension name.
 boolean getFindAllWords()
           
 int getGetPage()
           
 java.util.Locale getLocale()
          Will return the local copy of client Locale.
 java.lang.String getMailResultsTo()
           
 dkSchemaMapping getMapping(java.lang.String mappingName)
          Gets a mapping information from this datastore.
 java.lang.Object getOption(int option)
          Gets a datastore option.
 int getPageSize()
           
 java.lang.String getQuery()
           
 DKNVPair[] getQueryFolderProperties(java.lang.String folderName)
          getQueryFolderProperties will get the properties of the specified query folder
 java.lang.String getQueryId()
           
 boolean getResultsWhenAvail()
           
 boolean getScheduled()
           
 boolean getSortAscending()
           
 java.lang.String getSortField()
           
 int getSourceMaxHits()
           
 DKNVPair[] getStoredQueryOptions(java.lang.String folderName, java.lang.String queryName)
          getStoredQueryOptions will return the URL for the stored query t be displayed in the Browser
 DKNVPair[] getStoredQueryProperties(java.lang.String folderName, java.lang.String queryName)
          getStoredQueryProperties will get the properties for the specified stored query
 int getTimeOut()
           
 int getTotalMaxHits()
           
 java.lang.String getUserId()
           
 DKHandle handle(java.lang.String type)
          Gets the either the DES session handle or the broker handle based on type
 boolean isConnected()
          Checks to see if the datastore is connected.
 java.lang.String[] listDataSourceNames()
          Gets a list of datasource names
 dkCollection listDataSources()
          List the available datastore sources that you can connect to.
 dkCollection listEntities()
          Gets a list of entities from persistent datastore
 java.lang.String[] listEntityAttrNames(java.lang.String entityName)
          Gets a list of attribute names for a given entity name.
 dkCollection listEntityAttrs(java.lang.String entityName)
          Gets a list of attributes for a given entity name.
 java.lang.String[] listEntityCategoryNames()
          listEntityCategoryNames will return a String array of Category names under the specified application.
 java.lang.String[] listEntityNames()
          Gets a list of entity names from persistent datastore
 java.lang.String[] listEntityNamesByCategory(java.lang.String categoryName)
          listEntityNamesByCategory will return a String array of Source names names under the specified category in a specified application.
 java.lang.String[] listEntityNamesByCategoryAndType(java.lang.String categoryName, java.lang.String entitySourceType)
          listEntityNamesByCategoryAndType will return a String array of Source names names under the specified category in a specified application of a particulare link type.
 java.lang.String[] listExtensionNames()
          Gets the list of extension objects' names
 java.lang.String[] listFileSystemEntities()
          listFileSystemEntities will list the file system sources configured.
 java.lang.String[] listMappingNames()
          Gets the list of the registered mappings from this datastore.
 java.lang.String[] listQueryFolderNames()
          listQueryFolderNames will list all the parent level folders in the ES database
 java.lang.Object listSchema()
          List the entities that belong to this datastore
 java.lang.Object listSchemaAttributes(java.lang.String schemaEntry)
          List the attributes that belong to a schema.
 java.lang.Object listServers()
          Deprecated. Replace by listDataSources
 java.lang.String[] listStoredQueryNames(java.lang.String folderName)
          listStoredQueryNames will list all the stored queries in a folder
 java.lang.String[] listStoredQueryResultIDs(java.lang.String folderName, java.lang.String queryName)
          listStoredQueryResultIDs will list all the resultIDs in the specifed stored query Names in a folder
 void printSearchOpts()
          Will print out the variables set for the private varibale _ics_search_opts.
 void refreshDESRepositories()
          Will refresh the DES repositories by communicating to DES RMI Also refresh the repositories and rmiref handles.
 java.lang.String registerMapping(DKNVPair sourceMap)
          Registers a mapping definition to this datastore.
 void removeExtension(java.lang.String extensionName)
          Remove an existing extension object
 void retrieveObject(dkDataObject ddo)
          Retrieves the data-object from this datastore.
 void rollback()
          Rollback a datastore transaction
 void setConstraints(java.lang.String name, java.lang.String operator, java.lang.String value)
           
 void setFindAllWords(boolean bFindAll)
           
 void setGetPage(int iGetPage)
           
 void setLocale(java.util.Locale locale)
          Will set the locale for the icsBroker to pass the client locale to the ES server.
 void setLocaleForDES(java.lang.String locale)
          Will set the locale for the icsBroker.
 void setMailResultsTo(java.lang.String sMailTo)
           
 void setOption(int option, java.lang.Object value)
          Sets a datastore option.
 void setPageSize(int iPageSize)
           
 void setQuery(java.lang.String sQuery)
           
 void setQueryFolderProperties(DKNVPair[] prop)
          setQueryFolderProperties will set the properties for query folder
 void setQueryId(java.lang.String sQueryId)
           
 void setResultsWhenAvail(boolean bResultsWhenAvail)
           
 void setScheduled(boolean bScheduled)
           
 void setSortAscending(boolean bAscending)
           
 void setSortField(java.lang.String sSortField)
           
 void setSourceMaxHits(int iMaxHits)
           
 void setStoredQueryProperties(DKNVPair[] prop)
          setStoredQueryProperties will set the properties for the stored query passed in the DKNVPair
 void setTimeOut(int iTimeOut)
           
 void setUserId(java.lang.String sUserId)
           
 dkResultSetCursor storedQueryResults(java.lang.String folderName, java.lang.String queryName, java.lang.String resultID)
          storedQueryResults will return result set for specified results ID.
 DKCQExpr translate(DKCQExpr cqe)
          Translate a query expression into a native query expression processable by this datastore.
 void unRegisterMapping(java.lang.String mappingName)
          Unregisters mapping information from this datastore.
 void updateObject(dkDataObject ddo)
          Updates this ddo in this datastore.
 java.lang.String userName()
          Gets the user name for this datastore object
 
Methods inherited from class com.ibm.mm.sdk.server.dkAbstractDatastore
addObject, addObject, addObjects, addObjects, addObjects, changePassword, clearCache, clearCache, deleteObject, deleteObject, deleteObjects, deleteObjects, deleteObjects, evaluate, execute, executeWithCallback, listAvailableServices, listSearchableEntities, listSearchableEntityNames, listSearchTemplateNames, listSearchTemplates, retrieveObject, retrieveObject, retrieveObjects, retrieveObjects, retrieveObjects, serviceMgr, startTransaction, updateObject, updateObject, updateObjects, updateObjects, updateObjects
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.ibm.mm.sdk.common.dkDatastore
addObject, addObject, addObjects, addObjects, addObjects, changePassword, clearCache, clearCache, deleteObject, deleteObject, deleteObjects, deleteObjects, deleteObjects, evaluate, execute, executeWithCallback, listAvailableServices, listSearchableEntities, listSearchableEntityNames, listSearchTemplateNames, listSearchTemplates, retrieveObject, retrieveObject, retrieveObjects, retrieveObjects, retrieveObjects, serviceMgr, startTransaction, updateObject, updateObject, updateObjects, updateObjects, updateObjects
 

Field Detail

_ics_rmiref

public com.ibm.bts.es.cliSrv.EsDatabaseAccessRMI _ics_rmiref
Constructor Detail

DKDatastoreDES

public DKDatastoreDES()
               throws DKException,
                      java.lang.Exception
Constructs the datastore and initializes the datastore with the default CC2MIME object.

DKDatastoreDES

public DKDatastoreDES(java.lang.String configuration)
               throws DKException,
                      java.lang.Exception
Constructs the datastore and initializes the datastore with the DKCC2Mime object based on the configuration string
Parameters:
configuration - - info about location of the CC2MIME file
Method Detail

connect

public void connect(java.lang.String datastore_name,
                    java.lang.String userName,
                    java.lang.String authentication,
                    java.lang.String connect_string)
             throws DKException,
                    java.lang.Exception
Connects to a datastore by initializing ES objects. ES has a dependency on the relative paths of "cgi-bin" and "servlet" directories on the supporting HTTP server. If the relative paths of CGI and Servlet are anything other than "/cgi-bin" and "/servlet" on the HTTP server, please create "desclient.cfg" file in the directory where your application is running with the following information in EXACTLY the same order:
/cgi-bin/desReflector.exe
/servlet/ESAdmin
You can replace "/cgi-bin" and "/servlet" to the appropriate paths.
Specified by:
connect in interface dkDatastore
Overrides:
connect in class dkAbstractDatastore
Parameters:
datastore_name - DES server TCP/IP address
userName - the user name used for connection
authentication - the password used for connection
connect_string - a string which supplies connection parameters to establish and maintain a connection to the DES server. Valid parameters are:
PORT=value
The port number for the DES server address. This MUST be specified.
DESAPPID=value
The Application Id for DES to control access to specific databases. This MUST be specified.
DESAPPPW=value
The Application Id paswword. This MUST be specified.
DESWEBPATH=value
The webpath for servlet (eg: /lotuskms or /servlet Default is /servlet (Asuming Domino installation).

Throws:
DKException - - DKUsageError: if either datastore_name, userName, authentication or connect_string is null.
- DKDatastoreError: if connecting to the DES backend server is not successful.
java.lang.Exception - if an error occurs in the java classes.

getOption

public java.lang.Object getOption(int option)
                           throws DKException,
                                  java.lang.Exception
Gets a datastore option.
Specified by:
getOption in interface dkDatastore
Overrides:
getOption in class dkAbstractDatastore
Parameters:
option - the option identifier
Returns:
an option value

setOption

public void setOption(int option,
                      java.lang.Object value)
               throws DKException,
                      java.lang.Exception
Sets a datastore option.
Specified by:
setOption in interface dkDatastore
Overrides:
setOption in class dkAbstractDatastore
Parameters:
option - the option identifier
value - the option value

evaluate

public java.lang.Object evaluate(java.lang.String command,
                                 short commandLangType,
                                 DKNVPair[] params)
                          throws DKException,
                                 java.lang.Exception
evaluates the query.
Specified by:
evaluate in interface dkDatastore
Overrides:
evaluate in class dkAbstractDatastore
Parameters:
command - a query string
commandLang - a query type
params - additional query option in name/value pair
Returns:
a collection of the results

evaluate

public java.lang.Object evaluate(dkQuery query)
                          throws DKException,
                                 java.lang.Exception
evaluates the query.
Specified by:
evaluate in interface dkDatastore
Overrides:
evaluate in class dkAbstractDatastore
Parameters:
query - a query object
Returns:
a collection of the results

evaluate

public java.lang.Object evaluate(DKCQExpr qe)
                          throws DKException,
                                 java.lang.Exception
evaluates the query.
Specified by:
evaluate in interface dkDatastore
Overrides:
evaluate in class dkAbstractDatastore
Parameters:
qe - a common query expression object
Returns:
a collection of the results

execute

public dkResultSetCursor execute(java.lang.String command,
                                 short commandLangType,
                                 DKNVPair[] params)
                          throws DKException,
                                 java.lang.Exception
executes the query.
Specified by:
execute in interface dkDatastore
Overrides:
execute in class dkAbstractDatastore
Parameters:
command - a query string
commandLang - a query type
params - additional query option in name/value pair
Returns:
resultSetCursor which represents a datastore cursor.

execute

public dkResultSetCursor execute(dkQuery query)
                          throws DKException,
                                 java.lang.Exception
executes the query.
Specified by:
execute in interface dkDatastore
Overrides:
execute in class dkAbstractDatastore
Parameters:
query - a query object
Returns:
resultSetCursor which represents a datastore cursor.

execute

public dkResultSetCursor execute(DKCQExpr cqe)
                          throws DKException,
                                 java.lang.Exception
executes the query in the DKCQExpr
Specified by:
execute in interface dkDatastore
Overrides:
execute in class dkAbstractDatastore
Parameters:
qe - a common query expression object
Returns:
resultSetCursor which represents a datastore cursor.

executeWithCallback

public void executeWithCallback(dkQuery query,
                                dkCallback callbackObj)
                         throws DKException,
                                java.lang.Exception
execute the query with callback function.
Specified by:
executeWithCallback in interface dkDatastore
Overrides:
executeWithCallback in class dkAbstractDatastore
Parameters:
qo - a query object
callbackObj - a dkCallback object

executeWithCallback

public void executeWithCallback(java.lang.String command,
                                short commandLangType,
                                DKNVPair[] params,
                                dkCallback callbackObj)
                         throws DKException,
                                java.lang.Exception
execute the query with callback function.
Specified by:
executeWithCallback in interface dkDatastore
Overrides:
executeWithCallback in class dkAbstractDatastore
Parameters:
command - a query string
commandLang - a query type
params - additional query option in name/value pair
callbackObj - a dkCallback object

executeWithCallback

public void executeWithCallback(DKCQExpr qe,
                                dkCallback callbackObj)
                         throws DKException,
                                java.lang.Exception
execute the query with callback function.
Specified by:
executeWithCallback in interface dkDatastore
Overrides:
executeWithCallback in class dkAbstractDatastore
Parameters:
qe - a common query expression object
callbackObj - a dkCallback object

createQuery

public dkQuery createQuery(java.lang.String command,
                           short commandLangType,
                           DKNVPair[] params)
                    throws DKException,
                           java.lang.Exception
Creates a query object.
Specified by:
createQuery in interface dkDatastore
Overrides:
createQuery in class dkAbstractDatastore
Parameters:
command - a query string
commandLang - a query type
params - additional query option in name/value pair
Returns:
a query object

createQuery

public dkQuery createQuery(DKCQExpr qe)
                    throws DKException,
                           java.lang.Exception
Creates a query object.
Specified by:
createQuery in interface dkDatastore
Overrides:
createQuery in class dkAbstractDatastore
Parameters:
qe - a common query expression object

retrieveObject

public void retrieveObject(dkDataObject ddo)
                    throws DKException,
                           java.lang.Exception
Retrieves the data-object from this datastore.
Specified by:
retrieveObject in interface dkDatastore
Overrides:
retrieveObject in class dkAbstractDatastore
Parameters:
ddo - the data-object to be retrieved from this datastore
See Also:
DKDDO.retrieve()

disconnect

public void disconnect()
                throws DKException,
                       java.lang.Exception
Disconnects from a datastore.
Specified by:
disconnect in interface dkDatastore
Overrides:
disconnect in class dkAbstractDatastore

isConnected

public boolean isConnected()
                    throws java.lang.Exception
Checks to see if the datastore is connected.
Specified by:
isConnected in interface dkDatastore
Overrides:
isConnected in class dkAbstractDatastore
Returns:
true if connected

datastoreName

public java.lang.String datastoreName()
                               throws java.lang.Exception
Gets the name of this datastore object. Usually it represents a datastore source's server name.
Specified by:
datastoreName in interface dkDatastore
Overrides:
datastoreName in class dkAbstractDatastore
Returns:
datastore name

handle

public DKHandle handle(java.lang.String type)
                throws java.lang.Exception
Gets the either the DES session handle or the broker handle based on type
Specified by:
handle in interface dkDatastore
Overrides:
handle in class dkAbstractDatastore
Parameters:
type - of handle - session of broker
Returns:
session or broker handle

connection

public DKHandle connection()
                    throws java.lang.Exception
Gets the connection handle for a datastore
Specified by:
connection in interface dkDatastore
Overrides:
connection in class dkAbstractDatastore
Returns:
session handle

datastoreType

public java.lang.String datastoreType()
                               throws java.lang.Exception
Gets the datastore type for this datastore object
Specified by:
datastoreType in interface dkDatastore
Overrides:
datastoreType in class dkAbstractDatastore
Returns:
datastore type

userName

public java.lang.String userName()
                          throws java.lang.Exception
Gets the user name for this datastore object
Specified by:
userName in interface dkDatastore
Overrides:
userName in class dkAbstractDatastore
Returns:
user name

listDataSources

public dkCollection listDataSources()
                             throws DKException
List the available datastore sources that you can connect to.
Specified by:
listDataSources in interface dkDatastore
Overrides:
listDataSources in class dkAbstractDatastore
Returns:
a collection of server defs
Throws:
DKException - if internal error occurs from server

listDataSourceNames

public java.lang.String[] listDataSourceNames()
                                       throws DKException
Gets a list of datasource names
Specified by:
listDataSourceNames in interface dkDatastore
Overrides:
listDataSourceNames in class dkAbstractDatastore
Returns:
an array of datasource names
Throws:
DKException - if error occurs when retrieving datasource names

listServers

public java.lang.Object listServers()
                             throws DKException,
                                    java.lang.Exception
Deprecated. Replace by listDataSources

List the available datastore sources that can be used to connect with.
Specified by:
listServers in interface dkDatastore
Overrides:
listServers in class dkAbstractDatastore
Returns:
a collection of server definitions
See Also:
listDataSources()

listEntities

public dkCollection listEntities()
                          throws DKException,
                                 java.lang.Exception
Gets a list of entities from persistent datastore
Specified by:
listEntities in interface dkDatastore
Overrides:
listEntities in class dkAbstractDatastore
Returns:
a collection of entity defs
Throws:
DKException - if error occurs

listEntityNames

public java.lang.String[] listEntityNames()
                                   throws DKException,
                                          java.lang.Exception
Gets a list of entity names from persistent datastore
Specified by:
listEntityNames in interface dkDatastore
Overrides:
listEntityNames in class dkAbstractDatastore
Returns:
an array of entity names
Throws:
DKException - if error occurs

listEntityAttrs

public dkCollection listEntityAttrs(java.lang.String entityName)
                             throws DKException,
                                    java.lang.Exception
Gets a list of attributes for a given entity name.
Specified by:
listEntityAttrs in interface dkDatastore
Overrides:
listEntityAttrs in class dkAbstractDatastore
Parameters:
entityName - name of entity to retrieve attributes for
Returns:
a dkCollection of dkAttrDef objects
Throws:
DKException - if the entity name does not exist

listEntityAttrNames

public java.lang.String[] listEntityAttrNames(java.lang.String entityName)
                                       throws DKException,
                                              java.lang.Exception
Gets a list of attribute names for a given entity name.
Specified by:
listEntityAttrNames in interface dkDatastore
Overrides:
listEntityAttrNames in class dkAbstractDatastore
Parameters:
entityName - name of entity to retrieve attribute names for
Returns:
an array of attribute names
Throws:
DKException - if the entity name does not exist

datastoreDef

public dkDatastoreDef datastoreDef()
Get datastore definition
Specified by:
datastoreDef in interface dkDatastore
Overrides:
datastoreDef in class dkAbstractDatastore
Returns:
the meta-data (dkDatastoreDef) of this datastore

registerMapping

public java.lang.String registerMapping(DKNVPair sourceMap)
                                 throws DKException,
                                        java.lang.Exception
Registers a mapping definition to this datastore. Mapping is done by entities.
Specified by:
registerMapping in interface dkDatastore
Overrides:
registerMapping in class dkAbstractDatastore
Parameters:
sourceMap - source name and mapping, a DKNVPair class with the following possible values:
  • ("BUFFER", ) : buffer_ref is a reference to a string in memory
  • ("FILE", ) : file_name is the name of the file containing the mapping
  • ("URL", ) : URL-address location of the mapping
  • ("LDAP", ) : LDAP file-name
  • ("SCHEMA", ) : a reference to a dkSchemaMapping object defining the mapping. Currently, only "SCHEMA" option is supported, others may be added later.
    Returns:
    the name of the mapping definition.
    See Also:
    unRegisterMapping(java.lang.String)

unRegisterMapping

public void unRegisterMapping(java.lang.String mappingName)
                       throws DKException,
                              java.lang.Exception
Unregisters mapping information from this datastore.
Specified by:
unRegisterMapping in interface dkDatastore
Overrides:
unRegisterMapping in class dkAbstractDatastore
Parameters:
mappingName - name of the mapping information
See Also:
registerMapping(com.ibm.mm.sdk.common.DKNVPair)

listMappingNames

public java.lang.String[] listMappingNames()
                                    throws DKException,
                                           java.lang.Exception
Gets the list of the registered mappings from this datastore.
Specified by:
listMappingNames in interface dkDatastore
Overrides:
listMappingNames in class dkAbstractDatastore
Returns:
an array of registered mapping objects' names
See Also:
registerMapping(com.ibm.mm.sdk.common.DKNVPair)

getMapping

public dkSchemaMapping getMapping(java.lang.String mappingName)
                           throws DKException,
                                  java.lang.Exception
Gets a mapping information from this datastore.
Specified by:
getMapping in interface dkDatastore
Overrides:
getMapping in class dkAbstractDatastore
Parameters:
mappingName - name of the mapping information
Returns:
the schema mapping object
See Also:
registerMapping(com.ibm.mm.sdk.common.DKNVPair)

createDDO

public DKDDO createDDO(java.lang.String objectType,
                       int Flags)
                throws DKException,
                       java.lang.Exception
Creates a new DDO with a basic pid for DES
Specified by:
createDDO in interface dkDatastore
Overrides:
createDDO in class dkAbstractDatastore
Parameters:
objectType - the object type you want to create
Flags - not used for DES
Returns:
a new DDO of the given object type

getExtension

public dkExtension getExtension(java.lang.String extensionName)
                         throws DKException,
                                java.lang.Exception
Gets the extension object from a given extension name.
Specified by:
getExtension in interface dkDatastore
Overrides:
getExtension in class dkAbstractDatastore
Parameters:
extensionName - name of the extension object.
Returns:
extension object.

addExtension

public void addExtension(java.lang.String extensionName,
                         dkExtension extensionObj)
                  throws DKException,
                         java.lang.Exception
Adds a new extension object.
Specified by:
addExtension in interface dkDatastore
Overrides:
addExtension in class dkAbstractDatastore
Parameters:
extensionName - name of new extension object
extensionObj - the extension object to be set

removeExtension

public void removeExtension(java.lang.String extensionName)
                     throws DKException,
                            java.lang.Exception
Remove an existing extension object
Specified by:
removeExtension in interface dkDatastore
Overrides:
removeExtension in class dkAbstractDatastore
Parameters:
extensionName - name of extension object to be removed

listExtensionNames

public java.lang.String[] listExtensionNames()
                                      throws DKException,
                                             java.lang.Exception
Gets the list of extension objects' names
Specified by:
listExtensionNames in interface dkDatastore
Overrides:
listExtensionNames in class dkAbstractDatastore
Returns:
an array of extension objects' names

translate

public DKCQExpr translate(DKCQExpr cqe)
                   throws DKException,
                          java.lang.Exception
Translate a query expression into a native query expression processable by this datastore.
Parameters:
cqe - the input compound query expression
Returns:
a translated query expression or null if the expression is invalid

addObject

public void addObject(dkDataObject ddo)
               throws DKException,
                      java.lang.Exception
Description copied from interface: dkDatastore
Adds this ddo to this datastore.

Note:DKUsageError exception thrown if method is not implemented

Specified by:
addObject in interface dkDatastore
Overrides:
addObject in class dkAbstractDatastore
Following copied from interface: com.ibm.mm.sdk.common.dkDatastore
Parameters:
ddo - the ddo to be added to this datastore

deleteObject

public void deleteObject(dkDataObject ddo)
                  throws DKException,
                         java.lang.Exception
Description copied from interface: dkDatastore
Deletes this ddo from this datastore.

Note:DKUsageError exception thrown if method is not implemented

Specified by:
deleteObject in interface dkDatastore
Overrides:
deleteObject in class dkAbstractDatastore
Following copied from interface: com.ibm.mm.sdk.common.dkDatastore
Parameters:
ddo - the ddo to be deleted from this datastore

updateObject

public void updateObject(dkDataObject ddo)
                  throws DKException,
                         java.lang.Exception
Description copied from interface: dkDatastore
Updates this ddo in this datastore.

Note:DKUsageError exception thrown if method is not implemented

Specified by:
updateObject in interface dkDatastore
Overrides:
updateObject in class dkAbstractDatastore
Following copied from interface: com.ibm.mm.sdk.common.dkDatastore
Parameters:
ddo - the ddo to be updated in this datastore

commit

public void commit()
            throws DKException,
                   java.lang.Exception
Description copied from interface: dkDatastore
Commits a datastore transaction

Note:DKUsageError exception thrown if method is not implemented

Specified by:
commit in interface dkDatastore
Overrides:
commit in class dkAbstractDatastore

rollback

public void rollback()
              throws DKException,
                     java.lang.Exception
Description copied from interface: dkDatastore
Rollback a datastore transaction

Note:DKUsageError exception thrown if method is not implemented

Specified by:
rollback in interface dkDatastore
Overrides:
rollback in class dkAbstractDatastore

listSchema

public java.lang.Object listSchema()
                            throws DKException,
                                   java.lang.Exception
Description copied from interface: dkDatastore
List the entities that belong to this datastore

Note:DKUsageError exception thrown if method is not implemented

Specified by:
listSchema in interface dkDatastore
Overrides:
listSchema in class dkAbstractDatastore
Following copied from interface: com.ibm.mm.sdk.common.dkDatastore
Returns:
an object that contains the schema
See Also:
dkDatastore.listEntities()

listSchemaAttributes

public java.lang.Object listSchemaAttributes(java.lang.String schemaEntry)
                                      throws DKException,
                                             java.lang.Exception
Description copied from interface: dkDatastore
List the attributes that belong to a schema.

Note:DKUsageError exception thrown if method is not implemented

Specified by:
listSchemaAttributes in interface dkDatastore
Overrides:
listSchemaAttributes in class dkAbstractDatastore
Following copied from interface: com.ibm.mm.sdk.common.dkDatastore
Parameters:
schemaEntry - the name of the schema.
Returns:
an object that contains the attributes that belong to this schema
See Also:
dkDatastore.listEntityAttrs(java.lang.String)

destroy

public void destroy()
             throws DKException,
                    java.lang.Exception
datastore destroy - datastore cleanup if needed
Specified by:
destroy in interface dkDatastore
Overrides:
destroy in class dkAbstractDatastore

printSearchOpts

public void printSearchOpts()
Will print out the variables set for the private varibale _ics_search_opts. This can be used for debug pourposes.
Returns:
void

setFindAllWords

public void setFindAllWords(boolean bFindAll)

getFindAllWords

public boolean getFindAllWords()

setScheduled

public void setScheduled(boolean bScheduled)

getScheduled

public boolean getScheduled()

setSortAscending

public void setSortAscending(boolean bAscending)

getSortAscending

public boolean getSortAscending()

setResultsWhenAvail

public void setResultsWhenAvail(boolean bResultsWhenAvail)

getResultsWhenAvail

public boolean getResultsWhenAvail()

setSourceMaxHits

public void setSourceMaxHits(int iMaxHits)

getSourceMaxHits

public int getSourceMaxHits()

getTotalMaxHits

public int getTotalMaxHits()

setGetPage

public void setGetPage(int iGetPage)

getGetPage

public int getGetPage()

setPageSize

public void setPageSize(int iPageSize)

getPageSize

public int getPageSize()

setTimeOut

public void setTimeOut(int iTimeOut)

getTimeOut

public int getTimeOut()

setQueryId

public void setQueryId(java.lang.String sQueryId)

getQueryId

public java.lang.String getQueryId()

setSortField

public void setSortField(java.lang.String sSortField)

getSortField

public java.lang.String getSortField()

setUserId

public void setUserId(java.lang.String sUserId)

getUserId

public java.lang.String getUserId()

setMailResultsTo

public void setMailResultsTo(java.lang.String sMailTo)

getMailResultsTo

public java.lang.String getMailResultsTo()

setQuery

public void setQuery(java.lang.String sQuery)

getQuery

public java.lang.String getQuery()

setConstraints

public void setConstraints(java.lang.String name,
                           java.lang.String operator,
                           java.lang.String value)

setLocaleForDES

public void setLocaleForDES(java.lang.String locale)
Will set the locale for the icsBroker. if null is passed, the locale information will be extracted from the running system. "LanguageCountryCodepage" is the format for a valid locale information. "enuUSA1252" is a valid locale information.
Returns:
void

setLocale

public void setLocale(java.util.Locale locale)
Will set the locale for the icsBroker to pass the client locale to the ES server.
Parameters:
locale - - this is a Locale object of the Client.
Returns:
void

getLocale

public java.util.Locale getLocale()
Will return the local copy of client Locale.
Returns:
String

getConnStrFromDESRMICfgFile

public java.lang.String getConnStrFromDESRMICfgFile()
Will return the DES rmi port and rmi reference names for DES from information in desrmi.cfg file located in the application run directory. If desrmi.cfg does not exist, ":20000/EsDatabase" will be returned. If the DES RMI is not running in the default port or reference configuration, please create "desrmi.cfg" file in the current aplication directory with the following two key and value property entries # DES rmi port information dbrmi.port=20000 # DES rmi reference information dbrmi.ref=EsDatabase Also a DES administrator can find the above mentioned values in admin.properties located in WebServer root directory of DES.
Returns:
String

refreshDESRepositories

public void refreshDESRepositories()
                            throws java.lang.Exception
Will refresh the DES repositories by communicating to DES RMI Also refresh the repositories and rmiref handles.
Returns:
void

listEntityCategoryNames

public java.lang.String[] listEntityCategoryNames()
                                           throws DKException,
                                                  java.lang.Exception
listEntityCategoryNames will return a String array of Category names under the specified application.
Specified by:
listEntityCategoryNames in interface dkDatastoreIntDES
Returns:
String[]

listEntityNamesByCategory

public java.lang.String[] listEntityNamesByCategory(java.lang.String categoryName)
                                             throws DKException,
                                                    java.lang.Exception
listEntityNamesByCategory will return a String array of Source names names under the specified category in a specified application.
Specified by:
listEntityNamesByCategory in interface dkDatastoreIntDES
Parameters:
categoryName - - category name of interest
Returns:
String[]

listEntityNamesByCategoryAndType

public java.lang.String[] listEntityNamesByCategoryAndType(java.lang.String categoryName,
                                                           java.lang.String entitySourceType)
                                                    throws DKException,
                                                           java.lang.Exception
listEntityNamesByCategoryAndType will return a String array of Source names names under the specified category in a specified application of a particulare link type.
Specified by:
listEntityNamesByCategoryAndType in interface dkDatastoreIntDES
Parameters:
categoryName - - category name of interest
entitySourceType - - linkType name of interest
Returns:
String[]

getEntitySourceType

public java.lang.String getEntitySourceType(java.lang.String entityName)
                                     throws DKException,
                                            java.lang.Exception
getEntitySourceType will return the link type of specified source
Specified by:
getEntitySourceType in interface dkDatastoreIntDES
Parameters:
entityName - - source name of interest
Returns:
String

listFileSystemEntities

public java.lang.String[] listFileSystemEntities()
                                          throws DKException,
                                                 java.lang.Exception
listFileSystemEntities will list the file system sources configured.
Specified by:
listFileSystemEntities in interface dkDatastoreIntDES
Parameters:
void -  
Returns:
String[] string array with list of file system sources

getActions

public DKNVPair[] getActions(java.lang.String entityName)
getActions will return a DKNVpair with Action names (as key) and the URLS (as value) for the specified source in the specified application
Parameters:
sourceName - - source name of interest
Returns:
String[]

addStoredQueryAndSchedule

public void addStoredQueryAndSchedule(java.lang.String queryStr,
                                      DKNVPair[] options)
                               throws DKException,
                                      DKUsageError,
                                      java.lang.Exception
addStoredQueryAndSchedule will save or add a query in ES database. All the query fileds will be extracted form the HttpServletRequest argument.
Parameters:
HTTPServletRequest - object should be passed.
Returns:
void

listQueryFolderNames

public java.lang.String[] listQueryFolderNames()
listQueryFolderNames will list all the parent level folders in the ES database
Returns:
String[]

getQueryFolderProperties

public DKNVPair[] getQueryFolderProperties(java.lang.String folderName)
getQueryFolderProperties will get the properties of the specified query folder
Parameters:
String - folderName
Returns:
DKNVPair[]

setQueryFolderProperties

public void setQueryFolderProperties(DKNVPair[] prop)
setQueryFolderProperties will set the properties for query folder
Parameters:
DKNVPair[] - prop
Returns:
void

deleteQueryFolders

public void deleteQueryFolders(java.lang.String[] folderNames)
deleteQueryFolders will delete the specified query folder
Parameters:
String[] - folderNames
Returns:
void

listStoredQueryNames

public java.lang.String[] listStoredQueryNames(java.lang.String folderName)
listStoredQueryNames will list all the stored queries in a folder
Parameters:
String - folderName
Returns:
String[]

getStoredQueryProperties

public DKNVPair[] getStoredQueryProperties(java.lang.String folderName,
                                           java.lang.String queryName)
getStoredQueryProperties will get the properties for the specified stored query
Parameters:
String - folderName
String - queryName
Returns:
DKNVPair[]

setStoredQueryProperties

public void setStoredQueryProperties(DKNVPair[] prop)
setStoredQueryProperties will set the properties for the stored query passed in the DKNVPair
Parameters:
DKNVPair -  
Returns:
void

deleteStoredQueries

public void deleteStoredQueries(java.lang.String folderName,
                                java.lang.String[] queryNames)
deleteStoredQueries will delete the specified stored query in ES DB
Parameters:
String - folderName
String[] - queryNames
Returns:
void

getStoredQueryOptions

public DKNVPair[] getStoredQueryOptions(java.lang.String folderName,
                                        java.lang.String queryName)
getStoredQueryOptions will return the URL for the stored query t be displayed in the Browser
Parameters:
String - folderName
String - queryName

listStoredQueryResultIDs

public java.lang.String[] listStoredQueryResultIDs(java.lang.String folderName,
                                                   java.lang.String queryName)
listStoredQueryResultIDs will list all the resultIDs in the specifed stored query Names in a folder
Parameters:
string - folderName
string - queryName
Returns:
String array

deleteStoredQueryResultIDs

public void deleteStoredQueryResultIDs(java.lang.String folderName,
                                       java.lang.String queryName,
                                       java.lang.String[] resultIDs)
deleteStoredQueryResultIDs will delete specified resultIDs
Parameters:
string - folderName
string - queryName
string[] - resultIDs
Returns:
String array

storedQueryResults

public dkResultSetCursor storedQueryResults(java.lang.String folderName,
                                            java.lang.String queryName,
                                            java.lang.String resultID)
storedQueryResults will return result set for specified results ID.
Parameters:
string - folderName
string - queryName
string - resultID
Returns:
dkResultsetCursor

EIP Java APIs

(c) Copyright International Business Machines Corporation 1996, 2002. IBM Corp. All rights reserved.