Membrane.ComponentPath (Membrane Core v0.7.0) View Source

Traces element's path inside a pipeline. Path is a list consisted of following pipeline/bin/element names down the assembled pipeline. Information is being stored in a process dictionary and can be set/appended to.

Link to this section Summary

Functions

Appends given name to the current path.

Returns formatted string of given path's names joined with separator.

Returns currently stored path.

Works the same as format/2 but uses currently stored path

Sets current path.

Convenient combination of set/1 and append/1.

Link to this section Types

Specs

path_t() :: [String.t()]

Link to this section Functions

Specs

append(String.t()) :: :ok

Appends given name to the current path.

If path has not been previously set then creates new one with given name.

Link to this function

format(path, separator \\ "/")

View Source

Specs

format(path_t(), String.t()) :: String.t()

Returns formatted string of given path's names joined with separator.

Specs

get() :: [String.t()]

Returns currently stored path.

If path has not been set, empty list is returned.

Link to this function

get_formatted(separator \\ "/")

View Source

Specs

get_formatted(String.t()) :: String.t()

Works the same as format/2 but uses currently stored path

Specs

set(path_t()) :: :ok

Sets current path.

If path had already existed then replaces it.

Link to this function

set_and_append(path, name)

View Source

Specs

set_and_append(path_t(), String.t()) :: :ok

Convenient combination of set/1 and append/1.