InternalProtected_The array of scheduled timeline events
Set this debug flag to log all events that happen in this class.
If the time value must always be greater than or equal to the last element on the list.
The memory of the timeline, i.e. how many events in the past it will retain
ReadonlynameThe name of the class
StaticversionThe version number semver
Indicates if the instance was disposed. 'Disposing' an instance means that all of the Web Audio nodes that were created for the instance are disconnected and freed for garbage collection.
The number of items in the timeline.
Protected_Does a binary search on the timeline array and returns the nearest event index whose time is after or equal to the given time. If a time is searched before the first index in the timeline, -1 is returned. If the time is after the end, the index of the last item is returned.
Optionalparam: TimelineSearchParamInsert an event object onto the timeline. Events must have a "time" attribute.
The event object to insert into the timeline.
Cancel events at and after the given time
The time to query.
Cancel events before or equal to the given time.
The time to cancel before.
Clean up.
Iterate over everything in the array
The callback to invoke with every item
Iterate over everything in the array after the given time.
The time to check if items are before
The callback to invoke with every item
Iterate over everything in the array at the given time
The time to check if items are before
The callback to invoke with every item
Iterate over everything in the array at or before the given time.
The time to check if items are before
The callback to invoke with every item
Iterate over everything in the array between the startTime and endTime. The timerange is inclusive of the startTime, but exclusive of the endTime. range = [startTime, endTime).
The time to check if items are before
The end of the test interval.
The callback to invoke with every item
Iterate over everything in the array at or after the given time. Similar to forEachAfter, but includes the item(s) at the given time.
The time to check if items are before
The callback to invoke with every item
Get the nearest event whose time is less than or equal to the given time.
The time to query.
Optionalparam: TimelineSearchParamGet the event which is scheduled after the given time.
The time to query.
Optionalparam: TimelineSearchParamGet the event before the event at the given time.
The time to query.
Return the event before the time with the given state
The state to look for
When to check before
The event with the given state before the time
Return the event after the time with the given state
The state to look for
When to check from
The event with the given state after the time
Returns the scheduled state scheduled before or at the given time.
The time to query.
The name of the state input in setStateAtTime.
ProtectedlogPrints the outputs to the console log for debugging purposes.
Prints the contents only if either the object has a property
called debug set to true, or a variable called TONE_DEBUG_CLASS
is set to the name of the class.
Return the first event in the timeline without removing it
The first event object
Returns the previous event if there is one. null otherwise
The event to find the previous one of
The event right before the given event
Remove an event from the timeline.
The event object to remove from the list.
this
Add a state to the timeline.
The name of the state to set.
The time to query.
Optionaloptions: AdditionalOptions
Any additional options that are needed in the timeline.
Return the first event in the timeline and remove it
StaticgetReturns all of the default options belonging to the class.
A Timeline State. Provides the methods:
setStateAtTime("state", time)andgetValueAtTime(time)Param: initial
The initial state of the StateTimeline. Defaults to
undefined