com.ibm.mm.sdk.common

Class DKTextIndexDefICM

  1. java.lang.Object
  2. extended bycom.ibm.mm.sdk.common.DKTextIndexDefICM
All implemented interfaces:
java.io.Serializable

  1. public class DKTextIndexDefICM
  2. extends java.lang.Object
  3. implements java.io.Serializable
DB2 Content Manager version 8 allows an administrator to make attributes text-searchable. In addition, the text content in the Resource Manager may also be made text searchable. For such searches to work in an optimal manner, a text search index must be define. The DKTextIndexICM class holds all the properties of a text search index in DB2 Content Manager. It contains set/get methods to set and query this information. It has no interaction with the server itself. An instance of this class may be specified when defining an attribute for a component. If this class is specified, it makes the attribute text searchable. Conversely, setting the value of the instance of this class associated with the attribute to null makes the attribute non text-searchable. An instance of this class may also be used to specify the text index properties for a Text Resource Item Type.
See Also:
Serialized Form

Field Summary

Modifier and Type Field and Description
  1. static
  2. java.lang.String
TEXT_INDEX_DOC_FORMAT_GPP
Constant to specify gpp format for indexed documents.
  1. static
  2. java.lang.String
TEXT_INDEX_DOC_FORMAT_HTML
Constant to specify html format for indexed documents.
  1. static
  2. java.lang.String
TEXT_INDEX_DOC_FORMAT_TEXT
Constant to specify text format for indexed documents.
  1. static
  2. java.lang.String
TEXT_INDEX_DOC_FORMAT_XML
Constant to specify xml format for indexed documents.

Constructor Summary

Constructor and Description
DKTextIndexDefICM()
Default constructor.
DKTextIndexDefICM(DKTextIndexDefICM attr)
Copy constructor for the text index definition class.

Method Summary

Modifier and Type Method and Description
  1. int
getCommitCount()
Retrieves the commit count for this text index.
  1. java.lang.String
getFormat()
Retrieves the format of text documents in the index.
  1. int
getIndexCCSID()
Gets CCSID used for building a text index.
  1. java.lang.String
getIndexDir()
Retrieves the name/value for the directory on the server where the text index is to be stored.
  1. java.lang.String
getIndexLangCode()
Retrieves the language code for theis text index.
  1. int
getMinChanges()
Retrieves the minimum number of changes to the text column that may occur before this text index is updated automatically.
  1. int
getModelCCSID()
Retrieves the model CCSID of the model file associated with this text index.
  1. java.lang.String
getModelFile()
Retrieves the model file for the model associated with this text index.
  1. java.lang.String
getModelName()
Retrieves the model name for this text index.
  1. java.lang.String
getUDFName()
Gets the name of a user defined Function (UDF) that will be used to fetch or filter the content that are indexed.
  1. java.lang.String
getUDFSchema()
Retrieves the schema of the user defined function(UDF) associated with tis text index.
  1. java.lang.String
getUpdateFrequency()
Retrieves the update frequency for this text index.
  1. java.lang.String
getWorkingDir()
Retrieves the working directory for this text index.
  1. void
setCommitCount(int commitCount)
Sets the commit count for this text index.
  1. void
setFormat(java.lang.String format)
Sets the format of the text documents associated with this text index.
  1. void
setIndexCCSID(int indexCCSID)
Sets the CCSID used for building this text index.
  1. void
setIndexDir(java.lang.String indexDir)
Sets the value for the directory on the server where the text index is to be stored.
  1. void
setIndexLangCode(java.lang.String indexLangCode)
Sets the language code for the text index.
  1. void
setMinChanges(int minChanges)
Sets the minimum number of changes to the text column that may occur before the text index is updated automaticially.
  1. void
setModelCCSID(int modelCCSID)
Sets the model CCSID of the model file associated with this text index.
  1. void
setModelFile(java.lang.String modelFile)
Sets the value for the model file associated with this text index.
  1. void
setModelName(java.lang.String modelName)
Sets the name of the model associated with this text index.
  1. void
setUDFName(java.lang.String udfName)
Sets the name of a user defined Function (UDF) that will be used to fetch or filter the content that is indexed.
  1. void
setUDFSchema(java.lang.String udfSchema)
Sets the schema of the user defined Function(UDF).
  1. void
setUpdateFrequency(java.lang.String updateFreq)
Sets the value for the update frequency for this text index.
  1. void
