Download
(25 Kb)
Download
Updated: 01-12-14 07:07 PM
Updated:01-12-14 07:07 PM
Created:02-29-12 03:37 AM
Downloads:595
Favorites:0
MD5:
LibEnfiltrate
Version: 0.7
by: seebs [More]
This is the abstract filtering library I've been nattering about. It's woefully incomplete, and very-beta, but you can now sort of see what I'm going for.

The idea is: Lots of Inspect.*.Detail return a big table of { key = { many members } }. Often, we want to see only some of those members.

So.

Let's say you want to search a Something, and it returns a table like that. Or heck, let's say you made the table yourself.

named_bob = Library.LibEnfiltrate.Filter:new('bob')
named_bob:include('name:bob')
results = named_bob:filter(your_table_here)

Congrads! You have everything that was in your_table_here which contained "bob", case-insensitive. Oh, wait. You meant EXACTLY bob.
named_bob:disinclude(1)
named_bob:include({ name = 'name', relation = '==', value = 'bob' })

There you go.
0.2: The version used in LibBaggotry, now cleaned up enough that I can use it from other addons.
0.4: Mostly just ToC updates and small fixes.
0.5: ToC updates, change printf implementation.
0.6: New libgetopt for new event model.
0.7: Fancy internal updates to allow subfields, like "stats.resistAll".
Optional Files (0)


Archived Files (5)
File Name
Version
Size
Author
Date
0.6
25kB
seebs
07-12-13 07:56 PM
0.5
23kB
seebs
11-03-12 01:39 AM
0.4
17kB
seebs
06-22-12 09:49 PM
0.2
16kB
seebs
02-29-12 07:54 PM
0.1
14kB
seebs
02-29-12 03:37 AM


Post A Reply Comment Options
Unread 02-29-12, 07:54 PM  
seebs
Super Moderator
Riftui Super Moderator
AddOn Author - Click to view AddOns

Forum posts: 9
File comments: 31
Uploads: 36
No! To "disinclude" is to remove an item from the "includes" ruleset. To "exclude" is to add an item to the "excludes" ruleset.

These are not equivalent.
seebs is offline Report comment to moderator  
Reply With Quote
Unread 02-29-12, 10:35 AM  
Bard
 
Bard's Avatar
AddOn Author - Click to view AddOns

Forum posts: 0
File comments: 48
Uploads: 1
By disinclude did you mean exclude by any chance?

Bard is offline Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump: