priority

package module
v0.0.0-...-4d703ae Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2024 License: MIT Imports: 4 Imported by: 0

README

go-priority

Manipule the priority of the GO program

Example

import (
    priority "github.com/Codehardt/go-priority"
)

func main() {
    if err := priority.SetPriority(priority.PriorityLow); err != nil {
        ...
    }
    ...
}

Priorities

Priority Unix Windows
PriorityVeryLow 19 IDLE_PRIORITY_CLASS
 PriorityLow 10 BELOW_NORMAL_PRIORITY_CLASS
PriorityMedium 0 NORMAL_PRIORITY_CLASS
 PriorityHigh -10 ABOVE_NORMAL_PRIORITY_CLASS
PriorityVeryHigh -20 HIGH_PRIORITY_CLASS

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetPriority

func SetPriority(priority Priority) error

Types

type Priority

type Priority int

Priority of a process

const (
	PriorityVeryLow Priority = iota
	PriorityLow
	PriorityMedium
	PriorityHigh
	PriorityVeryHigh
)

Jump to

Keyboard shortcuts

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