setWorkingDir(java.lang.String workingDir)
Sets the value of the working directory for this text index.
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail

TEXT_INDEX_DOC_FORMAT_TEXT

  1. public static java.lang.String TEXT_INDEX_DOC_FORMAT_TEXT
Constant to specify text format for indexed documents.

TEXT_INDEX_DOC_FORMAT_HTML

  1. public static java.lang.String TEXT_INDEX_DOC_FORMAT_HTML
Constant to specify html format for indexed documents.

TEXT_INDEX_DOC_FORMAT_XML

  1. public static java.lang.String TEXT_INDEX_DOC_FORMAT_XML
Constant to specify xml format for indexed documents.

TEXT_INDEX_DOC_FORMAT_GPP

  1. public static java.lang.String TEXT_INDEX_DOC_FORMAT_GPP
Constant to specify gpp format for indexed documents.

Constructor Detail

DKTextIndexDefICM

  1. public DKTextIndexDefICM()
Default constructor. Constructs a text index definitions with all default values set.

DKTextIndexDefICM

  1. public DKTextIndexDefICM(DKTextIndexDefICM attr)
Copy constructor for the text index definition class.
Parameters:
attr - - DKTextIndexDefICM object to use as a template for creating the new object.

Method Detail

getIndexCCSID

  1. public int getIndexCCSID()
Gets CCSID used for building a text index. The default for this is the CCSID of the database that the text index is created in.
Returns:
the CCSID used for building the text index.

setIndexCCSID

  1. public void setIndexCCSID(int indexCCSID)
Sets the CCSID used for building this text index. The default for this is the CCSID of the database that the text index was created in.
Parameters:
indexCCSID - - the CCSID that will be used for building this text index.

getIndexLangCode

  1. public java.lang.String getIndexLangCode( )
Retrieves the language code for theis text index. This language code is not in the same format as the language code that DB2 Content Manager uses. The index language code is in the form "EN_US" (US English) whereas the same language code in DB2 Content Manager would be "ENU. "
Returns:
the language code for the text index.

setIndexLangCode

  1. public void setIndexLangCode(java.lang.String indexLangCode)
Sets the language code for the text index. This language code is not in the same format as the language code that DB2 Content Manager uses. The index language code is in the form "EN_US" (representing US English) whereas the corresponding representation for US English in DB2 Content Manager would be "ENU".

getMinChanges

  1. public int getMinChanges()
Retrieves the minimum number of changes to the text column that may occur before this text index is updated automatically. The default is to never update the text index. This implies that the index must be updated manually.
Returns:
the minimum number of changes before this text index is updated automatically.

setMinChanges

  1. public void setMinChanges(int minChanges)
Sets the minimum number of changes to the text column that may occur before the text index is updated automaticially. The default is to never update this index. This implies that the index must be updated manually.
Parameters:
minChanges - - the value to set for the minimum number of changes to occur to the text column before an automatic update of this text index

getUpdateFrequency

  1. public java.lang.String getUpdateFrequency( )
Retrieves the update frequency for this text index. This value indicate when the automatic update is to be made. For details on the update frequency syntax, see the TIE documentation. The default is to never update this text index. This implies that the index must be updated manually.
Returns:
the update frequency for this text index.

setUpdateFrequency

  1. public void setUpdateFrequency( java.lang.String updateFreq)
Sets the value for the update frequency for this text index. This value indicates when the automatic update is to be made. For details on the update frequency syntax, see the TIE documentation. The default is to never update this text index. This implies that this index must be updated manually.
Parameters:
updateFreq - - value to set the update frequency for this text index to.

getCommitCount

  1. public int getCommitCount()
Retrieves the commit count for this text index. This value is the number of updated rows that will be processed before a commit is executed during the process of index updating. This value is useful when processing large numbers of documents.
Returns:
commit count for this text index.

setCommitCount

  1. public void setCommitCount(int commitCount)
Sets the commit count for this text index. This value is the number of updated rows that will be processed before a commit is executed during the process of index updating. This value is useful when processing large numbers of documents.
Parameters:
commitCount - - new value for the number of rows to process before a commit is executed

getFormat

  1. public java.lang.String getFormat( )
Retrieves the format of text documents in the index. The default format is "TEXT".Other possible values are "HTML", "XML" and "GPP"
Returns:
format of the text documents associated with this text index.

setFormat

  1. public void setFormat(java.lang.String format)
