X-Git-Url: https://sigrok.org/gitweb/?p=pulseview.git;a=blobdiff_plain;f=pv%2Fdevices%2Finputfile.hpp;h=41698e6d6be45638b7d00f24cb139deb9f2c6f6a;hp=02d4417c99e8af4bb95260e082e543b354bdccdb;hb=dbed5609ae31cdfc3e9db10f3ab91b7607c08372;hpb=519d0ccbe67d005a9c442795ce3b8255e78ca46d diff --git a/pv/devices/inputfile.hpp b/pv/devices/inputfile.hpp index 02d4417c..41698e6d 100644 --- a/pv/devices/inputfile.hpp +++ b/pv/devices/inputfile.hpp @@ -14,8 +14,7 @@ * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + * along with this program; if not, see . */ #ifndef PULSEVIEW_PV_DEVICE_INPUTFILE_HPP @@ -27,19 +26,26 @@ #include "file.hpp" +using std::atomic; +using std::ifstream; +using std::map; +using std::shared_ptr; +using std::streamsize; +using std::string; + namespace pv { namespace devices { class InputFile final : public File { private: - static const std::streamsize BufferSize; + static const streamsize BufferSize; public: - InputFile(const std::shared_ptr &context, - const std::string &file_name, - std::shared_ptr format, - const std::map &options); + InputFile(const shared_ptr &context, + const string &file_name, + shared_ptr format, + const map &options); void open(); @@ -52,12 +58,13 @@ public: void stop(); private: - const std::shared_ptr context_; - const std::shared_ptr format_; - const std::map options_; - std::shared_ptr input_; + const shared_ptr context_; + const shared_ptr format_; + const map options_; + shared_ptr input_; - std::atomic interrupt_; + ifstream *f; + atomic interrupt_; }; } // namespace devices