PriorityMailboxOptionsValidator
此内容尚不支持你的语言。
Defined in: src/mailbox/PriorityMailboxOptions.ts:162
Validates resolved PriorityMailboxOptionsType settings.
priorityFor gets a required-and-callable check because the accepted input
union includes Partial<…> — new PriorityMailbox({}) type-checks, and
before #647 it failed as this.priorityFor is not a function on the first
enqueue, which is inside the sender’s tell and a long way from the
mistake. There is no function helper on OptionsValidator (nothing else
in the project needs one), so this is a bespoke fail rule.
overflow without capacity is rejected rather than ignored, for the same
reason ActorOptions rejects the pair: an unbounded mailbox never
overflows, so a policy on its own is a no-op that reads like configuration.
Extends
Section titled “Extends”Type Parameters
Section titled “Type Parameters”T
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new PriorityMailboxOptionsValidator<
T>():PriorityMailboxOptionsValidator<T>
Defined in: src/mailbox/PriorityMailboxOptions.ts:163
Returns
Section titled “Returns”PriorityMailboxOptionsValidator<T>
Overrides
Section titled “Overrides”OptionsValidator<PriorityMailboxOptionsType<T>>.constructor
Methods
Section titled “Methods”validate()
Section titled “validate()”validate(
settings):void
Defined in: src/util/OptionsValidator.ts:76
Check the (merged) settings; throws OptionsError on the first
violation. Unset (undefined) fields always pass.
Parameters
Section titled “Parameters”settings
Section titled “settings”Partial<T>
Returns
Section titled “Returns”void
