From 554c5d6de17264b2e66726eff8569d1fe57ffe92 Mon Sep 17 00:00:00 2001 From: astrojhgu Date: Sat, 22 Aug 2009 17:05:30 +0000 Subject: git-svn-id: file:///home/svn/opt_utilities@50 ed2142bd-67ad-457f-ba7c-d818d4011675 --- misc/data_loaders.hpp | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) (limited to 'misc/data_loaders.hpp') diff --git a/misc/data_loaders.hpp b/misc/data_loaders.hpp index d0f07e7..0347252 100644 --- a/misc/data_loaders.hpp +++ b/misc/data_loaders.hpp @@ -1,3 +1,8 @@ +/** + \file data_loaders.hpp + a set of classes used to load data_set from std::istream + */ + #ifndef DATA_LOADERS_H #define DATA_LOADERS_H #include @@ -17,15 +22,22 @@ namespace opt_utilities template class dl_x_xe_y_ye; + template std::istream& operator>>(std::istream& ifs,dl_x_xe_y_ye& dl); + template class dl_x_xu_xl_y_yu_yl; + template std::istream& operator>> (std::istream& ifs,dl_x_xu_xl_y_yu_yl& dl); + + /** + loading data from file in format [x] [y] [y error] + */ template class dl_x_y_ye { @@ -67,6 +79,11 @@ namespace opt_utilities //friend std::istream& operator>> <>(std::istream& ifs,dl_x_y_ye& dl); }; + + + /** + stream operator + */ template std::istream& operator>>(std::istream& ifs,dl_x_y_ye& dl) { @@ -75,6 +92,11 @@ namespace opt_utilities } + /** + loading data from stream with file + + [x] [x error] [y] [y error] + */ template class dl_x_xe_y_ye { @@ -113,6 +135,10 @@ namespace opt_utilities } }; + + /** + stream operator + */ template std::istream& operator>>(std::istream& ifs,dl_x_xe_y_ye& dl) { @@ -120,6 +146,12 @@ namespace opt_utilities return ifs; } + + /** + loading data from stream with format + + [x] [x lower error] [x upper error] [y] [y lower error] [y upper error] + */ template class dl_x_xu_xl_y_yu_yl { @@ -164,6 +196,10 @@ namespace opt_utilities } }; + + /** + stream operator + */ template std::istream& operator>> (std::istream& ifs,dl_x_xu_xl_y_yu_yl& dl) { -- cgit v1.2.2