Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix typespecs in UtilitySupervisor #681

Merged
merged 2 commits into from
Nov 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
* Specify the order in which state fields will be printed in the error logs. [#614](https://github.com/membraneframework/membrane_core/pull/614)
* Fix clock selection [#626](https://github.com/membraneframework/membrane_core/pull/626)
* Log messages in the default handle_info implementation [#680](https://github.com/membraneframework/membrane_core/pull/680)
* Fix typespecs in Membrane.UtilitySupervisor [#681](https://github.com/membraneframework/membrane_core/pull/681)

## 1.0.0
* Introduce `:remove_link` action in pipelines and bins.
Expand Down
10 changes: 8 additions & 2 deletions lib/membrane/utility_supervisor.ex
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,22 @@ defmodule Membrane.UtilitySupervisor do

@doc """
Starts a process under the utility supervisor.

Semantics of the `child_spec` argument is the same as in `Supervisor.child_spec/2`.
"""
@spec start_child(t, Supervisor.child_spec()) :: Supervisor.on_start_child()
@spec start_child(t, Supervisor.child_spec() | {module(), term()} | module()) ::
Supervisor.on_start_child()
defdelegate start_child(supervisor, child_spec),
to: Membrane.Core.SubprocessSupervisor,
as: :start_utility

@doc """
Starts a process under the utility supervisor and links it to the current process.

Semantics of the `child_spec` argument is the same as in `Supervisor.child_spec/2`.
"""
@spec start_link_child(t, Supervisor.child_spec()) :: Supervisor.on_start_child()
@spec start_link_child(t, Supervisor.child_spec() | {module(), term()} | module()) ::
Supervisor.on_start_child()
defdelegate start_link_child(supervisor, child_spec),
to: Membrane.Core.SubprocessSupervisor,
as: :start_link_utility
Expand Down
Loading