ActorOptionsBuilder
Dieser Inhalt ist noch nicht in deiner Sprache verfügbar.
Defined in: src/ActorOptions.ts:121
Fluent builder for ActorOptionsType.
Mutates in place and returns this, per the shared OptionsBuilder
contract: two chains off one instance are not two configurations. Build a
second instance instead. The settings are snapshotted at spawn time, so a
builder mutated afterwards never reconfigures a running actor.
Extends
Section titled “Extends”OptionsBuilder<ActorOptionsType<TMessage>>
Type Parameters
Section titled “Type Parameters”TMessage
Section titled “TMessage”TMessage = unknown
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new ActorOptionsBuilder<
TMessage>():ActorOptionsBuilder<TMessage>
Returns
Section titled “Returns”ActorOptionsBuilder<TMessage>
Inherited from
Section titled “Inherited from”Methods
Section titled “Methods”build()
Section titled “build()”build():
Partial<T>
Defined in: src/util/OptionsBuilder.ts:51
Snapshot the set fields as an independent Partial<T> (own props only).
Returns
Section titled “Returns”Partial<T>
Inherited from
Section titled “Inherited from”withDispatcher()
Section titled “withDispatcher()”withDispatcher(
dispatcher):this
Defined in: src/ActorOptions.ts:134
Override the system-wide dispatcher for this actor.
Parameters
Section titled “Parameters”dispatcher
Section titled “dispatcher”Returns
Section titled “Returns”this
withDisplayName()
Section titled “withDisplayName()”withDisplayName(
displayName):this
Defined in: src/ActorOptions.ts:159
Name this actor in logs and the DevTools tree — see ActorOptionsType.displayName.
Parameters
Section titled “Parameters”displayName
Section titled “displayName”string
Returns
Section titled “Returns”this
withEntity()
Section titled “withEntity()”withEntity(
entity):this
Defined in: src/ActorOptions.ts:164
Give this actor a sharding identity — see ActorOptionsType.entity.
Parameters
Section titled “Parameters”entity
Section titled “entity”Returns
Section titled “Returns”this
withInternal()
Section titled “withInternal()”withInternal(
internal?):this
Defined in: src/ActorOptions.ts:154
Mark this actor as tooling — see ActorOptionsType.internal.
Parameters
Section titled “Parameters”internal?
Section titled “internal?”boolean = true
Returns
Section titled “Returns”this
withMailbox()
Section titled “withMailbox()”withMailbox(
mailbox):this
Defined in: src/ActorOptions.ts:149
Full control over the queue — any Mailbox subclass.
Parameters
Section titled “Parameters”mailbox
Section titled “mailbox”MailboxFactory<TMessage>
Returns
Section titled “Returns”this
withMailboxCapacity()
Section titled “withMailboxCapacity()”withMailboxCapacity(
mailboxCapacity):this
Defined in: src/ActorOptions.ts:139
Lower (or raise) the default bounded mailbox’s ceiling.
Parameters
Section titled “Parameters”mailboxCapacity
Section titled “mailboxCapacity”number
Returns
Section titled “Returns”this
withMailboxOverflow()
Section titled “withMailboxOverflow()”withMailboxOverflow(
mailboxOverflow):this
Defined in: src/ActorOptions.ts:144
What a full mailbox does — see ActorOptionsType.mailboxOverflow.
Parameters
Section titled “Parameters”mailboxOverflow
Section titled “mailboxOverflow”Returns
Section titled “Returns”this
withSupervisorStrategy()
Section titled “withSupervisorStrategy()”withSupervisorStrategy(
supervisorStrategy):this
Defined in: src/ActorOptions.ts:129
How the parent supervises this actor — see ActorOptionsType.supervisorStrategy.
Parameters
Section titled “Parameters”supervisorStrategy
Section titled “supervisorStrategy”Returns
Section titled “Returns”this
create()
Section titled “create()”
staticcreate<TMessage>():ActorOptionsBuilder<TMessage>
Defined in: src/ActorOptions.ts:124
Start a fresh builder. Equivalent to new ActorOptionsBuilder().
Type Parameters
Section titled “Type Parameters”TMessage
Section titled “TMessage”TMessage = unknown
Returns
Section titled “Returns”ActorOptionsBuilder<TMessage>
