@maplibre/native-ffi
    Preparing search index...

    Class StyleExpressionHandle

    A parsed style expression.

    See mln_style_expression in the C API reference.

    Hierarchy

    • Owner
      • StyleExpressionHandle
    Index
    "[asyncDispose]": () => Promise<void>

    Calls release(), for await using. Hosts without Symbol.asyncDispose, such as ArkTS, leave it undefined.

    "[dispose]": () => void

    Calls release(), for using. Hosts without Symbol.dispose, such as ArkTS, leave it undefined.

    id: bigint

    The native handle value. It stays readable after release.

    • Evaluates a style expression and writes its result as JSON.

      A number in the result that isn't finite becomes null. A color is ["rgba", r, g, b, a], with red, green, and blue from 0 to 255 and alpha from 0 to 1, each exact only to single precision. Formatted text is a ["format", …] expression, an image is {"name": …, "available": …}, padding is [top, right, bottom, left], and a variable anchor offset is [anchor, [x, y], …].

      See mln_style_expression_evaluate in the C API reference.

      Errors:

      • Status.invalidArgument when the expression fails to evaluate, such as when it reads an input that inputs doesn't set.

      Parameters

      Returns unknown