Source

ocaml-stringpainter / src / Prioritized.mli

Full commit
(*********************************************************************************************************************
 * Copyrights (C) by
 *  Pawel Wieczorek <wieczyk gmail>
 *
 * http://bitbucket.org/wieczyk/ocaml-stringpainter
 ********************************************************************************************************************)

type painter

type associativity
    = LeftAssociative
    | RightAssociative
    | NoAssociative

val get_priority : painter -> int

val get_painter :  painter -> Basic.painter

val psp_nested : int -> painter list -> painter

val psp_indent : int->  painter list -> painter

val psp_reprioritize : int -> painter -> painter

val psp_max_priority : int

val psp_break : painter

val psp_newline : painter

val psp_word : string -> painter

val psp_keyword : string -> painter

val psp_value : string -> painter

val psp_value_keyword : string -> painter

val psp_operator : string -> painter

val psp_syntax : string -> painter

val psp_value_int : int -> painter

val psp_value_bool : bool -> painter

val psp_bracket : painter -> painter -> int -> painter -> painter

val psp_std_bracket : painter -> painter

val psp_square_bracket : painter -> painter

val psp_no_bracket : painter -> painter

val psp_decide_bracket : (painter -> painter) -> bool -> painter -> painter

val psp_decide_std_bracket : bool -> painter -> painter

val psp_associative_infix : (int -> int -> bool) -> (int -> int -> bool) -> int
                         -> painter -> painter -> painter -> painter

val psp_left_associative_infix : int -> painter -> painter -> painter -> painter

val psp_right_associative_infix : int -> painter -> painter -> painter -> painter

val psp_no_associative_infix : int -> painter -> painter -> painter -> painter

val psp_infix : associativity -> int -> painter -> painter -> painter -> painter

val print_painter_nl  : painter -> unit

val print_painter     : painter -> unit

val render_painter    : painter -> string