Impact Acquire SDK C++
ODevFileStreamBuf< CharType, Traits > Class Template Reference

An output stream buffer derived from std::basic_streambuf used to write to a file on a device. More...

#include <mvIMPACT_acquire_GenICam_FileStream.h>

Inheritance diagram for ODevFileStreamBuf< CharType, Traits >:
[legend]

Public Member Functions

filebuf_typeclose (void)
 Closes a file on the device.
 
bool is_open (void) const
 Determines if a file is open.
 
 ODevFileStreamBuf ()
 Constructs a new mvIMPACT::acquire::GenICam::ODevFileStreamBuf object.
 
filebuf_typeopen (mvIMPACT::acquire::Device *pDev, const char *pFileName, std::ios_base::openmode mode)
 Opens a file on the device.
 
 ~ODevFileStreamBuf ()
 class destructor.
 

Protected Member Functions

int_type overflow (int_type c=traits_type::eof())
 
int sync (void)
 
std::streamsize xsputn (const char_type *s, std::streamsize n)
 

Detailed Description

template<typename CharType, typename Traits>
class mvIMPACT::acquire::GenICam::ODevFileStreamBuf< CharType, Traits >

An output stream buffer derived from std::basic_streambuf used to write to a file on a device.

Note
See description of the std::basic_streambuf in a STL implementation of your choice to find out more about how to use this object.

Constructor & Destructor Documentation

◆ ODevFileStreamBuf()

template<typename CharType , typename Traits >
ODevFileStreamBuf ( )
inline

◆ ~ODevFileStreamBuf()

template<typename CharType , typename Traits >
~ODevFileStreamBuf ( )
inline

class destructor.

Member Function Documentation

◆ close()

template<typename CharType , typename Traits >
filebuf_type * close ( void )
inline

Closes a file on the device.

Returns
  • A pointer to itself if successful
  • 0 otherwise

◆ is_open()

template<typename CharType , typename Traits >
bool is_open ( void ) const
inline

Determines if a file is open.

Returns
  • true if the file is open
  • false otherwise

◆ open()

template<typename CharType , typename Traits >
filebuf_type * open ( mvIMPACT::acquire::Device * pDev,
const char * pFileName,
std::ios_base::openmode mode )
inline

Opens a file on the device.

The member function calls rdbuf -> open(_Filename, _Mode | ios_base::in). If open fails, the function calls setstate(failbit), which may throw an ios_base::failure exception.

Parameters
pDevA pointer to a mvIMPACT::acquire::Device object obtained from a mvIMPACT::acquire::DeviceManager object.
pFileNameName of the file to open
modeFile open mode

◆ overflow()

template<typename CharType , typename Traits >
int_type overflow ( int_type c = traits_type::eof())
inlineprotected

◆ sync()

template<typename CharType , typename Traits >
int sync ( void )
inlineprotected

◆ xsputn()

template<typename CharType , typename Traits >
std::streamsize xsputn ( const char_type * s,
std::streamsize n )
inlineprotected