Filters

From ARK
Revision as of 07:23, 11 July 2008 by 91.124.132.72 (talk)

Jump to: navigation, search

Filters in ARK are based on Set theory. That is essentially considering how a whole set of different objects (in ARK lingo, results_arrays) are related to each other. For more information on Set Theory - with extremely useful diagrams - see Wikipedia.

The basic operation of a filter in ARK is to query the database (using whatever SQL is appropriate for that filter type) and then produce a result_array. This result_array can then be displayed to the user.

Intersection

Following the creation of this first result_array - the user may want to refine the results further. Currently this is undertaken by running another filter, producing another separate results array and then displaying the Intersection of these two arrays.

A simple worked through example of this is:

Question: "I want to see all the of the contexts that have been verified by Stuart Eve".

Back-end Methodology:

1.Run a 'Filter By Item' to return all of the Contexts. This produces the initial results_array (ra_1). 2.Run a 'Filter By Action' to return all of the Items that have been verified by Stuart Eve (ra_2). (note this filter on its own returns all of the items not just contexts). 3.Run an Intersect on ra_1 and ra_2 to produce a new results_array (ra_3) that only contains Contexts that have been Verified by Stuart Eve. (in Set Theory speak this is : ra_3 = ra_1 ∩ ra_2 ).

Complement