Helios++
Helios software for LiDAR simulations
Asset.h
1 #pragma once
2 
3 #include <string>
4 
5 #include <boost/serialization/base_object.hpp>
6 
10 class Asset {
11 
12  friend class boost::serialization::access;
13  template<class Archive>
14  void serialize(Archive &ar, const unsigned int version) {
15  ar & id;
16  ar & name;
17  ar & sourceFilePath;
18  }
19 
20 public:
21  // *** ATTRIBUTES *** //
22  // ******************** //
26  std::string id = "";
30  std::string name = "Unnamed Asset";
34  std::string sourceFilePath = "";
35 
36  // *** CONSTRUCTION / DESTRUCTION *** //
37  // ************************************ //
38  virtual ~Asset() {}
39 
40  // *** GETTERS and SETTERS *** //
41  // ***************************** //
46  std::string getLocationString() {
47  return sourceFilePath + "#" + id;
48  }
49 };
Base class for all assets.
Definition: Asset.h:10
std::string sourceFilePath
Path to asset file.
Definition: Asset.h:34
std::string name
Asset name.
Definition: Asset.h:30
std::string getLocationString()
Obtain asset location string.
Definition: Asset.h:46
std::string id
Asset identifier.
Definition: Asset.h:26