System::IO::BasicSTDOStreamWrapper class

BasicSTDOStreamWrapper class

Represents a System.IO.Stream-like wrapper for std::basic_ostream and its derived objects. Objects of this class should only be allocated using System::MakeObject() function. Never create instance of this type on stack or using operator new, as it will result in runtime errors and/or assertion faults. Always wrap this class into System::SmartPtr pointer and use this pointer to pass it to functions as argument.

template<typename T,typename>class BasicSTDOStreamWrapper : public virtual System::IO::STDIOStreamWrapperBase<T>

Methods

MethodDescription
BasicSTDOStreamWrapper(std::basic_ostream<char_type, traits_type>&, STDIOStreamWrappingMode)Constructs a new instance of the BasicSTDOStreamWrapper.
BasicSTDOStreamWrapper(const BasicSTDOStreamWrapper&)Copy constructor. Deleted.
Flush() overrideClears this stream’s buffers and writes all buffered data to the underlying storage.
operator=(const BasicSTDOStreamWrapper&)Copy assignment operator. Deleted.
Read(const ArrayPtr<uint8_t>&, int32_t, int32_t) overrideIf wrapping mode is binary, reads the specified number of bytes from the stream, otherwise read the specified number of characters and converts them to uint8_t type. Writes result of the reading to the specified byte array. Not supported!
Read(const System::Details::ArrayView<uint8_t>&, int32_t, int32_t) overrideReads the specified number of bytes from the stream and writes them to the specified byte array.
ReadByte() overrideIf wrapping mode is binary, reads a single byte from the last decoded character storage, otherwise read a single character from the stream and convert it to uint8_t type. Not supported!
SetLength(int64_t) overrideSets the length of the stream represented by the current object.
Write(const ArrayPtr<uint8_t>&, int32_t, int32_t) overrideIf wrapping mode is binary, writes to the stream the specified subrange of bytes from the specified byte array, otherwise convert the specified subrange of bytes from the specified byte array to char_type type ant then writes result to the stream.
Write(const System::Details::ArrayView<uint8_t>&, int32_t, int32_t) overrideWrites the specified subrange of bytes from the specified byte array to the stream.
WriteByte(uint8_t) overrideIf wrapping mode is binary, writes to the stream the specified unsigned 8-bit integer value, otherwise convert it to char_type type and then write the result to the stream.

Fields

FieldDescription
static NullA stream with no underlying storage.

Typedefs

TypedefDescription
BaseType
char_typeRTTI information.
ThisType
ThisTypeBaseTypesInfo
traits_type

See Also