Returns this Query cast as R
R
If the Query cannot be cast to R it will throw an exception.
R cast<R extends Query>() => this as R;