package ocp-ocamlres

  1. Overview
  2. Docs
Manipulation, injection and extraction of embedded resources

Install

dune-project
 Dependency

Authors

Maintainers

Sources

v0.4.tar.gz
sha256=658c2990e027e1e43a16290fd431f08c96b8630d91ac2b98003a9bc027179679
md5=725eb557e659c6febf8dc3044b323bd8

doc/ocplib-ocamlres.runtime/OCamlRes/Path/index.html

Module OCamlRes.PathSource

Paths inside resource stores.

Sourcetype t = dirs * name option

A path is a list of directory names and optionally a file name which is itself decomposed into a basename and an optional extension.

Sourceand dirs = string list
Sourceand name = string * ext option
Sourceand ext = string
Sourceval split_ext : string -> string * ext option

Splits the part before and after the first dot after the last slash (if any).

Sourceval split_base : string -> string * string option

Splits the part before and after the last slash (if any).

Sourceval split_dirs : string -> dirs

Splits a string using slashes as separator.

Sourceval shorten : t -> t

Applies ".."s and drops prefix ".."s and "."s.

Sourceval name_of_string : string -> name

Alias for split_ext.

Sourceval string_of_name : name -> string

Inverse of split_ext.

Sourceval of_string : string -> t

Turns a Unix-like path string into a t.

Sourceval to_string : t -> string

Turns a t into a Unix-like formatted path string.

OCaml

Innovation. Community. Security.