Queue (clsQueue), Node (clsNode), and QueueFields (clsQueueFields) implement a doubly linked queue model. media:clsQueueDemo.zip contains demonstration databases in A2010 and A2003 format. There is also documentation in OneNote format located at Queue Management Documentation
Simply described, a queue is an ordered list. Each item it the list is referred to as a node. In a linked list, each node has a field that points to its successor (the next item in the list.) In a doubly linked list, each node contains a reference to the node's predecessor as well as a link to its successor. This implemenation is also a circular queue so that the next node after the last node is the first node, and the last node is the predecessor to the first.
This implemenation also maintains an ordinal field so that the queue can be used to impose an order that cannot otherwise be achieved. For example data that includes the first and last names and birthdates of people can easily be sorted by any of those values (alphabetically or chronologically.) However, if you need to see the list in a user determined sequence that is neither chronolgical, nor alphabetical, it can't be done using just the data.
The demostration database includes a form that allows the user to create a subset list from a main data list and then to manipulate the subset sequence by moving items up or down the list. The demonstration form also has a section that shows changes to the queue as the user adds, deletes, or moves items in the subset list.
The classes maintain the queue in a table that contains only nodes. This table has a one to one relationship with the main data table. clsQueue manages the queue table. clsNode manages individual nodes in the queue and clsQueueFields is used as a property of clsQueue and clsNode for managing the field names used in the queue table.
|This page has been accessed 839 times. This page was last modified 12:18, 29 June 2011 by Glenn Lloyd. Disclaimers|