projects
/
cumulus.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Rename --name to --scheme, and store the scheme name in the local database.
[cumulus.git]
/
ref.h
diff --git
a/ref.h
b/ref.h
index
496fdec
..
cc21a5a
100644
(file)
--- a/
ref.h
+++ b/
ref.h
@@
-64,12
+64,16
@@
std::string generate_uuid();
* and converted to and from the text representation. */
class ObjectReference {
public:
* and converted to and from the text representation. */
class ObjectReference {
public:
+ ObjectReference();
ObjectReference(const std::string& segment, int sequence);
ObjectReference(const std::string& segment, int sequence);
+ ObjectReference(const std::string& segment, const std::string& sequence);
std::string to_string() const;
std::string to_string() const;
+ static ObjectReference *parse(const std::string& s);
std::string get_segment() const { return segment; }
std::string get_segment() const { return segment; }
- void set_segment(const std::string& segment) { this->segment = segment; }
+ std::string get_sequence() const { return object; }
+ std::string get_basename() const { return segment + "/" + object; }
bool has_checksum() const { return checksum_valid; }
std::string get_checksum() const { return checksum; }
bool has_checksum() const { return checksum_valid; }
std::string get_checksum() const { return checksum; }