SetLimit Class Reference

A manipulator that specifies the maximum number of bytes that can be read/written. More...

#include <DataEncoder.h++>

Inheritance diagram for SetLimit:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 SetLimit (int64_t limit) throw ()
 Construct a new SetLimit manipulator.
 ~SetLimit () throw ()
 Destructor.

Protected Member Functions

void apply (DataEncoder &encoder) const throw (IOException)
 Apply the DataManipulator to a DataEncoder.

Detailed Description

A manipulator that specifies the maximum number of bytes that can be read/written.

Attempts to read/write past this limit will raise an IOException.

Author:
Mark Lindner

Constructor & Destructor Documentation

SetLimit ( int64_t  limit  )  throw ()

Construct a new SetLimit manipulator.

Parameters:
limit The limit, in bytes. A value of 0 indicates no limit.
~SetLimit (  )  throw ()

Destructor.


Member Function Documentation

void apply ( DataEncoder encoder  )  const throw (IOException) [protected, virtual]

Apply the DataManipulator to a DataEncoder.

Parameters:
encoder The target DataEncoder.
Exceptions:
IOException If an I/O error occurs.

Implements Manipulator.


The documentation for this class was generated from the following files:
Generated on Sat Nov 26 16:49:08 2011 for libcommonc++ by  doxygen 1.6.3