Documentation
¶
Index ¶
- func FormatStackWithNumbers(stack []string) string
- type Direction
- type FlameView
- func (f *FlameView) BuildFromRows(rows *sql.Rows) error
- func (f *FlameView) Draw(screen tcell.Screen)
- func (f *FlameView) GetTotalCount() int
- func (f *FlameView) SetData(data string)
- func (f *FlameView) SetDirection(d Direction)
- func (f *FlameView) SetFrameHandler(handler FrameHandler)
- func (f *FlameView) SetPageSwitcher(switcher PageSwitcherFunc)
- func (f *FlameView) SetSourcePage(sourcePage string)
- type FocusedFrame
- type Frame
- type FrameHandler
- type PageSwitcherFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FormatStackWithNumbers ¶
FormatStackWithNumbers adds numbering to each frame in the stack
Types ¶
type FlameView ¶
FlameView is a custom tview widget for drawing flamegraphs.
func NewFlamegraphView ¶
func NewFlamegraphView() *FlameView
NewFlamegraphView creates a new instance of the flamegraph widget. Default direction is top-down.
func (*FlameView) BuildFromRows ¶
BuildFromRows builds the flamegraph tree directly from database rows. This avoids the need to write to and read from temporary files.
func (*FlameView) GetTotalCount ¶
func (*FlameView) SetDirection ¶
SetDirection sets the drawing direction of the flamegraph.
func (*FlameView) SetFrameHandler ¶
func (f *FlameView) SetFrameHandler(handler FrameHandler)
SetFrameHandler sets the handler function for frame selection events.
func (*FlameView) SetPageSwitcher ¶
func (f *FlameView) SetPageSwitcher(switcher PageSwitcherFunc)
SetPageSwitcher sets the function that will be called to switch pages
func (*FlameView) SetSourcePage ¶
SetSourcePage sets the name of the page that opened this flamegraph
type FocusedFrame ¶
type FocusedFrame struct {
// contains filtered or unexported fields
}
FocusedFrame represents a frame that currently has focus.
type FrameHandler ¶
FrameHandler is a function that handles frame selection events. It receives the full stack trace from root to the selected frame, the count, and the level/position of the selected frame in the stack (0-based index).
type PageSwitcherFunc ¶
type PageSwitcherFunc func(targetPage string)
PageSwitcherFunc is a function that switches to a specified page