asjava.uniobjects
Class UniSelectList

java.lang.Object
  extended byasjava.uniobjects.UniBase
      extended byasjava.uniobjects.UniSelectList

public class UniSelectList
extends UniBase

UniSelectList is used to control, access, and manipulate server side select lists.

Since:
UNIOBJECTS 1.0
Version:
Version 1.0
Author:
David T. Meeks

Field Summary
 
Fields inherited from class asjava.uniobjects.UniBase
inPacket, outPacket, uniConnection, uniEncryptionType, uniParentSession, uniStatus
 
Constructor Summary
UniSelectList()
           
UniSelectList(UniSession aSession, int aSelectListNumber)
          Returns the runtime class of the object
 
Method Summary
 void clearList()
          Clears the selected list, emptying the contents and preparing for a new select list to be generated.
 void formList(java.lang.Object aString)
          creates a new select list from the supplied list of record IDs
 void formList(UniDataSet aDataSet)
          creates a new select list from the supplied list of record IDs contained in the UniDataSet object
 void getList(java.lang.Object aListName)
          activates the named select list from the &SAVEDLISTS& file on the server
 boolean isLastRecordRead()
          boolean entry denoting whether or not the last record has been read.
 UniString next()
          returns the next record ID in the select list.
 UniDynArray readList()
          reads the entire contents of the select list and returns it all at once
 void saveList(java.lang.Object aListNameObj)
          Saves the current select list in &SAVEDLISTS& file on the server with the name supplied
 void select(UniDictionary uniFile)
          creates a new select list by selecting the UniDictionary object and generating a select list of all the record IDs from that file.
 void select(UniFile uniFile)
          creates a new select list by selecting the UniFile object and generating a select list of all the record IDs from that file.
 void selectAlternateKey(UniDictionary unid, java.lang.Object aIndexName)
          generate a select list from the given UniDictionary from values in the secondary key index that is specified.
 void selectAlternateKey(UniFile uniFile, java.lang.Object aIndexName)
          generate a select list from the given UniFile from values in the secondary key index that is specified.
 void selectMatchingAK(UniDictionary unid, java.lang.Object aIndexName, java.lang.Object aIndexValue)
          generate a select list from the given UniDictionary from values in the secondary key index that is specified whose value matches that in the named value.
 void selectMatchingAK(UniFile uniFile, java.lang.Object aIndexName, java.lang.Object aIndexValue)
          generate a select list from the given UniFile from values in the secondary key index that is specified whose value matches that in the named value.
 
Methods inherited from class asjava.uniobjects.UniBase
getEncryptionType, isCommandActive, setEncryptionType, status
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UniSelectList

public UniSelectList()
              throws UniSelectListException

UniSelectList

public UniSelectList(UniSession aSession,
                     int aSelectListNumber)
              throws UniSelectListException
Returns the runtime class of the object

Since:
UNIOBJECTS 1.0
Method Detail

clearList

public void clearList()
               throws UniSelectListException
Clears the selected list, emptying the contents and preparing for a new select list to be generated.

Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

formList

public void formList(java.lang.Object aString)
              throws UniSelectListException
creates a new select list from the supplied list of record IDs

Parameters:
aString - a delimited String or UniDynArray containing the records IDs to use
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

formList

public void formList(UniDataSet aDataSet)
              throws UniSelectListException
creates a new select list from the supplied list of record IDs contained in the UniDataSet object

Parameters:
aDataSet - an existing UniDataSet object
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

getList

public void getList(java.lang.Object aListName)
             throws UniSelectListException
activates the named select list from the &SAVEDLISTS& file on the server

Parameters:
aListName - String denoting the name of which select list to activate
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

isLastRecordRead

public boolean isLastRecordRead()
boolean entry denoting whether or not the last record has been read. true denotes that no more records are left in the select list.

Returns:
the boolean value representing whether the last record was read.
  • true means the select list has no more records
  • false means the select list still has records IDs
Since:
UNIOBJECTS 1.0

next

public UniString next()
               throws UniSelectListException
returns the next record ID in the select list. If exhausted, it will return a null value and the isLastRecordRead method will return true

Returns:
the next record ID from the select list, or a null if exhausted
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0
See Also:
isLastRecordRead()

readList

public UniDynArray readList()
                     throws UniSelectListException
reads the entire contents of the select list and returns it all at once

Returns:
UniDynArray representing the entire select list
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

saveList

public void saveList(java.lang.Object aListNameObj)
              throws UniSelectListException
Saves the current select list in &SAVEDLISTS& file on the server with the name supplied

Parameters:
aListNameObj - String denoting the name the select list should be saved to
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

select

public void select(UniFile uniFile)
            throws UniSelectListException
creates a new select list by selecting the UniFile object and generating a select list of all the record IDs from that file. It will overwrite any previous select list and the select list pointer will be reset to the first record in the list.

Parameters:
uniFile - UniFile object to be selected
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

select

public void select(UniDictionary uniFile)
            throws UniSelectListException
creates a new select list by selecting the UniDictionary object and generating a select list of all the record IDs from that file. It will overwrite any previous select list and the select list pointer will be reset to the first record in the list.

Parameters:
uniFile - UniDictionary object to be selected
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

selectAlternateKey

public void selectAlternateKey(UniFile uniFile,
                               java.lang.Object aIndexName)
                        throws UniSelectListException
generate a select list from the given UniFile from values in the secondary key index that is specified.

Parameters:
uniFile - UniFile to be selected
aIndexName - index name to select on
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

selectAlternateKey

public void selectAlternateKey(UniDictionary unid,
                               java.lang.Object aIndexName)
                        throws UniSelectListException
generate a select list from the given UniDictionary from values in the secondary key index that is specified.

Parameters:
unid - UniDictionary to be selected
aIndexName - index name to select on
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

selectMatchingAK

public void selectMatchingAK(UniFile uniFile,
                             java.lang.Object aIndexName,
                             java.lang.Object aIndexValue)
                      throws UniSelectListException
generate a select list from the given UniFile from values in the secondary key index that is specified whose value matches that in the named value.

Parameters:
uniFile - UniFile to be selected
aIndexName - index name to select on
aIndexValue - value within the index to select to
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0

selectMatchingAK

public void selectMatchingAK(UniDictionary unid,
                             java.lang.Object aIndexName,
                             java.lang.Object aIndexValue)
                      throws UniSelectListException
generate a select list from the given UniDictionary from values in the secondary key index that is specified whose value matches that in the named value.

Parameters:
unid - UniDictionary to be selected
aIndexName - index name to select on
aIndexValue - value from the secondary key index. Records are selected when the indexed field matches this value.
Throws:
UniSelectListException - is thrown if an error condition occurs
Since:
UNIOBJECTS 1.0