24 #ifndef PSS_ASTROTYPES_SIGPROC_FILEREADER_H
25 #define PSS_ASTROTYPES_SIGPROC_FILEREADER_H
33 namespace astrotypes {
40 template<
typename HeaderType=Header>
57 void open(std::string
const& file_name);
62 template<
typename DataType>
63 typename std::enable_if<has_dimensions<DataType, units::Time, units::Frequency>::value,
FileReader>::type &
69 template<
typename Dimension>
78 void do_open(std::string
const& file_name);
81 std::ifstream _stream;
82 std::string _file_name;
90 #endif // PSS_ASTROTYPES_SIGPROC_FILEREADER_H
std::size_t number_of_data_points() const
the number of data points in the file (i.e number of data points of nbits)
std::enable_if< has_dimensions< DataType, units::Time, units::Frequency >::value, FileReader >::type & operator>>(DataType &data)
read in to the provided data object
void open(std::string const &file_name)
set the filename to read
DimensionSize< Dimension > dimension() const
return the expected dimension of the data in the file
A compile time dimesion tagging of size_t.
void do_open(std::string const &file_name)