#ifndef GENERS_RECORD_HH_ #define GENERS_RECORD_HH_ #include "geners/ArchiveRecord.hh" namespace gs { template inline ArchiveRecord Record(const T& object, const char* name, const char* category) { return ArchiveRecord(object, name, category); } #ifndef SWIG template inline ArchiveRecord Record(const T& object, const std::string& name, const char* category) { return ArchiveRecord(object, name.c_str(), category); } template inline ArchiveRecord Record(const T& object, const char* name, const std::string& category) { return ArchiveRecord(object, name, category.c_str()); } template inline ArchiveRecord Record(const T& object, const std::string& name, const std::string& category) { return ArchiveRecord(object, name.c_str(), category.c_str()); } #endif // // ValueRecord makes a copy of the object and stores it internally // template inline ArchiveValueRecord ValueRecord(const T& object, const char* name, const char* category) { return ArchiveValueRecord(object, name, category); } #ifndef SWIG template inline ArchiveValueRecord ValueRecord(const T& object, const std::string& name, const char* category) { return ArchiveValueRecord(object, name.c_str(), category); } template inline ArchiveValueRecord ValueRecord(const T& object, const char* name, const std::string& category) { return ArchiveValueRecord(object, name, category.c_str()); } template inline ArchiveValueRecord ValueRecord(const T& object, const std::string& name, const std::string& category) { return ArchiveValueRecord(object, name.c_str(), category.c_str()); } #endif } #endif // GENERS_RECORD_HH_