package luv

  1. Overview
  2. Docs
Binding to libuv: cross-platform asynchronous I/O

Install

Dune Dependency

Authors

Maintainers

Sources

luv-0.5.7.tar.gz
sha256=c0085224ae2025a2aae9c69f542450974bdbfea592fed6c3d4df361f73e15672
md5=ca1a2de9a100a8d2f2d9fcf2e1b5bd8c

doc/luv/Luv/Rwlock/index.html

Module Luv.RwlockSource

Read-write locks.

See Read-write locks in libuv.

Sourcetype t
Sourceval init : unit -> (t, Error.t) Result.result

Allocates and initializes a read-write lock.

Binds uv_rwlock_init. See pthread_rwlock_init(3p).

Sourceval destroy : t -> unit

Cleans up a read-write lock.

Binds uv_rwlock_destroy. See pthread_rwlock_destroy(3p).

Sourceval rdlock : t -> unit

Takes a read-write lock for reading (shared access).

Binds uv_rwlock_rdlock. See pthread_rwlock_rdlock(3p).

Sourceval tryrdlock : t -> (unit, Error.t) Result.result

Tries to take a read-write lock for reading without blocking.

Binds uv_rwlock_tryrdlock. See pthread_rwlock_tryrdlock(3p).

Sourceval rdunlock : t -> unit

Releases a read-write lock after it was taken for reading.

Binds uv_rwlock_rdunlock. See pthread_rwlock_unlock(3p).

Sourceval wrlock : t -> unit

Takes a read-write lock for writing (exclusive access).

Binds uv_rwlock_wrlock. See pthread_rwlock_wrlock(3p).

Sourceval trywrlock : t -> (unit, Error.t) Result.result

Tries to take a read-write lock for writing without blocking.

Binds uv_rwlock_trywrlock. pthread_rwlock_trywrlock(3p).

Sourceval wrunlock : t -> unit

Releases a read-write lock after it was taken for writing.

Binds uv_rwlock_wrunlock. See pthread_rwlock_unlock(3p).

OCaml

Innovation. Community. Security.