priority

package module
v0.0.0-...-2832d4e Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2023 License: MIT Imports: 1 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