You're seeing just the macro def_options, go back to Membrane.Element.Base module for more information.
Link to this macro


View Source (macro)

Macro defining options that parametrize element.

It automatically generates appropriate struct and documentation.

Options are defined by a keyword list, where each key is an option name and is described by another keyword list with following fields:

  • type: atom, used for parsing
  • spec: typespec for value in struct. If ommitted, for types: [:atom, :boolean, :caps, :keyword, :string, :struct, :time] the default typespec is provided, for others typespec is set to any/0
  • default: default value for option. If not present, value for this option will have to be provided each time options struct is created
  • inspector: function converting fields' value to a string. Used when creating documentation instead of inspect/1
  • description: string describing an option. It will be used for generating the docs