gops

package
v0.0.0-...-3744b1b Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2018 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ProcInfo

type ProcInfo struct {
	Pid  int     `json:"pid"`
	Pids []int   `json:"pids"`
	Rss  int     `json:"rss"`
	PCpu float64 `json:"pcpu"`
}

func (*ProcInfo) Add

func (pi *ProcInfo) Add(add ProcInfo)

type Process

type Process struct {
	mps.Process
}

func NewProcess

func NewProcess(pid int) (p Process, err error)

func (*Process) Children

func (p *Process) Children(recursive bool) (cps []Process)

Get all child process

func (*Process) ChildrenProcInfo

func (p *Process) ChildrenProcInfo(recursive bool) (pi ProcInfo)

Sum everything

func (*Process) ProcInfo

func (p *Process) ProcInfo() (pi ProcInfo, err error)

CPU Percent * 100 only linux and darwin works

Jump to

Keyboard shortcuts

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