Search Results for

    Show / Hide Table of Contents

    Class Balance<T>

    Fan-out the stream to several streams. Each upstream element is emitted to the first available downstream consumer. It will not shut down until the subscriptions for at least two downstream subscribers have been established.

    A Balance<T> has one In port and 2 or more Out(int) ports.

    Emits when any of the outputs stops backpressuring; emits the element to the first available output

    Backpressures when all of the outputs backpressure

    Completes when upstream completes

    Cancels when all downstreams cancel
    Inheritance
    object
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>
    GraphStage<UniformFanOutShape<T, T>>
    Balance<T>
    Implements
    IGraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>
    IGraph<UniformFanOutShape<T, T>, NotUsed>
    IGraph<UniformFanOutShape<T, T>>
    Inherited Members
    GraphStage<UniformFanOutShape<T, T>>.CreateLogicAndMaterializedValue(Attributes)
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.Shape
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.WithAttributes(Attributes)
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.CreateLogicAndMaterializedValue(Attributes)
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.Module
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.AddAttributes(Attributes)
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.Named(string)
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.Async()
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.ReferenceEquals(object, object)
    Namespace: Akka.Streams.Dsl
    Assembly: Akka.Streams.dll
    Syntax
    public sealed class Balance<T> : GraphStage<UniformFanOutShape<T, T>>, IGraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>, IGraph<UniformFanOutShape<T, T>, NotUsed>, IGraph<UniformFanOutShape<T, T>>
    Type Parameters
    Name Description
    T

    TBD

    Constructors

    | Edit this page View Source

    Balance(int, bool)

    Initializes a new instance of the Balance<T> class.

    Declaration
    public Balance(int outputPorts, bool waitForAllDownstreams = false)
    Parameters
    Type Name Description
    int outputPorts

    TBD

    bool waitForAllDownstreams

    TBD

    Exceptions
    Type Condition
    ArgumentException

    This exception is thrown when the specified outputPorts is less than one.

    Properties

    | Edit this page View Source

    In

    TBD

    Declaration
    public Inlet<T> In { get; }
    Property Value
    Type Description
    Inlet<T>
    | Edit this page View Source

    InitialAttributes

    TBD

    Declaration
    protected override Attributes InitialAttributes { get; }
    Property Value
    Type Description
    Attributes
    Overrides
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.InitialAttributes
    | Edit this page View Source

    Shape

    TBD

    Declaration
    public override UniformFanOutShape<T, T> Shape { get; }
    Property Value
    Type Description
    UniformFanOutShape<T, T>
    Overrides
    GraphStageWithMaterializedValue<UniformFanOutShape<T, T>, NotUsed>.Shape

    Methods

    | Edit this page View Source

    CreateLogic(Attributes)

    TBD

    Declaration
    protected override GraphStageLogic CreateLogic(Attributes inheritedAttributes)
    Parameters
    Type Name Description
    Attributes inheritedAttributes

    TBD

    Returns
    Type Description
    GraphStageLogic

    TBD

    Overrides
    GraphStage<UniformFanOutShape<T, T>>.CreateLogic(Attributes)
    | Edit this page View Source

    Out(int)

    TBD

    Declaration
    public Outlet<T> Out(int id)
    Parameters
    Type Name Description
    int id

    TBD

    Returns
    Type Description
    Outlet<T>

    TBD

    | Edit this page View Source

    ToString()

    TBD

    Declaration
    public override string ToString()
    Returns
    Type Description
    string

    TBD

    Overrides
    object.ToString()

    Implements

    IGraphStageWithMaterializedValue<TShape, TMaterialized>
    IGraph<TShape, TMaterialized>
    IGraph<TShape>

    Extension Methods

    ObjectExtensions.IsDefaultForType<T>(T)
    ObjectExtensions.AsOption<T>(T)
    Extensions.AsInstanceOf<T>(object)
    In this article
    • githubEdit this page
    • View Source
    Back to top
    Contribute
    • Project Chat
    • Discussion Forum
    • Source Code
    Support
    • Akka.NET Support Plans
    • Akka.NET Observability Tools
    • Akka.NET Training & Consulting
    Maintained By
    • Petabridge - The Akka.NET Company
    • Learn Akka.NET