/*
 * STRUCT: SE_SEARCH_RULES
 *
 *   Structures used to create search filters.  Search filters can be based on
 *   the type of an object, the field values of an object, the passing of one
 *   or more user-defined predicate functions, the type of an object's
 *   components, the field values and type of an object's components, the
 *   existence of any associations from an object, the existence of
 *   associations to certain types of objects from an object, and an optional
 *   maximum search depth.  The sequence of structures form a RPN logic
 *   evaluation stack.  Macros are provided (see below) that allow a possibly
 *   more readable pre-fix notation to be used when initializing search rule
 *   arrays in variable declarations.
 *
 *   All search values used by Search Rules are data somewhere in the user's
 *   memory space, and are accessed through void pointers. By using the type
 *   specified in the SE_SEARCH_VALUE_TYPE_ENUM, the API knows how to cast
 *   this void pointer.
 *
 *   To see which rules use which fields, and what those fields mean for
 *   each rule, see the comments within the SE_RULE_TYPE_ENUM.
 */
typedef struct
{
SE_RULE_TYPE_ENUM rule_type;
/*
* If the following fields were in a union, then it would be impossible to
* use aggregate initializers (and then the #defined Search Macros could
* not work). So, in order to allow for the Search Macros, these fields
* are presented in a 'plain struct' instead of a union, even though for
* any given rule_type, only a certain sub-set of the fields contain
* applicable values.
*/
SE_TOKEN_ENUM object_type;
SE_TOKEN_ENUM component_object_type;
SE_UINT16 value_offset;
void *value_ptr;
void *second_value_ptr;
SE_SEARCH_VALUE_TYPE_ENUM type_of_value;
SE_PREDICATE user_function_ptr;
SE_UINT16 max_depth;
SE_UINT16 array_length;
} SE_SEARCH_RULES;
Prev: SE_SEARCH_QUALITY_ENUM. Next: SE_SEARCH_VALUE_TYPE_ENUM. Up:Index