com.ibm.jzos
Class CatalogSearch.Entry
- java.lang.Object
-
- com.ibm.jzos.CatalogSearch.Entry
-
- Enclosing class:
- CatalogSearch
public static class CatalogSearch.Entry extends java.lang.ObjectA static nested class of CatalogSearch which holds a catalog search entry. Entry types are either Catalog or Dataset. Catalog entries only contain a Catalog name, while Dataset entries contain the dataset name and the requested field data.- See Also:
isCatalogEntry(),isDatasetEntry()
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.lang.StringgetCatalogName()Return the name of the current Catalog (the entry name of the last Catalog entry read).intgetEntryLength()Return the total length, in bytes, that this entry comprises in the work area.CatalogSearchFieldgetField(java.lang.String fieldName)Return the field data associated with a fieldName.bytegetFlag()Return the entry flag byte.java.lang.StringgetModuleId()Return the entry reason area module id.java.lang.StringgetName()Return a String containing the 1-44 character name (blanks trimmed)intgetRc()Return the entry reason area return code.intgetReason()Return the entry reason area reason code.chargetType()Return the entry type.booleanhasError()Return true if the entry has an error.booleanhasReasonArea()Return true if the entry has a valid reason area.booleanisCatalogEntry()Return true if this entry is a Catalog entry.booleanisDatasetEntry()Return true if this entry is a Dataset entry.
-
-
-
Method Detail
-
isCatalogEntry
public boolean isCatalogEntry()
Return true if this entry is a Catalog entry.
-
isDatasetEntry
public boolean isDatasetEntry()
Return true if this entry is a Dataset entry.
-
hasError
public boolean hasError()
Return true if the entry has an error. If so, the methodsgetRc()andgetReason()can be used to determine what the error is.
-
getRc
public int getRc()
Return the entry reason area return code. Will be zero ifhasError()is false.
-
getReason
public int getReason()
Return the entry reason area reason code. Will be zero ifhasError()is false.
-
getModuleId
public java.lang.String getModuleId()
Return the entry reason area module id. Will be a zero length string ifhasError()is false.
-
hasReasonArea
public boolean hasReasonArea()
Return true if the entry has a valid reason area. All catalog entries have a reason area; dataset entries have a reason area if in error (FLAG_CSIENTER != 0).- Returns:
- true if the entry has a valid reason area.
-
getEntryLength
public int getEntryLength()
Return the total length, in bytes, that this entry comprises in the work area.Each entry has the following common information:
- CSIFLAG[1]
- CSITYPE[1]
- CSIxNAME[44]
- CSIxRETM[2]
- CSIxRETR[1]
- CSIxRETC[1]
- Returns:
- the length of the entry
-
getCatalogName
public java.lang.String getCatalogName()
Return the name of the current Catalog (the entry name of the last Catalog entry read).
-
getFlag
public byte getFlag()
Return the entry flag byte.See See FLAG_* constants for possible values and consult the Catalog Search Interface documentation for details.
- Since:
- 2.3.2
-
getType
public char getType()
Return the entry type.For catalogs, this value will be
CatalogSearch.CATALOG_TYPE.For dataset entries, this value will be one of the entry types as described in
CatalogSearch.setEntryTypes(String).- Since:
- 2.3.2
-
getName
public java.lang.String getName()
Return a String containing the 1-44 character name (blanks trimmed)
-
getField
public CatalogSearchField getField(java.lang.String fieldName)
Return the field data associated with a fieldName.- Parameters:
fieldName- one of the names added viaCatalogSearch.addFieldName(String).- Returns:
- the field data
- Throws:
java.lang.UnsupportedOperationException- if this method is called on a Catalog Entryjava.util.NoSuchElementException- if the entry has no such field- See Also:
isCatalogEntry()
-
-