Returns an instance for the specified range expression. @param expr sequence expression @param cc compilation context @return range or null @throws QueryException query exception
(final Expr expr, final CompileContext cc)
| 35 | * @throws QueryException query exception |
| 36 | */ |
| 37 | public static SeqRange get(final Expr expr, final CompileContext cc) throws QueryException { |
| 38 | // check if expression is fn:subsequence or util:range |
| 39 | return expr instanceof final FnSubsequence sub ? sub.range(cc) : null; |
| 40 | } |
| 41 | |
| 42 | /** |
| 43 | * Adjusts the range values by applying the result size. |