com.ibm.ims.base
Class DLISecondaryIndexInfo
java.lang.Object
|
+--com.ibm.ims.base.DLITypeInfo
|
+--com.ibm.ims.base.DLISecondaryIndexInfo
- All Implemented Interfaces:
- java.io.Serializable
Deprecated. This class does not support for secondary indexes with source and target segments
being different. The preferred way to do is via the com.ibm.ims.db.SecondaryIndexInfo
class, whose constructor SecondaryIndexInfo(String, String, String[], String)
{/code> caters to the case where the source & target are different segments.
- public class DLISecondaryIndexInfo
- extends DLITypeInfo
A DLISecondaryIndexInfo object is a specialization of a DLITypeInfo object that defines a field,
or a set of fields, that make up a secondary index. You construct a DLISecondaryIndexInfo object by
providing the field name alias, an array of ordered strings that indicate the field names (by field
name alias) the secondary index references (via the SRCH parameter), and the actual name of the
secondary index as defined in the DBD.
The following example demonstrates how to define a segment containing a secondary index.
public class TelephoneDirectory extends DLISegment {
static String[] keys = {"EmployeeNumber", "FirstName"};
static DLITypeInfo[] typeInfo = {
new DLITypeInfo("EmployeeNumber", DLITypeInfo.CHAR, 1, 6, "EMPNO"),
new DLITypeInfo("LastName", DLITypeInfo.CHAR, 7, 10),
new DLITypeInfo("FirstName", DLITypeInfo.CHAR, 17, 10, "FNAME"),
new DLITypeInfo("Extension", DLITypeInfo.CHAR, 27, 10),
new DLISecondaryIndexInfo("EmployeeInfo", keys, "EMPINFO"),
};
public TelephoneDirectory() {
super("Directory", "TELEDIR", typeInfo, 36);
}
}
- See Also:
- Serialized Form
Fields inherited from class com.ibm.ims.base.DLITypeInfo |
BIGINT, BINARY, BIT, BLOB, CHAR, CLOB, DATE, DOUBLE, FLOAT, INTEGER, NON_UNIQUE_KEY, NOT_KEY, PACKEDDECIMAL, SECONDARY_INDEX, SMALLINT, TIME, TIMESTAMP, TINYINT, TYPELIST, UNIQUE_KEY, VARCHAR, ZONEDDECIMAL |
Constructor Summary |
DLISecondaryIndexInfo(java.lang.String fieldName,
java.lang.String[] indexInfo,
java.lang.String searchFieldName)
Deprecated. This constructor does not support secondary indexes with source
and target segments being different. The preferred way to do is via the
com.ibm.ims.db.SecondaryIndexInfo(String fieldName, String sourceSegmentName,
String[] indexInfo, String searchFieldName, int keyLength) method, which
takes the field name, source segment name, array of sequenced field names, search
field name and the length of the sequenced fields put together as parameters. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DLISecondaryIndexInfo
public DLISecondaryIndexInfo(java.lang.String fieldName,
java.lang.String[] indexInfo,
java.lang.String searchFieldName)
- Deprecated. This constructor does not support secondary indexes with source
and target segments being different. The preferred way to do is via the
com.ibm.ims.db.SecondaryIndexInfo(String fieldName, String sourceSegmentName,
String[] indexInfo, String searchFieldName, int keyLength)
method, which
takes the field name, source segment name, array of sequenced field names, search
field name and the length of the sequenced fields put together as parameters.
- Constructs a DLISecondaryIndexInfo object.
- Parameters:
fieldName
- The name of the field. This name can be an alias that maps to the
the actual name as defined in the DBD source file, which is given
by the searchFieldName
parameter.indexInfo
- The ordered list of segment name aliases that the secondary index
references (provided via the SRCH parameter). Note the fields
specified via the SRCH parameter are the actual names of the segments
and not the segment alias names so be sure to code the alias names.searchFieldName
- the actual name of the secondary index as defined in the DBD (via the
XDFLD NAME= parameter)
(C) International Business Machines Corporation 2004. All rights reserved.