Sets the format of the text documents associated with this text index. Possible values are: "TEXT", "HTML", "XML", and "GPP".
Parameters:
format - - new value for the format of text documents associated with this text index.

getIndexDir

  1. public java.lang.String getIndexDir( )
Retrieves the name/value for the directory on the server where the text index is to be stored.
Returns:
the name of directory on the server where the index data is stored.

setIndexDir

  1. public void setIndexDir(java.lang.String indexDir)
Sets the value for the directory on the server where the text index is to be stored. This value must be a directory on the server.

getWorkingDir

  1. public java.lang.String getWorkingDir( )
Retrieves the working directory for this text index. This is a directory on the server used to store temporary files created during indexing.
Returns:
the value for the working directory used to store temporary files needed during indexing.

setWorkingDir

  1. public void setWorkingDir(java.lang.String workingDir)
Sets the value of the working directory for this text index. This is a directory on the server used to store temporary files created during indexing.
Parameters:
workingDir - - value for the working directory where temporary files created during the indexing process of this text index will be stored.

getModelName

  1. public java.lang.String getModelName( )
Retrieves the model name for this text index. A model is used to define the characteristics of the text that will be indexed. For details on Models pleas refer to the TIE documentation. The default behavior is to not have a model.
Returns:
model name or empty string (if no model is associated with this text index).

setModelName

  1. public void setModelName(java.lang.String modelName)
Sets the name of the model associated with this text index. A model may be used to define the characteristics of the text that will be indexed by this text index. For details on Models see the TIE documentation. The default behavior is to not have a model.
Parameters:
modelName - - name of the model to be associated with this text index

getModelFile

  1. public java.lang.String getModelFile( )
Retrieves the model file for the model associated with this text index. A model may be used to define the characteristics of the text that will be indexed. For details on Models see the TIE documentation. The default behavioris to not have a model associated with this text index.
Returns:
model file for the model associated with this text index or empty string (if there is no model for this text index).

setModelFile

  1. public void setModelFile(java.lang.String modelFile)
Sets the value for the model file associated with this text index. A model may be used to define the characteristics of the text that will be indexed. For details on Models see the TIE documentation. The default behavior is to not have a model.
Parameters:
modelFile - - value for the model file for the model associated with this text index

getModelCCSID

  1. public int getModelCCSID()
Retrieves the model CCSID of the model file associated with this text index. The default value for this is the CCSID of the database.
Returns:
the CCSID used for building the text index.

setModelCCSID

  1. public void setModelCCSID(int modelCCSID)
Sets the model CCSID of the model file associated with this text index. The default value for this is the CCSID of the database.
Parameters:
modelCCSID - - value for the CCSID used for the model file.

getUDFName

  1. public java.lang.String getUDFName( )
Gets the name of a user defined Function (UDF) that will be used to fetch or filter the content that are indexed. If a UDF is specified, the UDF will be called with the value in the column being indexed during indexing. The UDF must return the textual content that is to be indexed. This UDF may be used for filtering or for fetching content from another location such as a URL. For text resource items, a system defined UDF is used to fetch content from the resource manager. If you specify your own UDF for a text resource item type, your UDF is responsible for fetching the content associated with that item type. The default behavior is to have no UDF defined, except when used for text resource item types.
Returns:
the name of the UDF (if, any) or an empty string.

setUDFName

  1. public void setUDFName(java.lang.String udfName)
Sets the name of a user defined Function (UDF) that will be used to fetch or filter the content that is indexed. If a UDF is specified, the UDF will be called with the value in the column being indexed during indexing. The UDF must return the textual content that is to be indexed. This UDF may be used for filtering or for fetching content from another location such as a URL. For text resource items a system defined UDF is used to fetch content from the resource manager. If you specify your own UDF for a text resource item type, your UDF is responsible for fetching the content associated with this item type. The default behavior is to have no UDF, except when used infor text resource item types.
Parameters:
udfName - - value for the UDF name that will be used to generate indexable content associated with this text index.

getUDFSchema

  1. public java.lang.String getUDFSchema( )
Retrieves the schema of the user defined function(UDF) associated with tis text index. The default is no UDF and thus no UDF schema.
Returns:
udfSchema - value for the UDF schema or empty string (if no defined UDF schema).

setUDFSchema

  1. public void setUDFSchema(java.lang.String udfSchema)
Sets the schema of the user defined Function(UDF). By default, there is no UDF and thus no UDF schema for text indexes.
Parameters:
udfSchema - - value for the UDF Schema associated with this text index.