Up

module Search

: sig

Search over the Git objects

#
type succ = [
| `Commit of SHA.t
| `Tag of string * SHA.t
| `Tree of string * SHA.t
]

Value.t successors.

#
val sha1_of_succ : succ -> SHA.t

Return the SHA of the successor value.

#
module Make : functor (S : Store.S) -> sig
#
type path = string list

A path can cross different type of Git object boundaries. By convention, the empty string "" denotes a Commit.t to Tree.t transition, so that mem head ["";"a";"b"] will look into the Tree/Blob object located under a/b for the head revision.

#
val succ : S.t -> SHA.t -> succ list Lwt.t

Compute the successor values.

#
val mem : S.t -> SHA.t -> string list -> bool Lwt.t

mem t sha1 path check wether we can go from the object named sha1 to an other object following the path labels.

#
val find : S.t -> SHA.t -> string list -> SHA.t option Lwt.t

find t sha1 path returns (if it exists) the object named sha1 to an other object following the path labels.

#
val find_exn : S.t -> SHA.t -> string list -> SHA.t Lwt.t

find t sha1 path returns (if it exists) the object named sha1 to an other object following the path labels. Raise Not_found if no such object exist.

end
end