Tekkotsu Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

ROBOOP::IO_matrix_file Class Reference

#include <gnugraph.h>

Inheritance diagram for ROBOOP::IO_matrix_file:

List of all members.


Detailed Description

Read and write data at every iterations in a file.

Definition at line 165 of file gnugraph.h.


Public Member Functions

 IO_matrix_file (const std::string &filename)
 Constructor.
short write (const std::vector< Matrix > &data)
 Write data on disk using a default data name..
short write (const std::vector< Matrix > &data, const std::vector< std::string > &title)
 Write data on disk.
short read (std::vector< Matrix > &data)
 Read one sequence of data per call.
short read (std::vector< Matrix > &data, std::vector< std::string > &title)
 Read one sequence of data per call.
short read_all (std::vector< Matrix > &data, std::vector< std::string > &data_title)
 Reads all sequences of data.

Private Attributes

int position_read
 Position to read the file.
int nb_iterations_write
 Number of iterations in writing mode.
int nb_iterations_read
 Number of iterations in reading mode.
int nb_element
 Number of elements to read or write.
std::string filename
 File name.

Constructor & Destructor Documentation

ROBOOP::IO_matrix_file::IO_matrix_file ( const std::string &  filename  ) 

Constructor.

Definition at line 336 of file gnugraph.cpp.


Member Function Documentation

short ROBOOP::IO_matrix_file::write ( const std::vector< Matrix > &  data  ) 

Write data on disk using a default data name..

Definition at line 347 of file gnugraph.cpp.

short ROBOOP::IO_matrix_file::write ( const std::vector< Matrix > &  data,
const std::vector< std::string > &  title 
)

Write data on disk.

Parameters:
data,: Data.
title,: Name of each data member (ie: speed, position, ...)

Definition at line 363 of file gnugraph.cpp.

short ROBOOP::IO_matrix_file::read ( std::vector< Matrix > &  data  ) 

Read one sequence of data per call.

Definition at line 456 of file gnugraph.cpp.

short ROBOOP::IO_matrix_file::read ( std::vector< Matrix > &  data,
std::vector< std::string > &  title 
)

Read one sequence of data per call.

Definition at line 472 of file gnugraph.cpp.

short ROBOOP::IO_matrix_file::read_all ( std::vector< Matrix > &  data,
std::vector< std::string > &  data_title 
)

Reads all sequences of data.

If the file "filename does not exist yet, created it and fill the first line with the number of rows and columns for each element of "data". ex: 6x1;3x1;3x3; This line indidate that data has 3 elements Matrix. The first one has 6 rows and 1 columns, the second one has 3 rows and 1 columns ...

Definition at line 542 of file gnugraph.cpp.

Referenced by ROBOOP::Plot_file::Plot_file().


Member Data Documentation

Position to read the file.

Definition at line 175 of file gnugraph.h.

Referenced by IO_matrix_file(), and read().

Number of iterations in writing mode.

Definition at line 175 of file gnugraph.h.

Referenced by IO_matrix_file(), and write().

Number of iterations in reading mode.

Definition at line 175 of file gnugraph.h.

Referenced by IO_matrix_file(), read(), and read_all().

Number of elements to read or write.

Definition at line 175 of file gnugraph.h.

Referenced by IO_matrix_file(), read(), and read_all().

std::string ROBOOP::IO_matrix_file::filename [private]

File name.

Definition at line 179 of file gnugraph.h.

Referenced by IO_matrix_file(), read(), read_all(), and write().


The documentation for this class was generated from the following files:

ROBOOP v1.21a
Generated Thu Nov 22 00:51:35 2007 by Doxygen 1.5.4