![]() ![]() ![]() ![]() | Table Of Contents | Index |
Qualifiers are named indexes into arrays. They are used to make the source menu file more readable and more organized.
Suppose we are creating a data structure to deal with places in the United States. First we will need an array for States.
Var StatesNow states have counties and counties have county seats, sheriffs, and cities.We want to store some facts about the states.
Qualifier Population Bird Motto County
State[3].Population = 10000000 State[3].Bird = 'Chicken' State[3].Motto = 'Best politicians money can buy!'
Qualifer Sheriff Seat CityNow counties have cities and cities have schools, mayors, churches, and taxes.State[3].County[7].Sheriff = 'Buck InBred' State[3].County[7].Seat = 'Possum Trot'
Qualifier Schools Mayor Churches TaxesThe above line is the same as:State[3].County[7].City[9].Schools = 8 State[3].County[7].City[9].Mayor = 'Virgil Collins' State[3].County[7].City[9].Churches = 120 State[3].County[7].City[9].Taxes = '$100,000,000'
State[3,4,7,3,9,4] = '$100,000,000'As you can see with qualifiers, it is easy to create multidimensional arrays in a way that is organized and readable.
In this example, the qualifier Population became equal to 1. Bird became equal to 2. The variable references, State[3].Bird and State[3,2] are the same. It's just that one is more readable than the other. Qualifiers normally begin by assigning 1 to the first name and 2 to the second, etc. This can be modified.
Qualifier Color = 7 Size ShapeIn this case Color becomes the number 7; Size becomes the number 8; and Shape becomes the number 9.
![]() ![]() ![]() ![]() | Table Of Contents | Index |
|