package biocaml
Install
dune-project
Dependency
Authors
Maintainers
Sources
md5=497e3f2f7128a6ca347d66848da38a3d
sha512=4a76ebbafda3bc944afaff40d69791dfe153a0638ef5d7e6e1bc962b7f991d9545cd0af2d7930b39f8b31dbf067d0603cfa03d9b7a49396ab1ae452df47fd1f3
doc/biocaml.base/Biocaml_base/Line/index.html
Module Biocaml_base.Line
Single line of text. See also Lines.
type t = private Base.stringA line is simply a string, possibly empty, that does not contain a newline character. As the name suggests, usually such strings are obtained by reading a file line by line.
val empty : tval parse_string : Base.string -> t Base.listparse_string s splits s on newline characters, returning the resulting list of lines. If the final line ended with a newline, the last string of the list is empty.
val rightmost : Base.string -> Base.string Base.option * trightmost s returns a pair whose right member is the longest suffix v of s that represents a line, while the possible remainder of s (minus the newline character) is represented in the left member. More formally, if v = s then the left member of the pair is None; otherwise it is Some u where s = u ^ "\n" ^ v.
val to_string : t -> Base.stringval of_string_unsafe : Base.string -> tReturn the given string without checking that it is a line. Useful for efficiency reasons if you're certain the given string is a line.
Standard String Operations
val split : t -> on:Base.char -> Base.string Base.listval for_all : Base.string -> f:(Base.char -> Base.bool) -> Base.boolS-Expressions
val t_of_sexp : Base.Sexp.t -> tval sexp_of_t : t -> Base.Sexp.t