Guitar
GitObject.h
Go to the documentation of this file.
1 
2 #ifndef GITOBJECT_H
3 #define GITOBJECT_H
4 
5 #include <QByteArray>
6 
7 struct GitObject {
8  enum class Type { // 値は固定。packフォーマットで決まってる
9  NONE = -1,
10  UNKNOWN = 0,
11  COMMIT = 1,
12  TREE = 2,
13  BLOB = 3,
14  TAG = 4,
15  UNDEFINED = 5,
16  OFS_DELTA = 6,
17  REF_DELTA = 7,
18  };
20  QByteArray content;
21  explicit operator bool () const
22  {
23  return type != Type::NONE;
24  }
25 };
26 
27 
28 #endif // GITOBJECT_H
Definition: GitObject.h:7
QByteArray content
Definition: GitObject.h:20
Type type
Definition: GitObject.h:19
Type
Definition: GitObject.h:8