View Source edb_dap_launch_config (edb v0.3.0)

DAP Launch Configuration Validation functions for the DAP launch configuration

Summary

Types

field_validation/0

-type field_validation() :: value_validation() | {optional, value_validation()}.

map_template/0

-type map_template() :: #{atom() => field_validation()}.

predicate/0

-type predicate() :: fun((term()) -> boolean()).

t/0

-type t() ::
          #{launchCommand => #{cwd := binary(), command := binary(), arguments => [binary()]},
            targetNode => #{name := binary(), cookie => binary(), type => binary()},
            stripSourcePath => binary(),
            timeout => non_neg_integer()}.

value_validation/0

-type value_validation() :: predicate() | map_template().

Functions

parse(LaunchConfig)

-spec parse(term()) -> {ok, t()} | {error, HumarReadableReason :: binary()}.