]> git.ipfire.org Git - thirdparty/git.git/blame - bulk-checkin.h
The twentieth batch
[thirdparty/git.git] / bulk-checkin.h
CommitLineData
568508e7
JH
1/*
2 * Copyright (c) 2011, Google Inc.
3 */
4#ifndef BULK_CHECKIN_H
5#define BULK_CHECKIN_H
6
a6dc3d36 7#include "object.h"
ef3ca954 8
c0f4752e
NS
9void prepare_loose_object_bulk_checkin(void);
10void fsync_loose_object_bulk_checkin(int fd, const char *filename);
11
9eb54197
EB
12int index_blob_bulk_checkin(struct object_id *oid,
13 int fd, size_t size,
14 const char *path, unsigned flags);
568508e7 15
2c23d1b4
NS
16/*
17 * Tell the object database to optimize for adding
18 * multiple objects. end_odb_transaction must be called
19 * to make new objects visible. Transactions can be nested,
20 * and objects are only visible after the outermost transaction
21 * is complete or the transaction is flushed.
22 */
23void begin_odb_transaction(void);
24
25/*
26 * Make any objects that are currently part of a pending object
27 * database transaction visible. It is valid to call this function
28 * even if no transaction is active.
29 */
30void flush_odb_transaction(void);
31
32/*
33 * Tell the object database to make any objects from the
34 * current transaction visible if this is the final nested
35 * transaction.
36 */
37void end_odb_transaction(void);
568508e7
JH
38
39#endif