Re: RFC: Operation Options API proposal



El vie, 25-03-2011 a las 13:37 +0100, Guillaume Emont escribió:
> On 25/03/2011 13:12, Iago Toral Quiroga wrote:
> >>> Or maybe I
> >>> am not understanding its purpose well.... Also, what is 'key' and what
> >>> is 'value' in the case of a filter with no arguments? (Like the filter
> >>> by types you considered originally)?
> >> could be something like:
> >>   grl_caps_test_option_int (caps, "type-filter", GRL_FILTER_TYPE_VIDEO);
> >> (or would we need a test_option_enum?)
> > 
> > Aha, so for an artist filter we would have something like this then?
> > grl_caps_test_option_string (caps, "artist-filter", artist)?
> > 
> It might be something like that, unless we want filtering on artists to
> be more subtle in a way that would require some more complex structure
> instead of a string.

Probably not.

> In such a case, I think it would be simpler to create a specific test
> function like grl_caps_test_artist_filter (caps, artist_filter); where
> artist_filter is an instance of some complicated structure (or we could
> have each member of this structure be an argument to
> _test_artist_filter() instead of passing the structure).

Yes, that is always an option.

Iago



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]