unix-2.4.2.0: POSIX functionality

Portability | non-portable (requires POSIX)
Stability | provisional
Maintainer | libraries@haskell.org

System.Posix.Resource

Contents

- Resource Limits

Description

POSIX resource support

Synopsis

- data ResourceLimit
  - = ResourceLimitInfinity
  - | ResourceLimitUnknown
  - | ResourceLimit Integer
- data ResourceLimits = ResourceLimits {
  - softLimit :: ResourceLimit
  - hardLimit :: ResourceLimit
  }
- data Resource
  - = ResourceCoreFileSize
  - | ResourceCPUTime
  - | ResourceDataSize
  - | ResourceFileSize
  - | ResourceOpenFiles
  - | ResourceStackSize
  - | ResourceTotalMemory
- getResourceLimit :: Resource -> IO ResourceLimits
- setResourceLimit :: Resource -> ResourceLimits -> IO ()

# Resource Limits

data ResourceLimit Source

Constructors

ResourceLimitInfinity |
ResourceLimitUnknown |
ResourceLimit Integer |

Instances

Eq ResourceLimit |

data ResourceLimits Source

Constructors

ResourceLimits |

Fields

softLimit :: ResourceLimit
hardLimit :: ResourceLimit

Instances

Eq ResourceLimits |

data Resource Source

Constructors

ResourceCoreFileSize |
ResourceCPUTime |
ResourceDataSize |
ResourceFileSize |
ResourceOpenFiles |
ResourceStackSize |
ResourceTotalMemory |

Instances

Eq Resource |

getResourceLimit :: Resource -> IO ResourceLimits Source

setResourceLimit :: Resource -> ResourceLimits -> IO ()Source