summaryrefslogtreecommitdiff
path: root/object-file.h
diff options
context:
space:
mode:
Diffstat (limited to 'object-file.h')
-rw-r--r--object-file.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/object-file.h b/object-file.h
index 15d97630d3..3fd48dcafb 100644
--- a/object-file.h
+++ b/object-file.h
@@ -218,4 +218,20 @@ int read_loose_object(struct repository *repo,
void **contents,
struct object_info *oi);
+struct odb_transaction;
+
+/*
+ * Tell the object database to optimize for adding
+ * multiple objects. object_file_transaction_commit must be called
+ * to make new objects visible. If a transaction is already
+ * pending, NULL is returned.
+ */
+struct odb_transaction *object_file_transaction_begin(struct odb_source *source);
+
+/*
+ * Tell the object database to make any objects from the
+ * current transaction visible.
+ */
+void object_file_transaction_commit(struct odb_transaction *transaction);
+
#endif /* OBJECT_FILE_H */