FlowRunner.Spec.ResourceValue (flow_runner v6.15.1)

Copy Markdown

ResourceValue is a struct that stores a piece of content for a given language and mode.

Summary

Functions

Cast the received fields to their internal representation

Load the map or list of maps into Elixir.FlowRunner.Spec.ResourceValue structs.

Validate a Elixir.FlowRunner.Spec.ResourceValue struct using Vex.validate

Types

t()

@type t() :: %FlowRunner.Spec.ResourceValue{
  content_type: String.t(),
  language_id: String.t(),
  mime_type: String.t(),
  modes: [String.t()],
  value: String.t()
}

Functions

cast!(module, map)

@spec cast!(module(), map()) :: map()

Cast the received fields to their internal representation

load!(blocks_module, list)

@spec load!(module(), map()) :: t()
@spec load!(module(), [map()]) :: [t()]

Load the map or list of maps into Elixir.FlowRunner.Spec.ResourceValue structs.

subset(value)

subset(options, value)

supports_mode(resource_value, mode)

valid?(self)

validate!(blocks_module, impl)

@spec validate!(blocks_module :: module(), t()) :: t()

Validate a Elixir.FlowRunner.Spec.ResourceValue struct using Vex.validate