
cts.nearQueryQueries( query as cts.nearQuery ) as Sequence
Returns the query sequence used to construct the near query.
| Parameters | |
|---|---|
| query | A query. |
cts.nearQueryQueries(query)
=> ... a Sequence of the queries used to
construct this query
const query =
cts.nearQuery([
cts.wordQuery("to be or"),
cts.wordQuery("or not to be")]);
const res = new Array();
for (const x of cts.nearQueryQueries(query)) {
res.push(x);
};
res;
=> [{"wordQuery":{"text":["to be or"],"options":["lang=en"]}},
{"wordQuery":{"text":["or not to be"],"options":["lang=en"]}}]