package core
Install
dune-project
Dependency
Authors
Maintainers
Sources
md5=bcac85c0ec5795ccabf1dccf0968ecd9
sha512=2e68556773549e0bf302c8733c9fc57df3c0fd73a1b547dc17097f74c5b5482c816ef89853b437e49452da7c124ef32a8a0de0dff64d71145b2ab11befbe5bb2
doc/core/Core/Bytes/Hexdump/index.html
Module Bytes.HexdumpSource
val to_string_hum :
?max_lines:Base.Int.t ->
?pos:Base.Int.t ->
?len:Base.Int.t ->
t ->
Base.String.tto_string_hum renders t as a multi-line ASCII string in hexdump format. pos and len select a subrange of t to render. max_lines determines the maximum number of lines of hex dump to produce. If the full hex dump exceeds this number, lines in the middle are replaced by a single "..."; the beginning and end of the hex dump are left intact. In order to produce at least some readable hex dump, at least 3 lines are always produced.
val to_sequence :
?max_lines:Base.Int.t ->
?pos:Base.Int.t ->
?len:Base.Int.t ->
t ->
Base.String.t Sequence.tto_sequence produces the lines of to_string_hum as a sequence of strings. This may be useful for incrementally rendering a large hex dump without producing the whole thing in memory. Optional arguments function as in to_string_hum.
[%sexp_of: Hexdump.Pretty.t] is the same as [%sexp_of: Hexdump.t], unless the underlying sequence of characters is entirely printable. In that case, it is rendered directly as a string. This allows e.g. test output to be much more compact in the common (printable) case while still being interpretable for any byte sequence.