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

Renamed method SetHandler accepting both callbacks to SetHandlers #5931

Merged
merged 1 commit into from
May 11, 2022
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
Original file line number Diff line number Diff line change
Expand Up @@ -4760,7 +4760,9 @@ namespace Akka.Streams.Stage
protected void SetHandler<T>(Akka.Streams.Inlet<T> inlet, System.Action onPush, System.Action onUpstreamFinish = null, System.Action<System.Exception> onUpstreamFailure = null) { }
protected void SetHandler<T>(Akka.Streams.Outlet<T> outlet, Akka.Streams.Stage.IOutHandler handler) { }
protected void SetHandler<T>(Akka.Streams.Outlet<T> outlet, System.Action onPull, System.Action onDownstreamFinish = null) { }
[System.ObsoleteAttribute("Use method `SetHandlers` instead. Will be removed in v1.5")]
protected void SetHandler<TIn, TOut>(Akka.Streams.Inlet<TIn> inlet, Akka.Streams.Outlet<TOut> outlet, Akka.Streams.Stage.InAndOutGraphStageLogic handler) { }
protected void SetHandlers<TIn, TOut>(Akka.Streams.Inlet<TIn> inlet, Akka.Streams.Outlet<TOut> outlet, Akka.Streams.Stage.InAndOutGraphStageLogic handler) { }
protected void SetKeepGoing(bool enabled) { }
protected void TryPull<T>(Akka.Streams.Inlet<T> inlet) { }
protected sealed class LambdaInHandler : Akka.Streams.Stage.InHandler
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4771,7 +4771,9 @@ namespace Akka.Streams.Stage
protected void SetHandler<T>(Akka.Streams.Inlet<T> inlet, System.Action onPush, System.Action onUpstreamFinish = null, System.Action<System.Exception> onUpstreamFailure = null) { }
protected void SetHandler<T>(Akka.Streams.Outlet<T> outlet, Akka.Streams.Stage.IOutHandler handler) { }
protected void SetHandler<T>(Akka.Streams.Outlet<T> outlet, System.Action onPull, System.Action onDownstreamFinish = null) { }
[System.ObsoleteAttribute("Use method `SetHandlers` instead. Will be removed in v1.5")]
protected void SetHandler<TIn, TOut>(Akka.Streams.Inlet<TIn> inlet, Akka.Streams.Outlet<TOut> outlet, Akka.Streams.Stage.InAndOutGraphStageLogic handler) { }
protected void SetHandlers<TIn, TOut>(Akka.Streams.Inlet<TIn> inlet, Akka.Streams.Outlet<TOut> outlet, Akka.Streams.Stage.InAndOutGraphStageLogic handler) { }
protected void SetKeepGoing(bool enabled) { }
protected void TryPull<T>(Akka.Streams.Inlet<T> inlet) { }
protected sealed class LambdaInHandler : Akka.Streams.Stage.InHandler
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4760,7 +4760,9 @@ namespace Akka.Streams.Stage
protected void SetHandler<T>(Akka.Streams.Inlet<T> inlet, System.Action onPush, System.Action onUpstreamFinish = null, System.Action<System.Exception> onUpstreamFailure = null) { }
protected void SetHandler<T>(Akka.Streams.Outlet<T> outlet, Akka.Streams.Stage.IOutHandler handler) { }
protected void SetHandler<T>(Akka.Streams.Outlet<T> outlet, System.Action onPull, System.Action onDownstreamFinish = null) { }
[System.ObsoleteAttribute("Use method `SetHandlers` instead. Will be removed in v1.5")]
protected void SetHandler<TIn, TOut>(Akka.Streams.Inlet<TIn> inlet, Akka.Streams.Outlet<TOut> outlet, Akka.Streams.Stage.InAndOutGraphStageLogic handler) { }
protected void SetHandlers<TIn, TOut>(Akka.Streams.Inlet<TIn> inlet, Akka.Streams.Outlet<TOut> outlet, Akka.Streams.Stage.InAndOutGraphStageLogic handler) { }
protected void SetKeepGoing(bool enabled) { }
protected void TryPull<T>(Akka.Streams.Inlet<T> inlet) { }
protected sealed class LambdaInHandler : Akka.Streams.Stage.InHandler
Expand Down
9 changes: 8 additions & 1 deletion src/core/Akka.Streams/Stage/GraphStage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -972,7 +972,14 @@ protected internal void SetHandler<T>(Outlet<T> outlet, Action onPull, Action on
/// <summary>
/// Assigns callbacks for the events for an <see cref="Inlet{T}"/> and <see cref="Outlet{T}"/>.
/// </summary>
protected internal void SetHandler<TIn, TOut>(Inlet<TIn> inlet, Outlet<TOut> outlet, InAndOutGraphStageLogic handler)
[Obsolete("Use method `SetHandlers` instead. Will be removed in v1.5")]
protected internal void SetHandler<TIn, TOut>(Inlet<TIn> inlet, Outlet<TOut> outlet, InAndOutGraphStageLogic handler) =>
SetHandlers(inlet, outlet, handler);

/// <summary>
/// Assigns callbacks for the events for an <see cref="Inlet{T}"/> and <see cref="Outlet{T}"/>.
/// </summary>
protected internal void SetHandlers<TIn, TOut>(Inlet<TIn> inlet, Outlet<TOut> outlet, InAndOutGraphStageLogic handler)
{
SetHandler(inlet, handler);
SetHandler(outlet, handler);
Expand Down