EcsElixirCore.Domain.Model.EcsMiddleware.Value.CoreExceptionLevelValidator (ecs_elixir_core v1.0.0)

Copy Markdown

Validates the level field for a CoreException.

Summary

Functions

Returns the list of accepted log levels (delegated to EcsLogLevel).

Validates that level is one of the accepted values or nil.

Functions

valid_levels()

@spec valid_levels() :: [String.t()]

Returns the list of accepted log levels (delegated to EcsLogLevel).

validate(level)

@spec validate(String.t() | nil) :: :ok | {:error, String.t()}

Validates that level is one of the accepted values or nil.