Search Results for

    Show / Hide Table of Contents

    Class InternalTestActorRef

    INTERNAL This special ActorRef is exclusively for use during unit testing in a single-threaded environment. Therefore, it overrides the dispatcher to CallingThreadDispatcher and sets the receiveTimeout to None. Otherwise, it acts just like a normal ActorRef. You may retrieve a reference to the underlying actor to test internal logic. Note! Part of internal API. Breaking changes may occur without notice. Use at own risk.

    Inheritance
    object
    ActorRefBase
    InternalActorRefBase
    ActorRefWithCell
    LocalActorRef
    InternalTestActorRef
    Implements
    IActorRef
    ICanTell
    IEquatable<IActorRef>
    IComparable<IActorRef>
    ISurrogated
    IComparable
    Inherited Members
    LocalActorRef.Underlying
    LocalActorRef.Cell
    LocalActorRef.Provider
    LocalActorRef.Parent
    LocalActorRef.Children
    LocalActorRef.Start()
    LocalActorRef.Stop()
    LocalActorRef.Suspend()
    LocalActorRef.IsLocal
    LocalActorRef.SendSystemMessage(ISystemMessage)
    LocalActorRef.Path
    LocalActorRef.System
    LocalActorRef.Props
    LocalActorRef.Dispatcher
    LocalActorRef.Supervisor
    LocalActorRef.IsTerminated
    LocalActorRef.MailboxType
    LocalActorRef.Resume(Exception)
    LocalActorRef.Restart(Exception)
    LocalActorRef.TellInternal(object, IActorRef)
    LocalActorRef.GetSingleChild(string)
    LocalActorRef.GetChild(IReadOnlyList<string>)
    ActorRefBase.Tell(object, IActorRef)
    ActorRefBase.Equals(object)
    ActorRefBase.GetHashCode()
    ActorRefBase.CompareTo(object)
    ActorRefBase.Equals(IActorRef)
    ActorRefBase.CompareTo(IActorRef)
    ActorRefBase.ToSurrogate(ActorSystem)
    object.Equals(object, object)
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: Akka.TestKit.Internal
    Assembly: Akka.TestKit.dll
    Syntax
    public class InternalTestActorRef : LocalActorRef, IActorRef, ICanTell, IEquatable<IActorRef>, IComparable<IActorRef>, ISurrogated, IComparable

    Properties

    | Edit this page View Source

    UnderlyingActor

    TBD

    Declaration
    public object UnderlyingActor { get; }
    Property Value
    Type Description
    object
    Exceptions
    Type Condition
    IllegalActorStateException

    TBD

    Methods

    | Edit this page View Source

    Create(ActorSystem, Props, IActorRef, string)

    INTERNAL Note! Part of internal API. Breaking changes may occur without notice. Use at own risk.

    Declaration
    public static InternalTestActorRef Create(ActorSystem system, Props props, IActorRef supervisor = null, string name = null)
    Parameters
    Type Name Description
    ActorSystem system

    TBD

    Props props

    TBD

    IActorRef supervisor

    TBD

    string name

    TBD

    Returns
    Type Description
    InternalTestActorRef

    TBD

    Exceptions
    Type Condition
    IllegalStateException

    TBD

    | Edit this page View Source

    CreateUniqueName()

    INTERNAL Note! Part of internal API. Breaking changes may occur without notice. Use at own risk.

    Declaration
    public static string CreateUniqueName()
    Returns
    Type Description
    string

    TBD

    | Edit this page View Source

    GetTestActorCell()

    TBD

    Declaration
    protected InternalTestActorRef.TestActorCell GetTestActorCell()
    Returns
    Type Description
    InternalTestActorRef.TestActorCell

    TBD

    | Edit this page View Source

    NewActorCell(ActorSystemImpl, IInternalActorRef, Props, MessageDispatcher, IInternalActorRef)

    TBD

    Declaration
    protected override ActorCell NewActorCell(ActorSystemImpl system, IInternalActorRef self, Props props, MessageDispatcher dispatcher, IInternalActorRef supervisor)
    Parameters
    Type Name Description
    ActorSystemImpl system

    TBD

    IInternalActorRef self

    TBD

    Props props

    TBD

    MessageDispatcher dispatcher

    TBD

    IInternalActorRef supervisor

    TBD

    Returns
    Type Description
    ActorCell

    TBD

    Overrides
    LocalActorRef.NewActorCell(ActorSystemImpl, IInternalActorRef, Props, MessageDispatcher, IInternalActorRef)
    | Edit this page View Source

    Receive(object, IActorRef)

    Directly inject messages into actor receive behavior. Any exceptions thrown will be available to you, while still being able to use become/unbecome.

    Declaration
    public void Receive(object message, IActorRef sender = null)
    Parameters
    Type Name Description
    object message

    The message.

    IActorRef sender

    The sender.

    | Edit this page View Source

    ReceiveAsync(object, IActorRef)

    Declaration
    public Task ReceiveAsync(object message, IActorRef sender = null)
    Parameters
    Type Name Description
    object message
    IActorRef sender
    Returns
    Type Description
    Task
    | Edit this page View Source

    ToString()

    TBD

    Declaration
    public override string ToString()
    Returns
    Type Description
    string

    TBD

    Overrides
    ActorRefBase.ToString()
    | Edit this page View Source

    Unwatch(IActorRef)

    Deregisters this actor from being a death monitor of the provided ActorRef This means that this actor will not get a Terminated()-message when the provided actor is permanently terminated. Returns the same ActorRef that is provided to it, to allow for cleaner invocations.

    Declaration
    public void Unwatch(IActorRef subject)
    Parameters
    Type Name Description
    IActorRef subject

    The subject to unwatch.

    | Edit this page View Source

    Watch(IActorRef)

    Registers this actor to be a death monitor of the provided ActorRef This means that this actor will get a Terminated()-message when the provided actor is permanently terminated. Returns the same ActorRef that is provided to it, to allow for cleaner invocations.

    Declaration
    public void Watch(IActorRef subject)
    Parameters
    Type Name Description
    IActorRef subject

    The subject to watch.

    Implements

    IActorRef
    ICanTell
    IEquatable<T>
    IComparable<T>
    ISurrogated
    IComparable

    Extension Methods

    ActorRefExtensions.GetOrElse(IActorRef, Func<IActorRef>)
    ActorRefExtensions.IsNobody(IActorRef)
    ActorRefImplicitSenderExtensions.Forward(IActorRef, object)
    ActorRefImplicitSenderExtensions.Tell(IActorRef, object)
    GracefulStopSupport.GracefulStop(IActorRef, TimeSpan)
    GracefulStopSupport.GracefulStop(IActorRef, TimeSpan, object)
    WatchAsyncSupport.WatchAsync(IActorRef, CancellationToken)
    Futures.Ask(ICanTell, object, TimeSpan?)
    Futures.Ask(ICanTell, object, TimeSpan?, CancellationToken)
    Futures.Ask(ICanTell, object, CancellationToken)
    Futures.Ask<T>(ICanTell, Func<IActorRef, object>, TimeSpan?, CancellationToken)
    Futures.Ask<T>(ICanTell, object, TimeSpan?)
    Futures.Ask<T>(ICanTell, object, TimeSpan?, CancellationToken)
    Futures.Ask<T>(ICanTell, object, CancellationToken)
    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