/
event.go
80 lines (68 loc) · 3.09 KB
/
event.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
// Code generated by cdpgen. DO NOT EDIT.
package heapprofiler
import (
"github.com/mafredri/cdp/rpcc"
)
// AddHeapSnapshotChunkClient is a client for AddHeapSnapshotChunk events.
type AddHeapSnapshotChunkClient interface {
// Recv calls RecvMsg on rpcc.Stream, blocks until the event is
// triggered, context canceled or connection closed.
Recv() (*AddHeapSnapshotChunkReply, error)
rpcc.Stream
}
// AddHeapSnapshotChunkReply is the reply for AddHeapSnapshotChunk events.
type AddHeapSnapshotChunkReply struct {
Chunk string `json:"chunk"` // No description.
}
// HeapStatsUpdateClient is a client for HeapStatsUpdate events. If heap
// objects tracking has been started then backend may send update for one or
// more fragments
type HeapStatsUpdateClient interface {
// Recv calls RecvMsg on rpcc.Stream, blocks until the event is
// triggered, context canceled or connection closed.
Recv() (*HeapStatsUpdateReply, error)
rpcc.Stream
}
// HeapStatsUpdateReply is the reply for HeapStatsUpdate events.
type HeapStatsUpdateReply struct {
StatsUpdate []int `json:"statsUpdate"` // An array of triplets. Each triplet describes a fragment. The first integer is the fragment index, the second integer is a total count of objects for the fragment, the third integer is a total size of the objects for the fragment.
}
// LastSeenObjectIDClient is a client for LastSeenObjectID events. If heap
// objects tracking has been started then backend regularly sends a current
// value for last seen object id and corresponding timestamp. If the were
// changes in the heap since last event then one or more heapStatsUpdate events
// will be sent before a new lastSeenObjectId event.
type LastSeenObjectIDClient interface {
// Recv calls RecvMsg on rpcc.Stream, blocks until the event is
// triggered, context canceled or connection closed.
Recv() (*LastSeenObjectIDReply, error)
rpcc.Stream
}
// LastSeenObjectIDReply is the reply for LastSeenObjectID events.
type LastSeenObjectIDReply struct {
LastSeenObjectID int `json:"lastSeenObjectId"` // No description.
Timestamp float64 `json:"timestamp"` // No description.
}
// ReportHeapSnapshotProgressClient is a client for ReportHeapSnapshotProgress events.
type ReportHeapSnapshotProgressClient interface {
// Recv calls RecvMsg on rpcc.Stream, blocks until the event is
// triggered, context canceled or connection closed.
Recv() (*ReportHeapSnapshotProgressReply, error)
rpcc.Stream
}
// ReportHeapSnapshotProgressReply is the reply for ReportHeapSnapshotProgress events.
type ReportHeapSnapshotProgressReply struct {
Done int `json:"done"` // No description.
Total int `json:"total"` // No description.
Finished *bool `json:"finished,omitempty"` // No description.
}
// ResetProfilesClient is a client for ResetProfiles events.
type ResetProfilesClient interface {
// Recv calls RecvMsg on rpcc.Stream, blocks until the event is
// triggered, context canceled or connection closed.
Recv() (*ResetProfilesReply, error)
rpcc.Stream
}
// ResetProfilesReply is the reply for ResetProfiles events.
type ResetProfilesReply struct {
}