resolveDollar ( ) {

Determine the numeric index, if any, of a value matching the positional operator. The prefix path where the positional operator was found is required, e.g. comments.$.author uses the path comments.

Both path and pathstr are required (not generated) because if you are calling resolveDollar you probably have or need both of these anyway.

Arguments

| Object target

The outer document to search. Must have the same root as the path and pathstr arguments.

| Object query

The query object used to generate the positional operator.

| Array path

The prefix path where the positional operator was found, as an Array of keys.

| String pathstr

The prefix path where the positional operator was found, as a dot-delimited String.