Memory streams - Fixed FixedBuffer template

This commit is contained in:
Emmanuel BENOîT 2020-09-27 11:04:00 +02:00
parent 8a19374d3f
commit b8db177012
2 changed files with 4 additions and 4 deletions

View file

@ -22,7 +22,7 @@ class T_MemoryInputStream final : public A_InputStream
T_MemoryInputStream& operator= ( T_MemoryInputStream const& other ) noexcept; T_MemoryInputStream& operator= ( T_MemoryInputStream const& other ) noexcept;
template< int S , typename T > template< size_t S , typename T >
explicit T_MemoryInputStream( T_FixedBuffer< S , T > const& buffer ); explicit T_MemoryInputStream( T_FixedBuffer< S , T > const& buffer );
template< typename T > template< typename T >
@ -49,7 +49,7 @@ class T_MemoryOutputStream final : public A_OutputStream
T_MemoryOutputStream( void* buffer , size_t size , F_Resizer resizer = nullptr ); T_MemoryOutputStream( void* buffer , size_t size , F_Resizer resizer = nullptr );
T_MemoryOutputStream( T_MemoryOutputStream&& source ) noexcept; T_MemoryOutputStream( T_MemoryOutputStream&& source ) noexcept;
template< int S , typename T > template< size_t S , typename T >
explicit T_MemoryOutputStream( T_FixedBuffer< S , T >& buffer ); explicit T_MemoryOutputStream( T_FixedBuffer< S , T >& buffer );
template< typename T > template< typename T >

View file

@ -10,7 +10,7 @@ namespace ebcl {
/*= T_MemoryInputStream ======================================================*/ /*= T_MemoryInputStream ======================================================*/
template< int S , typename T > template< size_t S , typename T >
inline T_MemoryInputStream::T_MemoryInputStream( T_FixedBuffer< S , T > const& buffer ) inline T_MemoryInputStream::T_MemoryInputStream( T_FixedBuffer< S , T > const& buffer )
: T_MemoryInputStream( buffer.data( ) , buffer.bytes( ) ) : T_MemoryInputStream( buffer.data( ) , buffer.bytes( ) )
{ } { }
@ -23,7 +23,7 @@ inline T_MemoryInputStream::T_MemoryInputStream( T_Buffer< T > const& buffer )
/*= T_MemoryOutputStream =====================================================*/ /*= T_MemoryOutputStream =====================================================*/
template< int S , typename T > template< size_t S , typename T >
inline T_MemoryOutputStream::T_MemoryOutputStream( T_FixedBuffer< S , T >& buffer ) inline T_MemoryOutputStream::T_MemoryOutputStream( T_FixedBuffer< S , T >& buffer )
: T_MemoryOutputStream( buffer.data( ) , buffer.bytes( ) ) : T_MemoryOutputStream( buffer.data( ) , buffer.bytes( ) )
{ } { }