Пример #1
0
        /// <summary>
        /// Creates a new <see cref="Akka.Actor.Props" /> with a given <paramref name="mailbox" />.
        ///
        /// <note>
        /// This method is immutable and returns a new instance of <see cref="Akka.Actor.Props" />.
        /// </note>
        /// </summary>
        /// <param name="mailbox">The mailbox used when deploying the actor.</param>
        /// <returns>A new <see cref="Akka.Actor.Props" /> with the provided <paramref name="mailbox" />.</returns>
        public Props WithMailbox(string mailbox)
        {
            Props copy = Copy();

            copy.Deploy = Deploy.WithMailbox(mailbox);
            return(copy);
        }
Пример #2
0
        /// <summary>
        ///     Returns a new Props with the specified mailbox set.
        /// </summary>
        /// <param name="path">The path.</param>
        /// <returns>Props.</returns>
        public Props WithMailbox(string path)
        {
            Props copy = Copy();

            copy.Deploy = Deploy.WithMailbox(path);
            return(copy);
        }