Constructor

MaplibreNativeFfiStyleExpressioncreate

Declaration [src]

MaplibreNativeFfiStyleExpression*
maplibre_native_ffi_style_expression_create (
  const char* expression,
  MaplibreNativeFfiStyleExpressionOptions* options,
  GError** error
)

Description [src]

Parses a style [expression](https://maplibre.org/maplibre-style-spec/expressions/) to evaluate without a map.

See mln_style_expression_create in the C API reference.

It fails with these errors:

  • MAPLIBRE_NATIVE_FFI_ERROR_INVALID_ARGUMENT when expression isn’t a valid expression, or its result can’t have the expected type.

Parameters

expression

Type: const char*

The UTF-8 text.

The data is owned by the caller of the function.
The value is a NUL terminated UTF-8 string.
options

Type: MaplibreNativeFfiStyleExpressionOptions

The value, or NULL.

The argument can be NULL.
The data is owned by the caller of the function.
error

Type: GError **

The return location for a recoverable error.

The argument can be NULL.
If the return location is not NULL, then you must initialize it to a NULL GError*.
The argument will be left initialized to NULL by the constructor if there are no errors.
In case of error, the argument will be set to a newly allocated GError; the caller will take ownership of the data, and be responsible for freeing it.

Return value

Type: MaplibreNativeFfiStyleExpression

The object.

The caller of the function takes ownership of the data, and is responsible for freeing it.