pond-ts API Reference (core)
Preparing search index...
LiveAggregation
Class LiveAggregation<S, Out>
Type Parameters
S
extends
SeriesSchema
Out
extends
SeriesSchema
=
SeriesSchema
Index
Constructors
constructor
Properties
name
schema
Accessors
closed
Count
has
Open
Bucket
length
Methods
at
closed
cumulative
diff
dispose
fill
filter
map
on
pct
Change
rate
rolling
select
snapshot
window
Constructors
constructor
new
LiveAggregation
<
S
extends
SeriesSchema
,
Out
extends
SeriesSchema
=
SeriesSchema
,
>
(
source
:
LiveSource
<
S
>
,
sequence
:
Sequence
,
mapping
:
AggregateMap
<
S
>
,
options
?:
LiveAggregationOptions
,
)
:
LiveAggregation
<
S
,
Out
>
Type Parameters
S
extends
SeriesSchema
Out
extends
SeriesSchema
=
SeriesSchema
Parameters
source
:
LiveSource
<
S
>
sequence
:
Sequence
mapping
:
AggregateMap
<
S
>
Optional
options
:
LiveAggregationOptions
Returns
LiveAggregation
<
S
,
Out
>
Properties
Readonly
name
name
:
string
Readonly
schema
schema
:
Out
Accessors
closed
Count
get
closedCount
()
:
number
Returns
number
has
Open
Bucket
get
hasOpenBucket
()
:
boolean
Returns
boolean
length
get
length
()
:
number
Returns
number
Methods
at
at
(
index
:
number
)
:
EventForSchema
<
Out
>
|
undefined
Parameters
index
:
number
Returns
EventForSchema
<
Out
>
|
undefined
closed
closed
()
:
TimeSeries
<
Out
>
Returns
TimeSeries
<
Out
>
cumulative
cumulative
<
const
Targets
extends
string
>
(
spec
:
{
[
K
in
string
]
:
|
"sum"
|
"count"
|
"min"
|
"max"
|
(
(
acc
:
number
,
value
:
number
)
=>
number
)
}
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Targets
>
,
]
,
>
Type Parameters
const
Targets
extends
string
Parameters
spec
:
{
[
K
in
string
]
:
|
"sum"
|
"count"
|
"min"
|
"max"
|
(
(
acc
:
number
,
value
:
number
)
=>
number
)
}
Returns
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Targets
>
,
]
,
>
diff
diff
<
const
Target
extends
string
>
(
columns
:
Target
|
readonly
Target
[]
,
options
?:
{
drop
?:
boolean
}
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
Type Parameters
const
Target
extends
string
Parameters
columns
:
Target
|
readonly
Target
[]
Optional
options
:
{
drop
?:
boolean
}
Returns
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
dispose
dispose
()
:
void
Returns
void
fill
fill
(
strategy
:
LiveFillStrategy
|
LiveFillMapping
<
Out
>
,
options
?:
{
limit
?:
number
}
,
)
:
LiveView
<
Out
>
Parameters
strategy
:
LiveFillStrategy
|
LiveFillMapping
<
Out
>
Optional
options
:
{
limit
?:
number
}
Returns
LiveView
<
Out
>
filter
filter
(
predicate
:
(
event
:
EventForSchema
<
Out
>
)
=>
boolean
)
:
LiveView
<
Out
>
Parameters
predicate
:
(
event
:
EventForSchema
<
Out
>
)
=>
boolean
Returns
LiveView
<
Out
>
map
map
(
fn
:
(
event
:
EventForSchema
<
Out
>
)
=>
EventForSchema
<
Out
>
)
:
LiveView
<
Out
>
Parameters
fn
:
(
event
:
EventForSchema
<
Out
>
)
=>
EventForSchema
<
Out
>
Returns
LiveView
<
Out
>
on
on
(
type
:
"event"
,
fn
:
CloseListener
)
:
()
=>
void
Parameters
type
:
"event"
fn
:
CloseListener
Returns
()
=>
void
on
(
type
:
"bucket"
,
fn
:
BucketListener
)
:
this
Parameters
type
:
"bucket"
fn
:
BucketListener
Returns
this
on
(
type
:
"close"
,
fn
:
CloseListener
)
:
this
Parameters
type
:
"close"
fn
:
CloseListener
Returns
this
on
(
type
:
"update"
,
fn
:
UpdateListener
)
:
this
Parameters
type
:
"update"
fn
:
UpdateListener
Returns
this
pct
Change
pctChange
<
const
Target
extends
string
>
(
columns
:
Target
|
readonly
Target
[]
,
options
?:
{
drop
?:
boolean
}
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
Type Parameters
const
Target
extends
string
Parameters
columns
:
Target
|
readonly
Target
[]
Optional
options
:
{
drop
?:
boolean
}
Returns
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
rate
rate
<
const
Target
extends
string
>
(
columns
:
Target
|
readonly
Target
[]
,
options
?:
{
drop
?:
boolean
}
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
Type Parameters
const
Target
extends
string
Parameters
columns
:
Target
|
readonly
Target
[]
Optional
options
:
{
drop
?:
boolean
}
Returns
LiveView
<
readonly
[
Out
[
0
]
,
ReplaceSmoothedColumn
<
ValueColumnsForSchema
<
Out
>
,
Target
>
,
]
,
>
rolling
rolling
(
windowSize
:
RollingWindow
,
mapping
:
AggregateMap
<
Out
>
,
)
:
LiveRollingAggregation
<
Out
>
Parameters
windowSize
:
RollingWindow
mapping
:
AggregateMap
<
Out
>
Returns
LiveRollingAggregation
<
Out
>
select
select
<
const
Keys
extends
readonly
(
keyof
EventDataForSchema
<
Out
>
)
[]
>
(
...
keys
:
Keys
,
)
:
LiveView
<
readonly
[
Out
[
0
]
,
PickSelectedColumns
<
ValueColumnsForSchema
<
Out
>
,
Keys
[
number
]
>
,
]
,
>
Type Parameters
const
Keys
extends
readonly
(
keyof
EventDataForSchema
<
Out
>
)
[]
Parameters
...
keys
:
Keys
Returns
LiveView
<
readonly
[
Out
[
0
]
,
PickSelectedColumns
<
ValueColumnsForSchema
<
Out
>
,
Keys
[
number
]
>
,
]
,
>
snapshot
snapshot
()
:
TimeSeries
<
Out
>
Returns
TimeSeries
<
Out
>
window
window
(
size
:
RollingWindow
)
:
LiveView
<
Out
>
Parameters
size
:
RollingWindow
Returns
LiveView
<
Out
>
Settings
Member Visibility
Inherited
External
Theme
OS
Light
Dark
On This Page
Constructors
constructor
Properties
name
schema
Accessors
closed
Count
has
Open
Bucket
length
Methods
at
closed
cumulative
diff
dispose
fill
filter
map
on
pct
Change
rate
rolling
select
snapshot
window
pond-ts API Reference (core)
Loading...