Created by: latortuga
Bit of a work in progress/hack. Map all searchable fields into a hash and allow each field class to customize the search predicate and comparison term based on the passed search string. If no matching enum value is found in the search term (based on == compare), omit enum field from search string. Otherwise, try to map it to the correct integer value.
I think this needs a new class of some kind, perhaps something like SearchField
, instantiated by either the Field class itself or the Deferred class which would avoid having to have the ugly class methods on the fields and the arity difference for enums only. I'm seriously open to design feedback on this one because, while It Works