ulimit

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Nov 3, 2015 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package ulimit provides structure and helper function to parse and represent resource limits (Rlimit and Ulimit, its human friendly version).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Rlimit

type Rlimit struct {
	Type int    `json:"type,omitempty"`
	Hard uint64 `json:"hard,omitempty"`
	Soft uint64 `json:"soft,omitempty"`
}

Rlimit specifies the resource limits, such as max open files.

type Ulimit

type Ulimit struct {
	Name string
	Hard int64
	Soft int64
}

Ulimit is a human friendly version of Rlimit.

func Parse

func Parse(val string) (*Ulimit, error)

Parse parses and returns a Ulimit from the specified string.

func (*Ulimit) GetRlimit

func (u *Ulimit) GetRlimit() (*Rlimit, error)

GetRlimit returns the RLimit corresponding to Ulimit.

func (*Ulimit) String

func (u *Ulimit) String() string

Jump to

Keyboard shortcuts

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