|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Object | +--Predicate
Creates a predicate from an object, returning a single-argument function that returns true on certain input, as described below.
In general, wherever a predicate is asked for by a function, any of the types in the left-hand column of the table below may be supplied.
| typeof p | behavior of returned function in terms of argument c | ||||||||
| function | p | ||||||||
| Predicate | p.matches | ||||||||
| Array | true if c is a value in p | ||||||||
| object | true if c is value of one of p's properties | ||||||||
| anything else | true if c === p | ||||||||
| Field Summary | |
Object |
matches
|
| Constructor Summary | |
Predicate(p)
|
|
| Field Detail |
Object matches
| Constructor Detail |
Predicate(p)
p - The predicate source
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||