std::string get_segment() const { return segment; }
std::string get_sequence() const { return object; }
std::string get_basename() const { return segment + "/" + object; }
+ ObjectReference base() const { return ObjectReference(segment, object); }
bool has_checksum() const { return checksum_valid; }
std::string get_checksum() const { return checksum; }
bool merge(ObjectReference ref);
+ // Maybe provide non-string implementations?
+ bool operator==(const ObjectReference &x) const
+ { return to_string() == x.to_string(); }
+ bool operator<(const ObjectReference &x) const
+ { return to_string() < x.to_string(); }
+
private:
RefType type;
std::string segment, object, checksum;