GeoLeaf Core API - v3.0.0
    Preparing search index...
    • Validates a layer's whole styleRules array.

      Accumulator contract, shared by every function in this module: nothing is returned and nothing throws — findings are pushed into errors and warnings, so one traversal can collect every defect of a profile instead of stopping at the first. A caller decides the profile is invalid by testing errors.length, not by catching.

      A non-array rules is itself an error; each entry is then checked for a when and a style.

      Parameters

      • rules: unknown

        The candidate styleRules value, of unverified shape.

      • errors: ValidationErrorItem[]

        Accumulator for blocking failures. Mutated in place.

      • warnings: ValidationWarningItem[]

        Accumulator for non-blocking remarks. Mutated in place.

      • context: Record<string, unknown>

        Diagnostic data merged into every finding (layer id, profile…).

      Returns void