X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fpbd%2Fpbd%2Ffile_manager.h;h=01c9a8ee316cc5e36db6c5746e88dcd5f2f03140;hb=6b1659a29bb9b5c4a31cb0aec371842df0585034;hp=2d3650c2c57bda7cc9e1d46b584fcc87b57246da;hpb=6b19aee3b511eaae2800837175e9b9a931d325e7;p=ardour.git diff --git a/libs/pbd/pbd/file_manager.h b/libs/pbd/pbd/file_manager.h index 2d3650c2c5..01c9a8ee31 100644 --- a/libs/pbd/pbd/file_manager.h +++ b/libs/pbd/pbd/file_manager.h @@ -51,7 +51,10 @@ public: FileDescriptor (std::string const &, bool); virtual ~FileDescriptor () {} + const std::string& path() const { return _path; } + void release (); + virtual void set_path (const std::string&); /** Emitted when the file is closed */ PBD::Signal0 Closed; @@ -71,7 +74,7 @@ protected: int _refcount; ///< number of active users of this file double _last_used; ///< monotonic time that this file was last allocated - std::string _name; ///< filename + std::string _path; ///< file path bool _writeable; ///< true if it should be opened writeable, otherwise false FileManager* manager (); @@ -86,7 +89,7 @@ private: class FdFileDescriptor : public FileDescriptor { public: - FdFileDescriptor (std::string const &, bool, mode_t); + FdFileDescriptor (std::string const & file_name, bool writeable, mode_t mode); ~FdFileDescriptor (); int allocate (); @@ -107,7 +110,7 @@ private: class StdioFileDescriptor : public FileDescriptor { public: - StdioFileDescriptor (std::string const &, std::string const &); + StdioFileDescriptor (std::string const & file_name, std::string const & mode); ~StdioFileDescriptor (); FILE* allocate ();