Flexiv RDK APIs  1.7.0
file_io.hpp
Go to the documentation of this file.
1 
6 #ifndef FLEXIV_RDK_FILE_IO_HPP_
7 #define FLEXIV_RDK_FILE_IO_HPP_
8 
9 #include "robot.hpp"
10 
11 namespace flexiv {
12 namespace rdk {
13 
18 class FileIO
19 {
20 public:
26  FileIO(const Robot& robot);
27  virtual ~FileIO();
28 
35  std::vector<std::string> traj_files_list() const;
36 
48  void UploadTrajFile(const std::string& file_dir, const std::string& file_name);
49 
59  std::string DownloadTrajFile(const std::string& file_name);
60 
72  void DownloadTrajFile(const std::string& file_name, const std::string& save_dir);
73 
74 private:
75  class Impl;
76  std::unique_ptr<Impl> pimpl_;
77 };
78 
79 } /* namespace rdk */
80 } /* namespace flexiv */
81 
82 #endif /* FLEXIV_RDK_FILE_IO_HPP_ */
Interface to exchange files with the robot. Only certain types of file can be transferred.
Definition: file_io.hpp:19
std::string DownloadTrajFile(const std::string &file_name)
[Blocking] Download a trajectory file (.traj) from the robot.
void UploadTrajFile(const std::string &file_dir, const std::string &file_name)
[Blocking] Upload a trajectory file (.traj) to the robot.
std::vector< std::string > traj_files_list() const
[Blocking] A list of all trajectory files currently stored in the connected robot.
FileIO(const Robot &robot)
[Non-blocking] Instantiate the file exchange interface.
void DownloadTrajFile(const std::string &file_name, const std::string &save_dir)
[Blocking] Download a trajectory file (.traj) from the robot and save to the specified directory.
Main interface to control the robot, containing several function categories and background services.
Definition: robot.hpp:25