Module Make.Objects

val add_reference : ContainerIdentifier.t -> Eris.urn -> tree -> tree Lwt.t

add_reference continer_id reference tree adds reference to the list of replica objects. You must manually make sure that necessary block references to decode content from reference are added to replica block references. Use add_binary or add for more convenience.

val add_binary : ContainerIdentifier.t -> string -> tree -> (Eris.urn * tree) Lwt.t

add_binary container_id content tree encodes content, stores blocks and block references and adds the object reference to list of relpica objects. Returns the ERIS URN of the encoded content. This is useful for adding binary content to a container.

val add : ContainerIdentifier.t -> FragmentGraph.t -> tree -> (Eris.urn * tree) Lwt.t

add container_id object tree encodes object, stores blocks, adds blocks to block references and adds reference to object to replica object lists. This is useful for adding a fragment graph to the container.

val to_list : ContainerIdentifier.t -> tree -> Eris.urn list Lwt.t
val to_triples : ContainerIdentifier.t -> tree -> Rdf.Triple.t list Lwt.t
val to_datalog_db : ContainerIdentifier.t -> tree -> Datalog.DB.t Lwt.t