| java.lang.Object | |
| ↳ | org.mule.module.magento.filters.FiltersParser |
A Magento's filter expression parser.
|
[Expand]
Inherited Constants | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From interface
org.mule.module.magento.filters.FiltersParserConstants
| |||||||||||
| Fields | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| builder | |||||||||||
| jj_expentries | |||||||||||
| jj_expentry | |||||||||||
| jj_gen | |||||||||||
| jj_input_stream | |||||||||||
| jj_kind | |||||||||||
| jj_la1 | |||||||||||
| jj_la1_0 | |||||||||||
| jj_nt | Next token. | ||||||||||
| jj_ntk | |||||||||||
| token | Current token. | ||||||||||
| token_source | Generated Token Manager. | ||||||||||
|
[Expand]
Inherited Fields | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From interface
org.mule.module.magento.filters.FiltersParserConstants
| |||||||||||
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Constructor with InputStream.
| |||||||||||
Constructor with InputStream and supplied encoding
| |||||||||||
Constructor.
| |||||||||||
Constructor with generated Token Manager.
| |||||||||||
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Reinitialise.
| |||||||||||
Reinitialise.
| |||||||||||
Reinitialise.
| |||||||||||
Reinitialise.
| |||||||||||
Disable tracing.
| |||||||||||
Enable tracing.
| |||||||||||
Generate ParseException.
| |||||||||||
Get the next Token.
| |||||||||||
Get the specific Token.
| |||||||||||
Parses a filter expression.
| |||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
Constructor with InputStream.
| stream |
|---|
Constructor with InputStream and supplied encoding
| stream | |
|---|---|
| encoding |
Constructor.
| stream |
|---|
Constructor with generated Token Manager.
| tm |
|---|
Reinitialise.
| stream | |
|---|---|
| encoding |
Reinitialise.
| stream |
|---|
Reinitialise.
| stream |
|---|
Disable tracing.
Enable tracing.
Parses a filter expression.
The syntax used by it is quite simple: it consist of one or more comma-separated unary or binary predicates, one for each filter. Unary predicates are in the form <predicateType>(<targetAttribute>), while binary ones are in the form <predicateType>(<targetAttribute>, <targetAttributeValue>), where <predicateType> is any of the supported Magento operators: eq, neq, like, null, etc.
For example, the following expressions creates a filter for entities whose customer id is greater
than 1500, and its deletion date is not null:
gt(customer_id, 1500), notnull(deletion_date)
| expression | A nullable expression. in the previously described syntax. Null expressions and empty expressions are interpreted as empty filters |
|---|
| IllegalArgumentException | if the expression can not be parsed |
|---|