package email_message
Module Email_message.EmailSource
include Ppx_compare_lib.Comparable.S with type t := t
include Ppx_hash_lib.Hashable.S with type t := t
val create :
headers:Email_message_kernel.Headers.t ->
raw_content:Email_message_kernel__.Email_raw_content.t ->
tval modify_headers :
t ->
f:(Email_message_kernel.Headers.t -> Email_message_kernel.Headers.t) ->
tval to_string_monoid :
?eol_except_raw_content:Email_message_kernel.Lf_or_crlf.t ->
t ->
Email_message_kernel.String_monoid.tString-builder-like module. Small-to-no memory overhead when unparsed.
Convert from string, in compliance with the RFC 2822 standard (standard email format, e.g. .eml but not mbox)
Convert to string, in compliance with the RFC 2822 standard (standard email format, e.g. .eml but not mbox)
val to_bigstring :
?eol_except_raw_content:Email_message_kernel.Lf_or_crlf.t ->
t ->
Core.Bigstring.tinclude Core.Comparable.S_plain with type t := t
include Base.Comparable.S with type t := t
include Base.Comparisons.S with type t := t
ascending is identical to compare. descending x y = ascending y x. These are intended to be mnemonic when used like List.sort ~compare:ascending and List.sort ~cmp:descending, since they cause the list to be sorted in ascending or descending order, respectively.
clamp_exn t ~min ~max returns t', the closest value to t such that between t' ~low:min ~high:max is true.
Raises if not (min <= max).
module Map :
Core.Map.S_plain
with type Key.t = t
with type Key.comparator_witness = comparator_witnessmodule Set :
Core.Set.S_plain
with type Elt.t = t
with type Elt.comparator_witness = comparator_witnessval save :
?temp_file:string ->
?perm:Async.Unix.file_perm ->
?fsync:bool ->
?eol_except_raw_content:Email_message_kernel.Lf_or_crlf.t ->
t ->
string ->
unit Async.Deferred.tEfficiently save t to disk with little additional allocation.
?temp_file, ?perm, ?fsync are blindly passed to Writer.with_file_atomic