Freemed-YiRC - Lists (Reference and Linked)
In Freemed-YiRC, a list is simply a group of items.
For example, we may have a list of fruits. The items on this list may be:
In Freemed-YiRC lists are typically stored within a database table. Hence the terms list and table may be used interchangeably within this context. Additionally, since items are stored in a database table field, the terms item and field may also be used interchangeably.
There are many, many lists in Freemed-YiRC. However, there are only two major types of lists in Freemed-YiRC: Reference Lists and Linked Lists.
A reference list contains a simple list of items whose values are referenced by the item value itself.
For example, given the list of fruits above (Apple, Orange, Banana), if the item Apple is chosen, the value Apple itself is stored. This type of table should only be used in situations where the items on the list will not change values. Editing of existing items on this list should be kept to an absolute minimum. The benefit to a reference list is that database tables storing these values are easier to report on, as there is no need to do a database lookup to retrieve an item's actual value. A negative about this method is that if one were to change the value of Apple on this simple list to Apples, this could create a situation where other database tables referencing this data will no longer offer Apple as a new item option, only Apples. In addition, any attempts to report on all records using the new value of Apples will not return older records which previously stored the value Apple. To a computer the values Apple and Apples are two completely different things, no more similar than Apple and Orange.
A linked list contains a list of items whose values are referenced not by the items value itself, but it's database record ID instead. For example, given the same list of fruit (Apple, record 1; Orange, record 2; Banana, record 3), if Apple is chosen, the value "1" (Apple's record number) would be stored in a database table. This means that any time this data needs to be reported on, a lookup would need to be performed to this list to reveal the value for record 1 (i.e., Apple). However, if the value of Apple were changed to Apples, all existing records referencing this would not need to be edited/modified as a lookup to the list is needed regardless any time the record needs to be reported on. Since the value 1 is stored in the database, after Apple was changed to Apples, then future reports would return Apples for any value of 1 for that list. The negative here, again, is that any records making use of values in a linked list require lookups to determine the actual value of a given item.
List Creation and Maintenance
Until the creation of the Freemed-YiRC List Editor, lists were created and edited/maintained in many various ways, purely dependent upon the specific module. This created quite a bit of redundant programming in Freemed-YiRC to deal with essentially the same thing. Hence, the Freemed-YiRC List Editor was created to provide both the developer and end-user with a common and consistent method to deal with lists.