Class ValidationListEntry
- java.lang.Object
-
- com.ibm.as400.access.ValidationListEntry
-
public class ValidationListEntry extends java.lang.Object
Represents an entry in a system validation list.- Author:
- Thomas Johnson (tom.johnson@kingland.com), Kingland Systems Corporation
-
-
Constructor Summary
Constructors Constructor and Description ValidationListEntry()
Constructs a ValidationListEntry.ValidationListEntry(byte[] buffer, int offset)
Constructs a ValidationListEntry from a structure stored as IBM i bytes.
-
Method Summary
Methods Modifier and Type Method and Description ValidationListAttributeInfo
getAttributeInfo()
Returns the object containing all attribute information associated with the entry.int
getByteLength()
Returns the total length of the corresponding structure when this object is written to IBM i bytes for use by the validation list APIs.ValidationListDataToEncrypt
getDataToEncrypt()
Returns the information to encrypt when the entry is subsequently inserted or updated.ValidationListTranslatedData
getEncryptedData()
Returns the information currently encrypted for the entry in the validation list.ValidationListTranslatedData
getEntryID()
Returns the translated data containing the entry identifier.ValidationListTranslatedData
getUnencryptedData()
Returns the unencrypted data for the entry.void
init(byte[] buffer, int offset)
Initialize a ValidationListEntry from a structure stored as IBM i bytes.void
setAttributeInfo(ValidationListAttributeInfo info)
Sets the object containing all attribute information associated with the entry.void
setDataToEncrypt(ValidationListDataToEncrypt dataToEncrypt)
Sets the information to encrypt when the entry is subsequently inserted or updated.void
setEncryptedData(ValidationListTranslatedData encryptedData)
Sets the information currently encrypted for the entry in the validation list.void
setEntryID(ValidationListTranslatedData entryID)
Sets the translated data containing the entry identifier.void
setUnencryptedData(ValidationListTranslatedData data)
Sets the unencrypted data for the entry.
-
-
-
Constructor Detail
-
ValidationListEntry
public ValidationListEntry()
Constructs a ValidationListEntry.
-
ValidationListEntry
public ValidationListEntry(byte[] buffer, int offset)
Constructs a ValidationListEntry from a structure stored as IBM i bytes.The offset indicates the starting position of the structure in the given buffer.
- Parameters:
buffer
- byte[]offset
- int
-
-
Method Detail
-
getAttributeInfo
public ValidationListAttributeInfo getAttributeInfo()
Returns the object containing all attribute information associated with the entry.Attributes and associated values can be assigned by the application prior to adding an entry. When finding an entry, the identifiers for attributes to retrieve are set by the application prior to the find. The corresponding attribute values are filled in as a result of the find operation.
- Returns:
- ValidationListAttributeInfo
-
getByteLength
public int getByteLength()
Returns the total length of the corresponding structure when this object is written to IBM i bytes for use by the validation list APIs.Note: The length 1724 is dictated by the API definition (i.e. QSYFDVLE).
- Returns:
- int
-
getDataToEncrypt
public ValidationListDataToEncrypt getDataToEncrypt()
Returns the information to encrypt when the entry is subsequently inserted or updated.This differs from the EncryptedData property in that the latter, if present, reflects the data currently encrypted for the entry.
If the QsyEncryptData attribute is set to 0, the data to be encrypted can only be used to verify an entry and cannot be retrieved later. This is the default.
If the attribute was set to 1, the data to be encrypted can be used to verify an entry and can potentially be returned on a find operation. The system value QRETSVRSEC (Retain system security data) has the final say in determining if the data can be retrieved from the entry. If the system value is set to 0 (Do not retain data), the entry will be added, but the data to be encrypted will not be stored with the entry and cannot be retrieved. If the system value is set to 1 (Retain data), then the data to be encrypted will be stored (in encrypted form) with the entry and can be retrieved.
- Returns:
- ValidationListDataToEncrypt
-
getEncryptedData
public ValidationListTranslatedData getEncryptedData()
Returns the information currently encrypted for the entry in the validation list.Note: The encrypted data may or may not be retrievable based on the value set for the QsyEncryptData attribute when the entry was inserted.
- Returns:
- ValidationListTranslatedData
- See Also:
getDataToEncrypt()
-
getEntryID
public ValidationListTranslatedData getEntryID()
Returns the translated data containing the entry identifier.- Returns:
- ValidationListTranslatedData
-
getUnencryptedData
public ValidationListTranslatedData getUnencryptedData()
Returns the unencrypted data for the entry.- Returns:
- ValidationListTranslatedData
-
init
public void init(byte[] buffer, int offset)
Initialize a ValidationListEntry from a structure stored as IBM i bytes.The offset indicates the starting position of the structure in the given buffer.
- Parameters:
buffer
- byte[]offset
- int
-
setAttributeInfo
public void setAttributeInfo(ValidationListAttributeInfo info)
Sets the object containing all attribute information associated with the entry.Attributes and associated values can be assigned by the application prior to adding an entry. When finding an entry, the identifiers for attributes to retrieve are set by the application prior to the find. The corresponding attribute values are filled in as a result of the find operation.
- Parameters:
info
- ValidationListAttributeInfo
-
setDataToEncrypt
public void setDataToEncrypt(ValidationListDataToEncrypt dataToEncrypt)
Sets the information to encrypt when the entry is subsequently inserted or updated.This differs from the EncryptedData property in that the latter, if present, reflects the data currently encrypted for the entry.
If the QsyEncryptData attribute is set to 0, the data to be encrypted can only be used to verify an entry and cannot be retrieved later. This is the default.
If the attribute was set to 1, the data to be encrypted can be used to verify an entry and can potentially be returned on a find operation. The system value QRETSVRSEC (Retain system security data) has the final say in determining if the data can be retrieved from the entry. If the system value is set to 0 (Do not retain data), the entry will be added, but the data to be encrypted will not be stored with the entry and cannot be retrieved. If the system value is set to 1 (Retain data), then the data to be encrypted will be stored (in encrypted form) with the entry and can be retrieved.
- Parameters:
dataToEncrypt
- ValidationListDataToEncrypt
-
setEncryptedData
public void setEncryptedData(ValidationListTranslatedData encryptedData)
Sets the information currently encrypted for the entry in the validation list.Note: The encrypted data may or may not be retrievable based on the value set for the QsyEncryptData attribute when the entry was inserted.
- Parameters:
encryptedData
- ValidationListTranslatedData
-
setEntryID
public void setEntryID(ValidationListTranslatedData entryID)
Sets the translated data containing the entry identifier.- Parameters:
entryID
- ValidationListTranslatedData
-
setUnencryptedData
public void setUnencryptedData(ValidationListTranslatedData data)
Sets the unencrypted data for the entry.- Parameters:
data
- ValidationListTranslatedData
-
-