Permalink
Browse files

doc: improve documentation of Bed's API

  • Loading branch information...
1 parent 5d19bd1 commit b553d45f1ac442ee9e7ee4efc1b24cd252d750f9 @smondet smondet committed Feb 26, 2013
Showing with 19 additions and 12 deletions.
  1. +2 −6 Makefile
  2. +17 −6 src/lib/biocaml_bed.mli
View
@@ -32,18 +32,14 @@ _build/doclib/index.html: setup.data build _build/doclib/biocaml.css _build/bioh
# This a "fast-compiling" sample of the documentation for testing purposes.
DOC_SAMPLES=_build/src/lib/biocaml_about.ml \
_build/src/lib/biocaml_streamable.ml \
- _build/src/lib/biocaml_stream.mli _build/src/lib/biocaml_stream.ml \
+ _build/src/lib/biocaml_bed.mli _build/src/lib/biocaml_bed.ml \
_build/src/lib/biocaml_transform.mli _build/src/lib/biocaml_transform.ml
_build/biohtml.cmo: src/odoc/biohtml.ml
ocamlfind ocamlc -c src/odoc/biohtml.ml -o $@ -I +ocamldoc -I +compiler-libs
-#ocamlc -c src/odoc/biohtml.ml -o $@ -I +ocamldoc -I +ocamldoc/custom
-
-
-
-doctest: setup.data _build/doclib/biocaml.css _build/biohtml.cmo
+doctest: setup.data _build/doclib/biocaml.css _build/biohtml.cmo build
mkdir -p _build/doclib
cp src/doc/figures/* _build/doclib/
ocamlfind ocamldoc \
View
@@ -1,4 +1,6 @@
-(** BED data. A BED file is in the format shown below, where columns
+(** BED data files.
+
+ A BED file is in the format shown below, where columns
must be separted by a tab character.
{v
@@ -29,18 +31,23 @@
*)
type item = string * int * int * Biocaml_table.Row.t
-with sexp
(** The type of BED data stream items. *)
+val item_of_sexp : Sexplib.Sexp.t -> item
+val sexp_of_item : item -> Sexplib.Sexp.t
+
type parsing_spec = [
| `enforce of Biocaml_table.Row.t_type
| `strings
]
-with sexp
(** The specification of how to parse the remaining columns. *)
-(** Definitions of error types ([with sexp]) *)
+val parsing_spec_of_sexp : Sexplib.Sexp.t -> parsing_spec
+val sexp_of_parsing_spec : parsing_spec -> Sexplib.Sexp.t
+
+
module Error: sig
+ (** Definitions of error types ([with sexp]) *)
type parsing_base = [
| `wrong_format of
@@ -49,10 +56,13 @@ module Error: sig
| `int_of_string of string ] *
Biocaml_table.Row.t_type * string
| `wrong_number_of_columns of Biocaml_table.Row.t ]
- with sexp
type parsing = [ `bed of parsing_base ]
- with sexp
+
+ val parsing_base_of_sexp : Sexplib.Sexp.t -> parsing_base
+ val sexp_of_parsing_base : parsing_base -> Sexplib.Sexp.t
+ val parsing_of_sexp : Sexplib.Sexp.t -> parsing
+ val sexp_of_parsing : parsing -> Sexplib.Sexp.t
end
@@ -64,6 +74,7 @@ val item_to_line: item -> Biocaml_lines.item
(** Basic “printing” of one single [item]. *)
module Transform: sig
+ (** Lower-level transforms of BED data-streams. *)
val string_to_item :
?more_columns:parsing_spec ->

0 comments on commit b553d45

Please sign in to comment.