Home Reference Source Test
public class | source

ThrottledQueue

Extends:

QueueUniqueQueue → ThrottledQueue

Constructor Summary

Public Constructor
public

constructor(maxAtOnce: number, allowanceNum: number, allowanceInterval: number, maxSize: number, allowanceCallback: function)

Member Summary

Public Members
public get

available: number

Method Summary

Public Methods
public

dequeue(): V | *

public

dequeueMulti(count: number): Array<V|*>

public

enqueue(value: V | *): void

public

isAvailable(): boolean

public

stop(): void

Inherited Summary

From class Queue
public get

length: number

protected
public

clear(): void

public

dequeue(): V | *

public

dequeueMulti(count: number): Array<V|*>

public

enqueue(value: V | *): void

public

enqueueAll(values: Array<V|*>): void

public

isEmpty(): boolean

public

peek(): V | *

protected

_newQueue(args: *): LinkedList<V|*>

From class UniqueQueue
public

contains(value: V | *): boolean

public

remove(value: V | *): void

public

requeue(value: V | *): void

protected

_newQueue(args: *): LinkedList<V|*>

Public Constructors

public constructor(maxAtOnce: number, allowanceNum: number, allowanceInterval: number, maxSize: number, allowanceCallback: function) source

Override:

UniqueQueue#constructor

Params:

NameTypeAttributeDescription
maxAtOnce number
  • optional
allowanceNum number
  • optional
allowanceInterval number
  • optional
maxSize number
  • optional
allowanceCallback function
  • optional

Public Members

public get available: number source

Public Methods

public dequeue(): V | * source

Override:

Queue#dequeue

Return:

V | *

public dequeueMulti(count: number): Array<V|*> source

Override:

Queue#dequeueMulti

Params:

NameTypeAttributeDescription
count number

Return:

Array<V|*>

public enqueue(value: V | *): void source

Override:

Queue#enqueue

Params:

NameTypeAttributeDescription
value V | *

Return:

void

public isAvailable(): boolean source

Return:

boolean

public stop(): void source

Return:

void