EZC3D
Public Member Functions | Protected Attributes | List of all members
ezc3d::DataNS::Frame Class Reference

Frame holder for C3D data. More...

#include <Frame.h>

Public Member Functions

 Frame ()
 Create an empty frame.
 
void print () const
 Print the frame. More...
 
void write (std::fstream &f) const
 Write a frame to an opened file. More...
 
const ezc3d::DataNS::Points3dNS::Pointspoints () const
 Return a reference to all the points. More...
 
ezc3d::DataNS::Points3dNS::Pointspoints_nonConst () const
 Return a reference to all the points in order to be modified by the caller. More...
 
const ezc3d::DataNS::AnalogsNS::Analogsanalogs () const
 Return a reference to all the analogs. More...
 
ezc3d::DataNS::AnalogsNS::Analogsanalogs_nonConst () const
 Return a reference to all the analogs in order to be modified by the caller. More...
 
void add (const ezc3d::DataNS::Frame &frame)
 Add a frame by copying a sent frame. More...
 
void add (const ezc3d::DataNS::Points3dNS::Points &points)
 Add points to a frame. More...
 
void add (const ezc3d::DataNS::AnalogsNS::Analogs &analogs)
 Add analogs to a frame. More...
 
void add (const ezc3d::DataNS::Points3dNS::Points &points, const ezc3d::DataNS::AnalogsNS::Analogs &analogs)
 Add points and analogs to a frame. More...
 
bool isempty () const
 Return if the frame is empty. More...
 

Protected Attributes

std::shared_ptr< ezc3d::DataNS::Points3dNS::Points_points
 All the points for this frame.
 
std::shared_ptr< ezc3d::DataNS::AnalogsNS::Analogs_analogs
 All the subframes for all the analogs.
 

Detailed Description

Frame holder for C3D data.

Definition at line 17 of file Frame.h.

Member Function Documentation

◆ add() [1/4]

void ezc3d::DataNS::Frame::add ( const ezc3d::DataNS::Frame frame)

Add a frame by copying a sent frame.

Parameters
frameThe frame to copy

Definition at line 50 of file Frame.cpp.

◆ add() [2/4]

void ezc3d::DataNS::Frame::add ( const ezc3d::DataNS::Points3dNS::Points points)

Add points to a frame.

Parameters
pointsThe 3D points to add

Definition at line 55 of file Frame.cpp.

◆ add() [3/4]

void ezc3d::DataNS::Frame::add ( const ezc3d::DataNS::AnalogsNS::Analogs analogs)

Add analogs to a frame.

Parameters
analogsThe analogous data to add

Definition at line 60 of file Frame.cpp.

◆ add() [4/4]

void ezc3d::DataNS::Frame::add ( const ezc3d::DataNS::Points3dNS::Points points,
const ezc3d::DataNS::AnalogsNS::Analogs analogs 
)

Add points and analogs to a frame.

Parameters
pointsThe 3D points to add
analogsThe analogous data to add

Definition at line 65 of file Frame.cpp.

◆ analogs()

const ezc3d::DataNS::AnalogsNS::Analogs & ezc3d::DataNS::Frame::analogs ( ) const

Return a reference to all the analogs.

Returns
Reference to all the analogs

Definition at line 40 of file Frame.cpp.

◆ analogs_nonConst()

ezc3d::DataNS::AnalogsNS::Analogs & ezc3d::DataNS::Frame::analogs_nonConst ( ) const

Return a reference to all the analogs in order to be modified by the caller.

Returns
A non-const reference to all the analogs

Get all the analogs in the form of a non-const reference. The user can thereafter modify these analogs at will, but with the caution it requires.

Definition at line 45 of file Frame.cpp.

◆ isempty()

bool ezc3d::DataNS::Frame::isempty ( ) const

Return if the frame is empty.

Returns
if the frame is empty

Definition at line 71 of file Frame.cpp.

◆ points()

const ezc3d::DataNS::Points3dNS::Points & ezc3d::DataNS::Frame::points ( ) const

Return a reference to all the points.

Returns
Reference to all the points

Definition at line 30 of file Frame.cpp.

◆ points_nonConst()

ezc3d::DataNS::Points3dNS::Points & ezc3d::DataNS::Frame::points_nonConst ( ) const

Return a reference to all the points in order to be modified by the caller.

Returns
A non-const reference to all the points

Get all the points in the form of a non-const reference. The user can thereafter modify these points at will, but with the caution it requires.

Definition at line 35 of file Frame.cpp.

◆ print()

void ezc3d::DataNS::Frame::print ( ) const

Print the frame.

Print the frame to the console by calling sequentially the print method for points and analogs

Definition at line 18 of file Frame.cpp.

◆ write()

void ezc3d::DataNS::Frame::write ( std::fstream &  f) const

Write a frame to an opened file.

Parameters
fAlready opened fstream file with write access

Write the frame to a file by calling sequentially the write method for points and analogs

Definition at line 24 of file Frame.cpp.


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