📄 class_buffered_transformation.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"><title>Crypto++: BufferedTransformation Class Reference</title><link href="doxygen.css" rel="stylesheet" type="text/css"><link href="tabs.css" rel="stylesheet" type="text/css"></head><body><!-- Generated by Doxygen 1.5.2 --><div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li class="current"><a href="classes.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> </ul></div><div class="tabs"> <ul> <li><a href="classes.html"><span>Alphabetical List</span></a></li> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul></div><h1>BufferedTransformation Class Reference</h1><!-- doxytag: class="BufferedTransformation" --><!-- doxytag: inherits="Algorithm,Waitable" --><code>#include <<a class="el" href="cryptlib_8h-source.html">cryptlib.h</a>></code><p><p>Inheritance diagram for BufferedTransformation:<p><center><img src="class_buffered_transformation.png" usemap="#BufferedTransformation_map" border="0" alt=""></center><map name="BufferedTransformation_map"><area href="class_algorithm.html" alt="Algorithm" shape="rect" coords="540,56,890,80"><area href="class_waitable.html" alt="Waitable" shape="rect" coords="900,56,1250,80"><area href="class_clonable.html" alt="Clonable" shape="rect" coords="540,0,890,24"><area href="class_auto_signaling.html" alt="AutoSignaling< BufferedTransformation >" shape="rect" coords="0,168,350,192"><area href="class_bufferless.html" alt="Bufferless< BufferedTransformation >" shape="rect" coords="360,168,710,192"><area href="class_filter.html" alt="Filter" shape="rect" coords="720,168,1070,192"><area href="class_input_rejecting.html" alt="InputRejecting< BufferedTransformation >" shape="rect" coords="1440,168,1790,192"><area href="class_sink.html" alt="Sink" shape="rect" coords="2160,168,2510,192"><area href="class_message_queue.html" alt="MessageQueue" shape="rect" coords="0,224,350,248"><area href="class_byte_queue.html" alt="ByteQueue" shape="rect" coords="360,224,710,248"><area href="class_auto_signaling.html" alt="AutoSignaling< Filter >" shape="rect" coords="1080,224,1430,248"><area href="class_bufferless.html" alt="Bufferless< Filter >" shape="rect" coords="1080,280,1430,304"><area href="class_custom_flush_propagation.html" alt="CustomFlushPropagation< Filter >" shape="rect" coords="1080,336,1430,360"><area href="class_encoded_object_filter.html" alt="EncodedObjectFilter" shape="rect" coords="1080,392,1430,416"><area href="class_filter_with_buffered_input.html" alt="FilterWithBufferedInput" shape="rect" coords="1080,448,1430,472"><area href="class_filter_with_input_queue.html" alt="FilterWithInputQueue" shape="rect" coords="1080,504,1430,528"><area href="class_input_rejecting.html" alt="InputRejecting< Filter >" shape="rect" coords="1080,560,1430,584"><area href="class_low_first_bit_writer.html" alt="LowFirstBitWriter" shape="rect" coords="1080,616,1430,640"><area href="class_unflushable.html" alt="Unflushable< Filter >" shape="rect" coords="1080,672,1430,696"><area href="class_auto_signaling.html" alt="AutoSignaling< InputRejecting< BufferedTransformation > >" shape="rect" coords="1800,224,2150,248"><area href="class_byte_queue_1_1_walker.html" alt="ByteQueue::Walker" shape="rect" coords="1800,280,2150,304"><area href="class_bufferless.html" alt="Bufferless< Sink >" shape="rect" coords="2520,224,2870,248"><area href="class_custom_flush_propagation.html" alt="CustomFlushPropagation< Sink >" shape="rect" coords="2520,280,2870,304"><area href="class_file_sink.html" alt="FileSink" shape="rect" coords="2520,336,2870,360"><area href="class_nonblocking_sink.html" alt="NonblockingSink" shape="rect" coords="2520,392,2870,416"><area href="class_unflushable.html" alt="Unflushable< Sink >" shape="rect" coords="2520,448,2870,472"></map><a href="class_buffered_transformation-members.html">List of all members.</a><hr><a name="_details"></a><h2>Detailed Description</h2>interface for buffered transformations <p><a class="el" href="class_buffered_transformation.html" title="interface for buffered transformations">BufferedTransformation</a> is a generalization of <a class="el" href="class_block_transformation.html" title="interface for the data processing part of block ciphers">BlockTransformation</a>, <a class="el" href="class_stream_transformation.html" title="interface for the data processing part of stream ciphers">StreamTransformation</a>, and <a class="el" href="class_hash_transformation.html" title="interface for hash functions and data processing part of MACs">HashTransformation</a>.<p>A buffered transformation is an object that takes a stream of bytes as input (this may be done in stages), does some computation on them, and then places the result into an internal buffer for later retrieval. Any partial result already in the output buffer is not modified by further input.<p>If a method takes a "blocking" parameter, and you pass "false" for it, the method will return before all input has been processed if the input cannot be processed without waiting (for network buffers to become available, for example). In this case the method will return true or a non-zero integer value. When this happens you must continue to call the method with the same parameters until it returns false or zero, before calling any other method on it or attached <a class="el" href="class_buffered_transformation.html" title="interface for buffered transformations">BufferedTransformation</a>. The integer return value in this case is approximately the number of bytes left to be processed, and can be used to implement a progress bar.<p>For functions that take a "propagation" parameter, propagation != 0 means pass on the signal to attached <a class="el" href="class_buffered_transformation.html" title="interface for buffered transformations">BufferedTransformation</a> objects, with propagation decremented at each step until it reaches 0. -1 means unlimited propagation. <p><p>Definition at line <a class="el" href="cryptlib_8h-source.html#l00724">724</a> of file <a class="el" href="cryptlib_8h-source.html">cryptlib.h</a>.<table border="0" cellpadding="0" cellspacing="0"><tr><td></td></tr><tr><td colspan="2"><br><h2>INPUT</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="e70658b0d271f8e114ac6c3cc9774ede"></a><!-- doxytag: member="BufferedTransformation::Put" ref="e70658b0d271f8e114ac6c3cc9774ede" args="(byte inByte, bool blocking=true)" -->size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#e70658b0d271f8e114ac6c3cc9774ede">Put</a> (byte inByte, bool blocking=true)</td></tr><tr><td class="mdescLeft"> </td><td class="mdescRight">input a byte for processing <br></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="44e935e60d3877975a7c82c6353d65c9"></a><!-- doxytag: member="BufferedTransformation::Put" ref="44e935e60d3877975a7c82c6353d65c9" args="(const byte *inString, size_t length, bool blocking=true)" -->size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#44e935e60d3877975a7c82c6353d65c9">Put</a> (const byte *inString, size_t length, bool blocking=true)</td></tr><tr><td class="mdescLeft"> </td><td class="mdescRight">input multiple bytes <br></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="92c60616792d7bce5cd41eaffbd1c3cc"></a><!-- doxytag: member="BufferedTransformation::PutWord16" ref="92c60616792d7bce5cd41eaffbd1c3cc" args="(word16 value, ByteOrder order=BIG_ENDIAN_ORDER, bool blocking=true)" -->size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#92c60616792d7bce5cd41eaffbd1c3cc">PutWord16</a> (word16 value, <a class="el" href="cryptlib_8h.html#aeb92d42f5a6e27b8ba19f18d69d142b">ByteOrder</a> order=BIG_ENDIAN_ORDER, bool blocking=true)</td></tr><tr><td class="mdescLeft"> </td><td class="mdescRight">input a 16-bit word <br></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="ffcc574867d51528afe3c96721ded075"></a><!-- doxytag: member="BufferedTransformation::PutWord32" ref="ffcc574867d51528afe3c96721ded075" args="(word32 value, ByteOrder order=BIG_ENDIAN_ORDER, bool blocking=true)" -->size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#ffcc574867d51528afe3c96721ded075">PutWord32</a> (word32 value, <a class="el" href="cryptlib_8h.html#aeb92d42f5a6e27b8ba19f18d69d142b">ByteOrder</a> order=BIG_ENDIAN_ORDER, bool blocking=true)</td></tr><tr><td class="mdescLeft"> </td><td class="mdescRight">input a 32-bit word <br></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual byte * </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#f390325c959c3d6a2c03a447d6cd469d">CreatePutSpace</a> (size_t &size)</td></tr><tr><td class="mdescLeft"> </td><td class="mdescRight">request space which can be written into by the caller, and then used as input to <a class="el" href="class_buffered_transformation.html#e70658b0d271f8e114ac6c3cc9774ede" title="input a byte for processing">Put()</a> <a href="#f390325c959c3d6a2c03a447d6cd469d"></a><br></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="ff5e36148728c1db63d9d3a6f5b49d7f"></a><!-- doxytag: member="BufferedTransformation::CanModifyInput" ref="ff5e36148728c1db63d9d3a6f5b49d7f" args="() const" -->virtual bool </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#ff5e36148728c1db63d9d3a6f5b49d7f">CanModifyInput</a> () const</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="e15df84a7b67c25dfe2ce0ef5a74123c"></a><!-- doxytag: member="BufferedTransformation::PutModifiable" ref="e15df84a7b67c25dfe2ce0ef5a74123c" args="(byte *inString, size_t length, bool blocking=true)" -->size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#e15df84a7b67c25dfe2ce0ef5a74123c">PutModifiable</a> (byte *inString, size_t length, bool blocking=true)</td></tr><tr><td class="mdescLeft"> </td><td class="mdescRight">input multiple bytes that may be modified by callee <br></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="20ae0ef2e4ff338b43849e541e9b940f"></a><!-- doxytag: member="BufferedTransformation::MessageEnd" ref="20ae0ef2e4ff338b43849e541e9b940f" args="(int propagation=-1, bool blocking=true)" -->bool </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#20ae0ef2e4ff338b43849e541e9b940f">MessageEnd</a> (int propagation=-1, bool blocking=true)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a10b7e626f5af900a4d12f6e5d125891"></a><!-- doxytag: member="BufferedTransformation::PutMessageEnd" ref="a10b7e626f5af900a4d12f6e5d125891" args="(const byte *inString, size_t length, int propagation=-1, bool blocking=true)" -->size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#a10b7e626f5af900a4d12f6e5d125891">PutMessageEnd</a> (const byte *inString, size_t length, int propagation=-1, bool blocking=true)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="class_buffered_transformation.html#d396dcb42260f23125a35ec0e5d17d55">Put2</a> (const byte *inString, size_t length, int messageEnd, bool blocking)=0</td></tr>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -