runtime

package
v0.0.0-...-fab57c2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 15, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package runtime provides a mockable wrapper for runtime.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Impl

type Impl struct{}

func (*Impl) BlockProfile

func (*Impl) BlockProfile(p []runtime.BlockProfileRecord) (n int, ok bool)

func (*Impl) Breakpoint

func (*Impl) Breakpoint()

func (*Impl) CPUProfile

func (*Impl) CPUProfile() []byte

func (*Impl) Caller

func (*Impl) Caller(skip int) (pc uintptr, file string, line int, ok bool)

func (*Impl) Callers

func (*Impl) Callers(skip int, pc []uintptr) int

func (*Impl) CallersFrames

func (*Impl) CallersFrames(callers []uintptr) *runtime.Frames

func (*Impl) FuncForPC

func (*Impl) FuncForPC(pc uintptr) *runtime.Func

func (*Impl) GC

func (*Impl) GC()

func (*Impl) GOMAXPROCS

func (*Impl) GOMAXPROCS(n int) int

func (*Impl) GOROOT

func (*Impl) GOROOT() string

func (*Impl) Goexit

func (*Impl) Goexit()

func (*Impl) GoroutineProfile

func (*Impl) GoroutineProfile(p []runtime.StackRecord) (n int, ok bool)

func (*Impl) Gosched

func (*Impl) Gosched()

func (*Impl) KeepAlive

func (*Impl) KeepAlive(x any)

func (*Impl) LockOSThread

func (*Impl) LockOSThread()

func (*Impl) MemProfile

func (*Impl) MemProfile(p []runtime.MemProfileRecord, inuseZero bool) (n int, ok bool)

func (*Impl) MutexProfile

func (*Impl) MutexProfile(p []runtime.BlockProfileRecord) (n int, ok bool)

func (*Impl) NumCPU

func (*Impl) NumCPU() int

func (*Impl) NumCgoCall

func (*Impl) NumCgoCall() int64

func (*Impl) NumGoroutine

func (*Impl) NumGoroutine() int

func (*Impl) ReadMemStats

func (*Impl) ReadMemStats(m *runtime.MemStats)

func (*Impl) ReadTrace

func (*Impl) ReadTrace() []byte

func (*Impl) SetBlockProfileRate

func (*Impl) SetBlockProfileRate(rate int)

func (*Impl) SetCPUProfileRate

func (*Impl) SetCPUProfileRate(hz int)

func (*Impl) SetCgoTraceback

func (*Impl) SetCgoTraceback(version int, traceback unsafe.Pointer, context unsafe.Pointer, symbolizer unsafe.Pointer)

func (*Impl) SetFinalizer

func (*Impl) SetFinalizer(obj any, finalizer any)

func (*Impl) SetMutexProfileFraction

func (*Impl) SetMutexProfileFraction(rate int) int

func (*Impl) Stack

func (*Impl) Stack(buf []byte, all bool) int

func (*Impl) StartTrace

func (*Impl) StartTrace() error

func (*Impl) StopTrace

func (*Impl) StopTrace()

func (*Impl) ThreadCreateProfile

func (*Impl) ThreadCreateProfile(p []runtime.StackRecord) (n int, ok bool)

func (*Impl) UnlockOSThread

func (*Impl) UnlockOSThread()

func (*Impl) Version

func (*Impl) Version() string

type Interface

type Interface interface {
	BlockProfile(p []runtime.BlockProfileRecord) (n int, ok bool)
	Breakpoint()
	CPUProfile() []byte
	Caller(skip int) (pc uintptr, file string, line int, ok bool)
	Callers(skip int, pc []uintptr) int
	CallersFrames(callers []uintptr) *runtime.Frames
	FuncForPC(pc uintptr) *runtime.Func
	GC()
	GOMAXPROCS(n int) int
	GOROOT() string
	Goexit()
	GoroutineProfile(p []runtime.StackRecord) (n int, ok bool)
	Gosched()
	KeepAlive(x any)
	LockOSThread()
	MemProfile(p []runtime.MemProfileRecord, inuseZero bool) (n int, ok bool)
	MutexProfile(p []runtime.BlockProfileRecord) (n int, ok bool)
	NumCPU() int
	NumCgoCall() int64
	NumGoroutine() int
	ReadMemStats(m *runtime.MemStats)
	ReadTrace() []byte
	SetBlockProfileRate(rate int)
	SetCPUProfileRate(hz int)
	SetCgoTraceback(version int, traceback unsafe.Pointer, context unsafe.Pointer, symbolizer unsafe.Pointer)
	SetFinalizer(obj any, finalizer any)
	SetMutexProfileFraction(rate int) int
	Stack(buf []byte, all bool) int
	StartTrace() error
	StopTrace()
	ThreadCreateProfile(p []runtime.StackRecord) (n int, ok bool)
	UnlockOSThread()
	Version() string
}

Directories

Path Synopsis
Package cgo provides a mockable wrapper for runtime/cgo.
Package cgo provides a mockable wrapper for runtime/cgo.
Package debug provides a mockable wrapper for runtime/debug.
Package debug provides a mockable wrapper for runtime/debug.
Package metrics provides a mockable wrapper for runtime/metrics.
Package metrics provides a mockable wrapper for runtime/metrics.
Package pprof provides a mockable wrapper for runtime/pprof.
Package pprof provides a mockable wrapper for runtime/pprof.
Package trace provides a mockable wrapper for runtime/trace.
Package trace provides a mockable wrapper for runtime/trace.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL