package xmlm

  1. Overview
  2. Docs

Module type Xmlm.BufferSource

Input signature for internal buffers.

Sourcetype string

The type for strings.

Sourcetype t

The type for buffers.

Sourceexception Full

Raised if the buffer cannot be grown.

Sourceval create : int -> t

Creates a buffer of the given size.

Sourceval add_uchar : t -> int -> unit

Adds the given (guaranteed valid) unicode code point to a buffer.

Raises Full if the buffer cannot be grown.

Sourceval clear : t -> unit

Clears the buffer.

Sourceval contents : t -> string

Returns the buffer contents.

Sourceval length : t -> int

Returns the number of characters contained in the buffer.