jirutka / rsql-parser

Parser for RSQL / FIQL – query language for RESTful APIs
731 stars 156 forks source link

Is it possible to add a complete example for a custom operator? #31

Open AhmadAbdelghany opened 6 years ago

AhmadAbdelghany commented 6 years ago

For the sake of completeness, would it be possible to give a complete example of a custom operator in the documentation? I understand that semantics of the operator is not a concern of the parser, so my request should really be directed to rsql-jpa. I just could not find a way to open an issue on their project.

jirutka commented 6 years ago

It is already here...

AhmadAbdelghany commented 6 years ago

So I have created custom operator "=all=" or "=subString=" so it is parsable. How do I define the what happens when the operator is executed? How to map it a predicate?

billschauweker commented 3 years ago

Small suggestion for jirutka - or some trying out custom operators in rsql: After adding an operator to the default set, be sure to call the parser constructor with the modified set as an operand.

Great parser by the way.