Note that you can put a space between the colon but currently there must be no space between the operator and the number.
I left fuzzy-matching (e.g. "~bpm" to specify tracks with similar BPMs to currently playing tracks and "~key" to specify harmonically compatible tracks) as stub methods in the SearchQueryParser class. If anybody wants to tackle those it should be pretty easy to get started.
As a stopgap before Bart's Full-Text-Search branch is finished I hacked up a dead-simple query parser tonight. It's currently in trunk.
* Text filtering (artist, album, genre, title, composer, comment)
* Numeric filtering (year, track, bpm, duration, played, rating)
For text filtering, you can do queries like:
- artist: "com truise"
- artist:Danger
- genre: Trance
Note it doesn't matter if you have a space between the colon and the argument or not.
For numeric filtering you can do either either exact number or range filtering:
- bpm:140
- bpm: >140
- year: <2010
- bpm: >=140
- rating: <=4
- bpm: 140-150
- played: >10
Note that you can put a space between the colon but currently there must be no space between the operator and the number.
I left fuzzy-matching (e.g. "~bpm" to specify tracks with similar BPMs to currently playing tracks and "~key" to specify harmonically compatible tracks) as stub methods in the SearchQueryParser class. If anybody wants to tackle those it should be pretty easy to get started.