roo_io
API Documentation for roo_io
Loading...
Searching...
No Matches
roo_io Namespace Reference

Namespaces

namespace  byte_order
 
namespace  internal
 

Data Structures

class  BackInsertingIterator
 
class  BufferedInputStreamIterator
 
class  BufferedMultipassInputStreamIterator
 
class  BufferedOutputStreamIterator
 
class  Directory
 
class  DirectoryImpl
 
class  FileIterable
 
class  FileResource
 
class  Filesystem
 
struct  HostNativeReader
 
struct  HostNativeWriter
 
class  InputStream
 Virtualizes access to files, memory, and other readable sources. More...
 
class  InputStreamReader
 Buffered typed reader over InputStream. More...
 
class  IntegerReader
 
class  IntegerReader< kBigEndian >
 
class  IntegerReader< kLittleEndian >
 
class  MacAddress
 
class  MemoryInputStream
 
class  MemoryOutputIterator
 Bounded output iterator writing from given address up to end. More...
 
class  MemoryOutputStream
 
class  MemoryResource
 
class  Mount
 
class  MountImpl
 
class  MultipassGenericMemoryIterable
 
class  MultipassGenericMemoryIterator
 Multipass bounded iterator reading from [begin, end). More...
 
class  MultipassInputStream
 Virtualizes access to files, memory, and other readable sources. More...
 
class  MultipassInputStreamReader
 
class  MultipassResource
 
class  NullInputStream
 
class  NullOutputStream
 
class  NumberWriter
 
class  NumberWriter< kBigEndian >
 
class  NumberWriter< kLittleEndian >
 
class  OutputStream
 Virtualizes access to writable sinks (files, memory, devices). More...
 
class  OutputStreamWriter
 Buffered typed writer over OutputStream. More...
 
class  Resource
 
class  RingBuffer
 
class  RingPipe
 
class  RingPipeInputStream
 InputStream adapter that reads from RingPipe. More...
 
class  RingPipeOutputStream
 OutputStream adapter that writes to RingPipe. More...
 
class  SafeGenericMemoryIterable
 
class  SafeGenericMemoryIterator
 Bounded iterator reading from [begin, end). More...
 
class  Stat
 
class  UnsafeGenericMemoryIterable
 
class  UnsafeGenericMemoryIterator
 Infinite iterator reading from memory starting at provided address. More...
 
class  UnsafeMemoryOutputIterator
 Infinite output iterator writing to memory from given address. More...
 
class  Utf8Decoder
 

Typedefs

using byte = roo::byte
 
template<typename CharT , typename Traits = std::char_traits<CharT>>
using basic_string_view = roo::basic_string_view< CharT, Traits >
 
using string_view = basic_string_view< char >
 
using UnsafeMemoryIterator = UnsafeGenericMemoryIterator< const byte * >
 
using MemoryIterator = SafeGenericMemoryIterator< const byte * >
 
using MultipassMemoryIterator = MultipassGenericMemoryIterator< const byte * >
 
using UnsafeMemoryIterable = UnsafeGenericMemoryIterable< const byte * >
 
using MemoryIterable = SafeGenericMemoryIterable< const byte * >
 
using MultipassMemoryIterable = MultipassGenericMemoryIterable< const byte * >
 

Enumerations

enum  ByteOrder { kLittleEndian = 0 , kBigEndian = 1 }
 
enum  FileUpdatePolicy { kFailIfExists = 0 , kTruncateIfExists = 1 , kAppendIfExists = 2 }
 
enum  Status {
  kOk = 0 , kEndOfStream = 1 , kClosed , kNotMounted ,
  kOpenError , kReadError , kSeekError , kWriteError ,
  kGenericMountError , kReadOnlyFilesystem , kNotFound , kFileExists ,
  kDirectoryExists , kNotDirectory , kNotFile , kDirectoryNotEmpty ,
  kInvalidPath , kOutOfMemory , kTooManyFilesOpen , kNoSpaceLeftOnDevice ,
  kUnknownIOError , kAccessDenied , kNoMedia , kConnectionError ,
  kBrokenPipe
}
 

Functions

template<typename storage_type >
constexpr storage_type bswap (storage_type in)
 
template<typename storage_type , ByteOrder dst>
constexpr storage_type hto (storage_type in)
 
template<typename storage_type , ByteOrder src>
constexpr storage_type toh (storage_type in)
 
template<typename storage_type >
constexpr storage_type htobe (storage_type in)
 
template<typename storage_type >
constexpr storage_type htole (storage_type in)
 
template<typename storage_type >
constexpr storage_type betoh (storage_type in)
 
template<typename storage_type >
constexpr storage_type letoh (storage_type in)
 
template<typename InputIterator >
constexpr uint8_t ReadU8 (InputIterator &in)
 
template<typename InputIterator >
constexpr uint16_t ReadBeU16 (InputIterator &in)
 
template<typename InputIterator >
constexpr uint16_t ReadLeU16 (InputIterator &in)
 
template<typename InputIterator >
constexpr uint32_t ReadBeU24 (InputIterator &in)
 
template<typename InputIterator >
constexpr uint32_t ReadLeU24 (InputIterator &in)
 
template<typename InputIterator >
constexpr uint32_t ReadBeU32 (InputIterator &in)
 
template<typename InputIterator >
constexpr uint32_t ReadLeU32 (InputIterator &in)
 
template<typename InputIterator >
constexpr uint64_t ReadBeU64 (InputIterator &in)
 
template<typename InputIterator >
constexpr uint64_t ReadLeU64 (InputIterator &in)
 
template<typename InputIterator >
constexpr int8_t ReadS8 (InputIterator &in)
 
template<typename InputIterator >
constexpr int16_t ReadBeS16 (InputIterator &in)
 
template<typename InputIterator >
constexpr int16_t ReadLeS16 (InputIterator &in)
 
template<typename InputIterator >
constexpr int32_t ReadBeS24 (InputIterator &in)
 
template<typename InputIterator >
constexpr int32_t ReadLeS24 (InputIterator &in)
 
template<typename InputIterator >
constexpr int32_t ReadBeS32 (InputIterator &in)
 
template<typename InputIterator >
constexpr int32_t ReadLeS32 (InputIterator &in)
 
template<typename InputIterator >
constexpr int64_t ReadBeS64 (InputIterator &in)
 
template<typename InputIterator >
constexpr int64_t ReadLeS64 (InputIterator &in)
 
template<typename InputIterator >
size_t ReadByteArray (InputIterator &in, byte *result, size_t count)
 
template<typename InputIterator >
uint64_t ReadVarU64 (InputIterator &in)
 
template<typename InputIterator , ByteOrder byte_order>
constexpr uint16_t ReadU16 (InputIterator &in)
 
template<typename InputIterator , ByteOrder byte_order>
constexpr uint32_t ReadU24 (InputIterator &in)
 
template<typename InputIterator , ByteOrder byte_order>
constexpr uint32_t ReadU32 (InputIterator &in)
 
template<typename InputIterator , ByteOrder byte_order>
constexpr uint64_t ReadU64 (InputIterator &in)
 
template<typename InputIterator >
size_t ReadCString (InputIterator &in, char *buf, size_t capacity=SIZE_MAX)
 
template<typename InputIterator >
std::string ReadString (InputIterator &in, size_t max_size=SIZE_MAX)
 
template<typename InputIterator , typename std::enable_if< internal::MemoryIteratorTraits< InputIterator >::is_memory, bool >::type = true>
roo::string_view ReadStringView (InputIterator &in, size_t max_size=SIZE_MAX)
 
template<typename OutputIterator >
constexpr void WriteU8 (OutputIterator &out, uint8_t v)
 
template<typename OutputIterator >
constexpr void WriteBeU16 (OutputIterator &out, uint16_t v)
 
template<typename OutputIterator >
constexpr void WriteLeU16 (OutputIterator &out, uint16_t v)
 
template<typename OutputIterator >
constexpr void WriteBeU24 (OutputIterator &out, uint32_t v)
 
template<typename OutputIterator >
constexpr void WriteLeU24 (OutputIterator &out, uint32_t v)
 
template<typename OutputIterator >
constexpr void WriteBeU32 (OutputIterator &out, uint32_t v)
 
template<typename OutputIterator >
constexpr void WriteLeU32 (OutputIterator &out, uint32_t v)
 
template<typename OutputIterator >
constexpr void WriteBeU64 (OutputIterator &out, uint64_t v)
 
template<typename OutputIterator >
constexpr void WriteLeU64 (OutputIterator &out, uint64_t v)
 
template<typename OutputIterator >
constexpr void WriteS8 (OutputIterator &out, int8_t v)
 
template<typename OutputIterator >
constexpr void WriteBeS16 (OutputIterator &out, int16_t v)
 
template<typename OutputIterator >
constexpr void WriteLeS16 (OutputIterator &out, int16_t v)
 
template<typename OutputIterator >
constexpr void WriteBeS24 (OutputIterator &out, int32_t v)
 
template<typename OutputIterator >
constexpr void WriteLeS24 (OutputIterator &out, int32_t v)
 
template<typename OutputIterator >
constexpr void WriteBeS32 (OutputIterator &out, int32_t v)
 
template<typename OutputIterator >
constexpr void WriteLeS32 (OutputIterator &out, int32_t v)
 
template<typename OutputIterator >
constexpr void WriteBeS64 (OutputIterator &out, int64_t v)
 
template<typename OutputIterator >
constexpr void WriteLeS64 (OutputIterator &out, int64_t v)
 
template<typename OutputIterator >
size_t WriteByteArray (OutputIterator &out, const byte *source, size_t count)
 
template<typename OutputIterator >
void WriteVarU64 (OutputIterator &out, uint64_t data)
 
template<typename OutputIterator >
void WriteString (OutputIterator &itr, roo::string_view data)
 
template<typename OutputIterator >
void WriteString (OutputIterator &itr, const char *data)
 
template<typename OutputIterator , ByteOrder byte_order>
constexpr void WriteU16 (OutputIterator &in, uint16_t v)
 
template<typename OutputIterator , ByteOrder byte_order>
constexpr void WriteU24 (OutputIterator &in, uint32_t v)
 
template<typename OutputIterator , ByteOrder byte_order>
constexpr void WriteU32 (OutputIterator &in, uint32_t v)
 
const charGetFileName (const char *path)
 
Status DeleteRecursively (roo_io::Mount &fs, const char *path)
 
Status MkDirRecursively (roo_io::Mount &fs, const char *path)
 
Status MkParentDirRecursively (roo_io::Mount &fs, const char *path)
 
MultipassInputStreamReader OpenDataFile (roo_io::Mount &fs, const char *path)
 
OutputStreamWriter OpenDataFileForWrite (roo_io::Mount &fs, const char *path, roo_io::FileUpdatePolicy update_policy)
 
std::unique_ptr< DirectoryImplDirectoryError (Status error)
 
std::unique_ptr< MultipassInputStreamInputError (Status error)
 
std::unique_ptr< OutputStreamOutputError (Status error)
 
template<int bytes>
bool PatternCompare (const byte *buf, size_t count, const byte *val)
 
template<int bytes>
bool PatternCompareAligned (const byte *buf, size_t count, const byte *val)
 
template<>
bool PatternCompare< 1 > (const byte *buf, size_t count, const byte *val)
 
template<>
bool PatternCompareAligned< 1 > (const byte *buf, size_t count, const byte *val)
 
template<>
 __attribute__ ((always_inline)) bool PatternCompare< 2 >(const byte *buf
 
template<int bytes>
void PatternWrite (byte *buf, const byte *val)
 
template<>
void PatternWrite< 1 > (byte *buf, const byte *val)
 
template<>
void PatternWrite< 2 > (byte *buf, const byte *val)
 
template<>
void PatternWrite< 3 > (byte *buf, const byte *val)
 
template<>
void PatternWrite< 4 > (byte *buf, const byte *val)
 
template<int bytes>
void PatternFill (byte *buf, size_t count, const byte *val)
 
template<>
void PatternFill< 1 > (byte *buf, size_t count, const byte *val)
 
template<>
void PatternFill< 2 > (byte *buf, size_t count, const byte *val)
 
template<>
void PatternFill< 3 > (byte *buf, size_t count, const byte *val)
 
template<>
void PatternFill< 4 > (byte *buf, size_t count, const byte *val)
 
void BitFill (byte *buf, uint32_t offset, size_t count, bool value)
 
void NibbleFill (byte *buf, uint32_t offset, size_t count, byte value)
 
constexpr uint8_t LoadU8 (const byte *source)
 
constexpr uint16_t LoadBeU16 (const byte *source)
 
constexpr uint16_t LoadLeU16 (const byte *source)
 
constexpr uint32_t LoadBeU24 (const byte *source)
 
constexpr uint32_t LoadLeU24 (const byte *source)
 
constexpr uint32_t LoadBeU32 (const byte *source)
 
constexpr uint32_t LoadLeU32 (const byte *source)
 
constexpr uint64_t LoadBeU64 (const byte *source)
 
constexpr uint64_t LoadLeU64 (const byte *source)
 
constexpr int8_t LoadS8 (const byte *source)
 
constexpr int16_t LoadBeS16 (const byte *source)
 
constexpr int16_t LoadLeS16 (const byte *source)
 
constexpr int32_t LoadBeS24 (const byte *source)
 
constexpr int32_t LoadLeS24 (const byte *source)
 
constexpr int32_t LoadBeS32 (const byte *source)
 
constexpr int32_t LoadLeS32 (const byte *source)
 
constexpr int64_t LoadBeS64 (const byte *source)
 
constexpr int64_t LoadLeS64 (const byte *source)
 
template<typename T >
constexpr T LoadHostNative (const byte *source)
 
template<ByteOrder byte_order>
constexpr uint16_t LoadU16 (const byte *source)
 
template<ByteOrder byte_order>
constexpr uint32_t LoadU24 (const byte *source)
 
template<ByteOrder byte_order>
constexpr uint32_t LoadU32 (const byte *source)
 
template<ByteOrder byte_order>
constexpr uint64_t LoadU64 (const byte *source)
 
template<ByteOrder byte_order>
constexpr int16_t LoadS16 (const byte *source)
 
template<ByteOrder byte_order>
constexpr int32_t LoadS24 (const byte *source)
 
template<ByteOrder byte_order>
constexpr int32_t LoadS32 (const byte *source)
 
template<ByteOrder byte_order>
constexpr int64_t LoadS64 (const byte *source)
 
template<typename IntegerType >
constexpr IntegerType LoadBeInteger (const byte *source)
 
template<typename IntegerType >
constexpr IntegerType LoadLeInteger (const byte *source)
 
template<ByteOrder byte_order, typename IntegerType >
constexpr IntegerType LoadInteger (const byte *source)
 
template<>
constexpr uint16_t LoadU16< kBigEndian > (const byte *source)
 
template<>
constexpr uint16_t LoadU16< kLittleEndian > (const byte *source)
 
template<>
constexpr uint32_t LoadU24< kBigEndian > (const byte *source)
 
template<>
constexpr uint32_t LoadU24< kLittleEndian > (const byte *source)
 
template<>
constexpr uint32_t LoadU32< kBigEndian > (const byte *source)
 
template<>
constexpr uint32_t LoadU32< kLittleEndian > (const byte *source)
 
template<>
constexpr uint64_t LoadU64< kBigEndian > (const byte *source)
 
template<>
constexpr uint64_t LoadU64< kLittleEndian > (const byte *source)
 
template<>
constexpr int16_t LoadS16< kBigEndian > (const byte *source)
 
template<>
constexpr int16_t LoadS16< kLittleEndian > (const byte *source)
 
template<>
constexpr int32_t LoadS24< kBigEndian > (const byte *source)
 
template<>
constexpr int32_t LoadS24< kLittleEndian > (const byte *source)
 
template<>
constexpr int32_t LoadS32< kBigEndian > (const byte *source)
 
template<>
constexpr int32_t LoadS32< kLittleEndian > (const byte *source)
 
template<>
constexpr int64_t LoadS64< kBigEndian > (const byte *source)
 
template<>
constexpr int64_t LoadS64< kLittleEndian > (const byte *source)
 
template<>
constexpr uint8_t LoadInteger< kBigEndian, uint8_t > (const byte *source)
 
template<>
constexpr uint8_t LoadInteger< kLittleEndian, uint8_t > (const byte *source)
 
template<>
constexpr uint16_t LoadInteger< kBigEndian, uint16_t > (const byte *source)
 
template<>
constexpr uint16_t LoadInteger< kLittleEndian, uint16_t > (const byte *source)
 
template<>
constexpr uint32_t LoadInteger< kBigEndian, uint32_t > (const byte *source)
 
template<>
constexpr uint32_t LoadInteger< kLittleEndian, uint32_t > (const byte *source)
 
template<>
constexpr uint64_t LoadInteger< kBigEndian, uint64_t > (const byte *source)
 
template<>
constexpr uint64_t LoadInteger< kLittleEndian, uint64_t > (const byte *source)
 
template<>
constexpr int8_t LoadInteger< kBigEndian, int8_t > (const byte *source)
 
template<>
constexpr int8_t LoadInteger< kLittleEndian, int8_t > (const byte *source)
 
template<>
constexpr int16_t LoadInteger< kBigEndian, int16_t > (const byte *source)
 
template<>
constexpr int16_t LoadInteger< kLittleEndian, int16_t > (const byte *source)
 
template<>
constexpr int32_t LoadInteger< kBigEndian, int32_t > (const byte *source)
 
template<>
constexpr int32_t LoadInteger< kLittleEndian, int32_t > (const byte *source)
 
template<>
constexpr int64_t LoadInteger< kBigEndian, int64_t > (const byte *source)
 
template<>
constexpr int64_t LoadInteger< kLittleEndian, int64_t > (const byte *source)
 
template<>
constexpr uint8_t LoadBeInteger< uint8_t > (const byte *source)
 
template<>
constexpr uint8_t LoadLeInteger< uint8_t > (const byte *source)
 
template<>
constexpr uint16_t LoadBeInteger< uint16_t > (const byte *source)
 
template<>
constexpr uint16_t LoadLeInteger< uint16_t > (const byte *source)
 
template<>
constexpr uint32_t LoadBeInteger< uint32_t > (const byte *source)
 
template<>
constexpr uint32_t LoadLeInteger< uint32_t > (const byte *source)
 
template<>
constexpr uint64_t LoadBeInteger< uint64_t > (const byte *source)
 
template<>
constexpr uint64_t LoadLeInteger< uint64_t > (const byte *source)
 
template<>
constexpr int8_t LoadBeInteger< int8_t > (const byte *source)
 
template<>
constexpr int8_t LoadLeInteger< int8_t > (const byte *source)
 
template<>
constexpr int16_t LoadBeInteger< int16_t > (const byte *source)
 
template<>
constexpr int16_t LoadLeInteger< int16_t > (const byte *source)
 
template<>
constexpr int32_t LoadBeInteger< int32_t > (const byte *source)
 
template<>
constexpr int32_t LoadLeInteger< int32_t > (const byte *source)
 
template<>
constexpr int64_t LoadBeInteger< int64_t > (const byte *source)
 
template<>
constexpr int64_t LoadLeInteger< int64_t > (const byte *source)
 
void StoreU8 (uint8_t v, byte *target)
 
void StoreBeU16 (uint16_t v, byte *target)
 
void StoreLeU16 (uint16_t v, byte *target)
 
void StoreBeU24 (uint32_t v, byte *target)
 
void StoreLeU24 (uint32_t v, byte *target)
 
void StoreBeU32 (uint32_t v, byte *target)
 
void StoreLeU32 (uint32_t v, byte *target)
 
void StoreBeU64 (uint64_t v, byte *target)
 
void StoreLeU64 (uint64_t v, byte *target)
 
void StoreS8 (int8_t v, byte *target)
 
void StoreBeS16 (uint16_t v, byte *target)
 
void StoreLeS16 (uint16_t v, byte *target)
 
void StoreBeS24 (uint32_t v, byte *target)
 
void StoreLeS24 (uint32_t v, byte *target)
 
void StoreBeS32 (uint32_t v, byte *target)
 
void StoreLeS32 (uint32_t v, byte *target)
 
void StoreBeS64 (uint64_t v, byte *target)
 
void StoreLeS64 (uint64_t v, byte *target)
 
template<typename T >
void StoreHostNative (const T &v, byte *target)
 
template<ByteOrder byte_order>
void StoreU16 (uint16_t v, byte *target)
 
template<ByteOrder byte_order>
void StoreU24 (uint32_t v, byte *target)
 
template<ByteOrder byte_order>
void StoreU32 (uint32_t v, byte *target)
 
template<ByteOrder byte_order>
void StoreU64 (uint64_t v, byte *target)
 
template<ByteOrder byte_order>
void StoreS16 (int16_t v, byte *target)
 
template<ByteOrder byte_order>
void StoreS24 (int32_t v, byte *target)
 
template<ByteOrder byte_order>
void StoreS32 (int32_t v, byte *target)
 
template<ByteOrder byte_order>
void StoreS64 (int64_t v, byte *target)
 
template<ByteOrder byte_order, typename IntegerType >
void StoreInteger (IntegerType v, byte *target)
 
template<>
void StoreU16< kBigEndian > (uint16_t v, byte *target)
 
template<>
void StoreU16< kLittleEndian > (uint16_t v, byte *target)
 
template<>
void StoreU24< kBigEndian > (uint32_t v, byte *target)
 
template<>
void StoreU24< kLittleEndian > (uint32_t v, byte *target)
 
template<>
void StoreU32< kBigEndian > (uint32_t v, byte *target)
 
template<>
void StoreU32< kLittleEndian > (uint32_t v, byte *target)
 
template<>
void StoreU64< kBigEndian > (uint64_t v, byte *target)
 
template<>
void StoreU64< kLittleEndian > (uint64_t v, byte *target)
 
template<>
void StoreS16< kBigEndian > (int16_t v, byte *target)
 
template<>
void StoreS16< kLittleEndian > (int16_t v, byte *target)
 
template<>
void StoreS24< kBigEndian > (int32_t v, byte *target)
 
template<>
void StoreS24< kLittleEndian > (int32_t v, byte *target)
 
template<>
void StoreS32< kBigEndian > (int32_t v, byte *target)
 
template<>
void StoreS32< kLittleEndian > (int32_t v, byte *target)
 
template<>
void StoreS64< kBigEndian > (int64_t v, byte *target)
 
template<>
void StoreS64< kLittleEndian > (int64_t v, byte *target)
 
template<>
void StoreInteger< kBigEndian, uint8_t > (uint8_t v, byte *target)
 
template<>
void StoreInteger< kLittleEndian, uint8_t > (uint8_t v, byte *target)
 
template<>
void StoreInteger< kBigEndian, int8_t > (int8_t v, byte *target)
 
template<>
void StoreInteger< kLittleEndian, int8_t > (int8_t v, byte *target)
 
template<>
void StoreInteger< kBigEndian, uint16_t > (uint16_t v, byte *target)
 
template<>
void StoreInteger< kLittleEndian, uint16_t > (uint16_t v, byte *target)
 
template<>
void StoreInteger< kBigEndian, uint32_t > (uint32_t v, byte *target)
 
template<>
void StoreInteger< kLittleEndian, uint32_t > (uint32_t v, byte *target)
 
template<>
void StoreInteger< kBigEndian, uint64_t > (uint64_t v, byte *target)
 
template<>
void StoreInteger< kLittleEndian, uint64_t > (uint64_t v, byte *target)
 
bool operator== (const MacAddress &a, const MacAddress &b)
 
bool operator!= (const MacAddress &a, const MacAddress &b)
 
bool operator< (const MacAddress &a, const MacAddress &b)
 
bool operator> (const MacAddress &a, const MacAddress &b)
 
bool operator<= (const MacAddress &a, const MacAddress &b)
 
bool operator>= (const MacAddress &a, const MacAddress &b)
 
roo_logging::Stream & operator<< (roo_logging::Stream &s, const MacAddress &addr)
 
template<typename InputIterator >
MacAddress ReadMacAddress (InputIterator &itr)
 
template<typename OutputIterator >
void WriteMacAddress (OutputIterator &itr, const MacAddress &addr)
 
const charStatusAsString (Status status)
 
roo_logging::Stream & operator<< (roo_logging::Stream &s, Status status)
 
void Base64Encode (const byte *input, size_t input_length, char *output)
 
std::string StringPrintf (const char *format,...)
 
std::string StringVPrintf (const char *format, va_list arg)
 
template<typename OutputItr >
void DecodeUtfString (roo::string_view s, OutputItr itr)
 
std::vector< char32_tDecodeUtfStringToVector (roo::string_view s)
 
template<typename OutputIterator >
void WriteUtf8Char (OutputIterator &itr, char32_t v)
 
int WriteUtf8Char (byte *buf, char32_t ch)
 
int WriteUtf8Char (char *buf, char32_t ch)
 

Variables

static const size_t kInputStreamIteratorBufferSize = 64
 
static const size_t kMultipassInputStreamIteratorBufferSize = 64
 
static const size_t kOutputStreamIteratorBufferSize = 64
 
size_t count
 

Typedef Documentation

◆ basic_string_view

template<typename CharT , typename Traits = std::char_traits<CharT>>
using roo_io::basic_string_view = typedef roo::basic_string_view<CharT, Traits>

Definition at line 8 of file string_view.h.

◆ byte

using roo_io::byte = typedef roo::byte

Definition at line 8 of file byte.h.

◆ MemoryIterable

◆ MemoryIterator

◆ MultipassMemoryIterable

◆ MultipassMemoryIterator

◆ string_view

◆ UnsafeMemoryIterable

◆ UnsafeMemoryIterator

Enumeration Type Documentation

◆ ByteOrder

Enumerator
kLittleEndian 
kBigEndian 

Definition at line 15 of file byte_order.h.

◆ FileUpdatePolicy

Enumerator
kFailIfExists 
kTruncateIfExists 
kAppendIfExists 

Definition at line 7 of file file_update_policy.h.

◆ Status

Enumerator
kOk 
kEndOfStream 
kClosed 
kNotMounted 
kOpenError 
kReadError 
kSeekError 
kWriteError 
kGenericMountError 
kReadOnlyFilesystem 
kNotFound 
kFileExists 
kDirectoryExists 
kNotDirectory 
kNotFile 
kDirectoryNotEmpty 
kInvalidPath 
kOutOfMemory 
kTooManyFilesOpen 
kNoSpaceLeftOnDevice 
kUnknownIOError 
kAccessDenied 
kNoMedia 
kConnectionError 
kBrokenPipe 

Definition at line 7 of file status.h.

Function Documentation

◆ __attribute__()

template<>
roo_io::__attribute__ ( (always_inline ) const
inline

◆ Base64Encode()

void roo_io::Base64Encode ( const byte input,
size_t  input_length,
char output 
)

Definition at line 7 of file base64.cpp.

References base64::encode().

◆ betoh()

template<typename storage_type >
constexpr storage_type roo_io::betoh ( storage_type  in)
constexpr

Definition at line 132 of file byte_order.h.

◆ BitFill()

void roo_io::BitFill ( byte buf,
uint32_t  offset,
size_t  count,
bool  value 
)
inline

Definition at line 266 of file fill.h.

References count.

◆ bswap()

template<typename storage_type >
constexpr storage_type roo_io::bswap ( storage_type  in)
constexpr

Definition at line 97 of file byte_order.h.

References roo_io::byte_order::Swap().

◆ DecodeUtfString()

template<typename OutputItr >
void roo_io::DecodeUtfString ( roo::string_view  s,
OutputItr  itr 
)

Definition at line 58 of file unicode.h.

Referenced by DecodeUtfStringToVector().

◆ DecodeUtfStringToVector()

std::vector< char32_t > roo_io::DecodeUtfStringToVector ( roo::string_view  s)
inline

Definition at line 64 of file unicode.h.

References DecodeUtfString().

◆ DeleteRecursively()

Status roo_io::DeleteRecursively ( roo_io::Mount fs,
const char path 
)

◆ DirectoryError()

std::unique_ptr< DirectoryImpl > roo_io::DirectoryError ( Status  error)

Definition at line 37 of file mount_impl.cpp.

◆ GetFileName()

const char * roo_io::GetFileName ( const char path)

Definition at line 54 of file filesystem.cpp.

◆ hto()

template<typename storage_type , ByteOrder dst>
constexpr storage_type roo_io::hto ( storage_type  in)
constexpr

Definition at line 104 of file byte_order.h.

◆ htobe()

template<typename storage_type >
constexpr storage_type roo_io::htobe ( storage_type  in)
constexpr

Definition at line 118 of file byte_order.h.

◆ htole()

template<typename storage_type >
constexpr storage_type roo_io::htole ( storage_type  in)
constexpr

Definition at line 125 of file byte_order.h.

◆ InputError()

std::unique_ptr< MultipassInputStream > roo_io::InputError ( Status  error)

Definition at line 41 of file mount_impl.cpp.

Referenced by roo_io::Mount::fopen().

◆ letoh()

template<typename storage_type >
constexpr storage_type roo_io::letoh ( storage_type  in)
constexpr

Definition at line 139 of file byte_order.h.

◆ LoadBeInteger()

template<typename IntegerType >
constexpr IntegerType roo_io::LoadBeInteger ( const byte source)
inlineconstexpr

◆ LoadBeInteger< int16_t >()

template<>
constexpr int16_t roo_io::LoadBeInteger< int16_t > ( const byte source)
inlineconstexpr

Definition at line 472 of file load.h.

References LoadBeS16().

◆ LoadBeInteger< int32_t >()

template<>
constexpr int32_t roo_io::LoadBeInteger< int32_t > ( const byte source)
inlineconstexpr

Definition at line 482 of file load.h.

References LoadBeS32().

◆ LoadBeInteger< int64_t >()

template<>
constexpr int64_t roo_io::LoadBeInteger< int64_t > ( const byte source)
inlineconstexpr

Definition at line 492 of file load.h.

References LoadBeS64().

◆ LoadBeInteger< int8_t >()

template<>
constexpr int8_t roo_io::LoadBeInteger< int8_t > ( const byte source)
inlineconstexpr

Definition at line 462 of file load.h.

References LoadS8().

◆ LoadBeInteger< uint16_t >()

template<>
constexpr uint16_t roo_io::LoadBeInteger< uint16_t > ( const byte source)
inlineconstexpr

Definition at line 432 of file load.h.

References LoadBeU16().

◆ LoadBeInteger< uint32_t >()

template<>
constexpr uint32_t roo_io::LoadBeInteger< uint32_t > ( const byte source)
inlineconstexpr

Definition at line 442 of file load.h.

References LoadBeU32().

◆ LoadBeInteger< uint64_t >()

template<>
constexpr uint64_t roo_io::LoadBeInteger< uint64_t > ( const byte source)
inlineconstexpr

Definition at line 452 of file load.h.

References LoadBeU64().

◆ LoadBeInteger< uint8_t >()

template<>
constexpr uint8_t roo_io::LoadBeInteger< uint8_t > ( const byte source)
inlineconstexpr

Definition at line 422 of file load.h.

References LoadU8().

◆ LoadBeS16()

constexpr int16_t roo_io::LoadBeS16 ( const byte source)
inlineconstexpr

◆ LoadBeS24()

constexpr int32_t roo_io::LoadBeS24 ( const byte source)
inlineconstexpr

Definition at line 76 of file load.h.

References LoadBeU24().

Referenced by LoadS24< kBigEndian >().

◆ LoadBeS32()

constexpr int32_t roo_io::LoadBeS32 ( const byte source)
inlineconstexpr

◆ LoadBeS64()

constexpr int64_t roo_io::LoadBeS64 ( const byte source)
inlineconstexpr

◆ LoadBeU16()

constexpr uint16_t roo_io::LoadBeU16 ( const byte source)
inlineconstexpr

◆ LoadBeU24()

constexpr uint32_t roo_io::LoadBeU24 ( const byte source)
inlineconstexpr

Definition at line 28 of file load.h.

Referenced by LoadBeS24(), and LoadU24< kBigEndian >().

◆ LoadBeU32()

constexpr uint32_t roo_io::LoadBeU32 ( const byte source)
inlineconstexpr

◆ LoadBeU64()

constexpr uint64_t roo_io::LoadBeU64 ( const byte source)
inlineconstexpr

◆ LoadHostNative()

template<typename T >
constexpr T roo_io::LoadHostNative ( const byte source)
inlineconstexpr

Definition at line 160 of file load.h.

◆ LoadInteger()

template<ByteOrder byte_order, typename IntegerType >
constexpr IntegerType roo_io::LoadInteger ( const byte source)
inlineconstexpr

◆ LoadInteger< kBigEndian, int16_t >()

template<>
constexpr int16_t roo_io::LoadInteger< kBigEndian, int16_t > ( const byte source)
inlineconstexpr

Definition at line 389 of file load.h.

References LoadBeS16().

◆ LoadInteger< kBigEndian, int32_t >()

template<>
constexpr int32_t roo_io::LoadInteger< kBigEndian, int32_t > ( const byte source)
inlineconstexpr

Definition at line 400 of file load.h.

References LoadBeS32().

◆ LoadInteger< kBigEndian, int64_t >()

template<>
constexpr int64_t roo_io::LoadInteger< kBigEndian, int64_t > ( const byte source)
inlineconstexpr

Definition at line 411 of file load.h.

References LoadBeS64().

◆ LoadInteger< kBigEndian, int8_t >()

template<>
constexpr int8_t roo_io::LoadInteger< kBigEndian, int8_t > ( const byte source)
inlineconstexpr

Definition at line 379 of file load.h.

◆ LoadInteger< kBigEndian, uint16_t >()

template<>
constexpr uint16_t roo_io::LoadInteger< kBigEndian, uint16_t > ( const byte source)
inlineconstexpr

Definition at line 343 of file load.h.

References LoadBeU16().

◆ LoadInteger< kBigEndian, uint32_t >()

template<>
constexpr uint32_t roo_io::LoadInteger< kBigEndian, uint32_t > ( const byte source)
inlineconstexpr

Definition at line 355 of file load.h.

References LoadBeU32().

◆ LoadInteger< kBigEndian, uint64_t >()

template<>
constexpr uint64_t roo_io::LoadInteger< kBigEndian, uint64_t > ( const byte source)
inlineconstexpr

Definition at line 367 of file load.h.

References LoadBeU64().

◆ LoadInteger< kBigEndian, uint8_t >()

template<>
constexpr uint8_t roo_io::LoadInteger< kBigEndian, uint8_t > ( const byte source)
inlineconstexpr

Definition at line 332 of file load.h.

References LoadU8().

◆ LoadInteger< kLittleEndian, int16_t >()

template<>
constexpr int16_t roo_io::LoadInteger< kLittleEndian, int16_t > ( const byte source)
inlineconstexpr

Definition at line 394 of file load.h.

References LoadLeS16().

◆ LoadInteger< kLittleEndian, int32_t >()

template<>
constexpr int32_t roo_io::LoadInteger< kLittleEndian, int32_t > ( const byte source)
inlineconstexpr

Definition at line 405 of file load.h.

References LoadLeS32().

◆ LoadInteger< kLittleEndian, int64_t >()

template<>
constexpr int64_t roo_io::LoadInteger< kLittleEndian, int64_t > ( const byte source)
inlineconstexpr

Definition at line 416 of file load.h.

References LoadLeS64().

◆ LoadInteger< kLittleEndian, int8_t >()

template<>
constexpr int8_t roo_io::LoadInteger< kLittleEndian, int8_t > ( const byte source)
inlineconstexpr

Definition at line 384 of file load.h.

◆ LoadInteger< kLittleEndian, uint16_t >()

template<>
constexpr uint16_t roo_io::LoadInteger< kLittleEndian, uint16_t > ( const byte source)
inlineconstexpr

Definition at line 349 of file load.h.

References LoadLeU16().

◆ LoadInteger< kLittleEndian, uint32_t >()

template<>
constexpr uint32_t roo_io::LoadInteger< kLittleEndian, uint32_t > ( const byte source)
inlineconstexpr

Definition at line 361 of file load.h.

References LoadLeU32().

◆ LoadInteger< kLittleEndian, uint64_t >()

template<>
constexpr uint64_t roo_io::LoadInteger< kLittleEndian, uint64_t > ( const byte source)
inlineconstexpr

Definition at line 373 of file load.h.

References LoadLeU64().

◆ LoadInteger< kLittleEndian, uint8_t >()

template<>
constexpr uint8_t roo_io::LoadInteger< kLittleEndian, uint8_t > ( const byte source)
inlineconstexpr

Definition at line 337 of file load.h.

References LoadU8().

◆ LoadLeInteger()

template<typename IntegerType >
constexpr IntegerType roo_io::LoadLeInteger ( const byte source)
inlineconstexpr

◆ LoadLeInteger< int16_t >()

template<>
constexpr int16_t roo_io::LoadLeInteger< int16_t > ( const byte source)
inlineconstexpr

Definition at line 477 of file load.h.

References LoadLeS16().

◆ LoadLeInteger< int32_t >()

template<>
constexpr int32_t roo_io::LoadLeInteger< int32_t > ( const byte source)
inlineconstexpr

Definition at line 487 of file load.h.

References LoadLeS32().

◆ LoadLeInteger< int64_t >()

template<>
constexpr int64_t roo_io::LoadLeInteger< int64_t > ( const byte source)
inlineconstexpr

Definition at line 497 of file load.h.

References LoadLeS64().

◆ LoadLeInteger< int8_t >()

template<>
constexpr int8_t roo_io::LoadLeInteger< int8_t > ( const byte source)
inlineconstexpr

Definition at line 467 of file load.h.

References LoadS8().

◆ LoadLeInteger< uint16_t >()

template<>
constexpr uint16_t roo_io::LoadLeInteger< uint16_t > ( const byte source)
inlineconstexpr

Definition at line 437 of file load.h.

References LoadLeU16().

◆ LoadLeInteger< uint32_t >()

template<>
constexpr uint32_t roo_io::LoadLeInteger< uint32_t > ( const byte source)
inlineconstexpr

Definition at line 447 of file load.h.

References LoadLeU32().

◆ LoadLeInteger< uint64_t >()

template<>
constexpr uint64_t roo_io::LoadLeInteger< uint64_t > ( const byte source)
inlineconstexpr

Definition at line 457 of file load.h.

References LoadLeU64().

◆ LoadLeInteger< uint8_t >()

template<>
constexpr uint8_t roo_io::LoadLeInteger< uint8_t > ( const byte source)
inlineconstexpr

Definition at line 427 of file load.h.

References LoadU8().

◆ LoadLeS16()

constexpr int16_t roo_io::LoadLeS16 ( const byte source)
inlineconstexpr

◆ LoadLeS24()

constexpr int32_t roo_io::LoadLeS24 ( const byte source)
inlineconstexpr

Definition at line 82 of file load.h.

References LoadLeU24().

Referenced by LoadS24< kLittleEndian >().

◆ LoadLeS32()

constexpr int32_t roo_io::LoadLeS32 ( const byte source)
inlineconstexpr

◆ LoadLeS64()

constexpr int64_t roo_io::LoadLeS64 ( const byte source)
inlineconstexpr

◆ LoadLeU16()

constexpr uint16_t roo_io::LoadLeU16 ( const byte source)
inlineconstexpr

◆ LoadLeU24()

constexpr uint32_t roo_io::LoadLeU24 ( const byte source)
inlineconstexpr

Definition at line 34 of file load.h.

Referenced by LoadLeS24(), and LoadU24< kLittleEndian >().

◆ LoadLeU32()

constexpr uint32_t roo_io::LoadLeU32 ( const byte source)
inlineconstexpr

◆ LoadLeU64()

constexpr uint64_t roo_io::LoadLeU64 ( const byte source)
inlineconstexpr

◆ LoadS16()

template<ByteOrder byte_order>
constexpr int16_t roo_io::LoadS16 ( const byte source)
inlineconstexpr

◆ LoadS16< kBigEndian >()

template<>
constexpr int16_t roo_io::LoadS16< kBigEndian > ( const byte source)
inlineconstexpr

Definition at line 270 of file load.h.

References LoadBeS16().

◆ LoadS16< kLittleEndian >()

template<>
constexpr int16_t roo_io::LoadS16< kLittleEndian > ( const byte source)
inlineconstexpr

Definition at line 275 of file load.h.

References LoadLeS16().

◆ LoadS24()

template<ByteOrder byte_order>
constexpr int32_t roo_io::LoadS24 ( const byte source)
inlineconstexpr

◆ LoadS24< kBigEndian >()

template<>
constexpr int32_t roo_io::LoadS24< kBigEndian > ( const byte source)
inlineconstexpr

Definition at line 280 of file load.h.

References LoadBeS24().

◆ LoadS24< kLittleEndian >()

template<>
constexpr int32_t roo_io::LoadS24< kLittleEndian > ( const byte source)
inlineconstexpr

Definition at line 285 of file load.h.

References LoadLeS24().

◆ LoadS32()

template<ByteOrder byte_order>
constexpr int32_t roo_io::LoadS32 ( const byte source)
inlineconstexpr

◆ LoadS32< kBigEndian >()

template<>
constexpr int32_t roo_io::LoadS32< kBigEndian > ( const byte source)
inlineconstexpr

Definition at line 290 of file load.h.

References LoadBeS32().

◆ LoadS32< kLittleEndian >()

template<>
constexpr int32_t roo_io::LoadS32< kLittleEndian > ( const byte source)
inlineconstexpr

Definition at line 295 of file load.h.

References LoadLeS32().

◆ LoadS64()

template<ByteOrder byte_order>
constexpr int64_t roo_io::LoadS64 ( const byte source)
inlineconstexpr

◆ LoadS64< kBigEndian >()

template<>
constexpr int64_t roo_io::LoadS64< kBigEndian > ( const byte source)
inlineconstexpr

Definition at line 300 of file load.h.

References LoadBeS64().

◆ LoadS64< kLittleEndian >()

template<>
constexpr int64_t roo_io::LoadS64< kLittleEndian > ( const byte source)
inlineconstexpr

Definition at line 305 of file load.h.

References LoadLeS64().

◆ LoadS8()

constexpr int8_t roo_io::LoadS8 ( const byte source)
inlineconstexpr

Definition at line 61 of file load.h.

References LoadU8().

Referenced by LoadBeInteger< int8_t >(), and LoadLeInteger< int8_t >().

◆ LoadU16()

template<ByteOrder byte_order>
constexpr uint16_t roo_io::LoadU16 ( const byte source)
inlineconstexpr

◆ LoadU16< kBigEndian >()

template<>
constexpr uint16_t roo_io::LoadU16< kBigEndian > ( const byte source)
inlineconstexpr

Definition at line 230 of file load.h.

References LoadBeU16().

◆ LoadU16< kLittleEndian >()

template<>
constexpr uint16_t roo_io::LoadU16< kLittleEndian > ( const byte source)
inlineconstexpr

Definition at line 235 of file load.h.

References LoadLeU16().

◆ LoadU24()

template<ByteOrder byte_order>
constexpr uint32_t roo_io::LoadU24 ( const byte source)
inlineconstexpr

◆ LoadU24< kBigEndian >()

template<>
constexpr uint32_t roo_io::LoadU24< kBigEndian > ( const byte source)
inlineconstexpr

Definition at line 240 of file load.h.

References LoadBeU24().

◆ LoadU24< kLittleEndian >()

template<>
constexpr uint32_t roo_io::LoadU24< kLittleEndian > ( const byte source)
inlineconstexpr

Definition at line 245 of file load.h.

References LoadLeU24().

◆ LoadU32()

template<ByteOrder byte_order>
constexpr uint32_t roo_io::LoadU32 ( const byte source)
inlineconstexpr

◆ LoadU32< kBigEndian >()

template<>
constexpr uint32_t roo_io::LoadU32< kBigEndian > ( const byte source)
inlineconstexpr

Definition at line 250 of file load.h.

References LoadBeU32().

◆ LoadU32< kLittleEndian >()

template<>
constexpr uint32_t roo_io::LoadU32< kLittleEndian > ( const byte source)
inlineconstexpr

Definition at line 255 of file load.h.

References LoadLeU32().

◆ LoadU64()

template<ByteOrder byte_order>
constexpr uint64_t roo_io::LoadU64 ( const byte source)
inlineconstexpr

◆ LoadU64< kBigEndian >()

template<>
constexpr uint64_t roo_io::LoadU64< kBigEndian > ( const byte source)
inlineconstexpr

Definition at line 260 of file load.h.

References LoadBeU64().

◆ LoadU64< kLittleEndian >()

template<>
constexpr uint64_t roo_io::LoadU64< kLittleEndian > ( const byte source)
inlineconstexpr

Definition at line 265 of file load.h.

References LoadLeU64().

◆ LoadU8()

◆ MkDirRecursively()

Status roo_io::MkDirRecursively ( roo_io::Mount fs,
const char path 
)

◆ MkParentDirRecursively()

Status roo_io::MkParentDirRecursively ( roo_io::Mount fs,
const char path 
)

Definition at line 63 of file fsutil.cpp.

References roo_io::Stat::exists(), kDirectoryExists, kNotFound, kOk, and roo_io::Stat::status().

◆ NibbleFill()

void roo_io::NibbleFill ( byte buf,
uint32_t  offset,
size_t  count,
byte  value 
)
inline

Definition at line 302 of file fill.h.

References count.

◆ OpenDataFile()

MultipassInputStreamReader roo_io::OpenDataFile ( roo_io::Mount fs,
const char path 
)

Definition at line 85 of file fsutil.cpp.

◆ OpenDataFileForWrite()

OutputStreamWriter roo_io::OpenDataFileForWrite ( roo_io::Mount fs,
const char path,
roo_io::FileUpdatePolicy  update_policy 
)

Definition at line 89 of file fsutil.cpp.

◆ operator!=()

Definition at line 30 of file mac_address.cpp.

◆ operator<()

Definition at line 34 of file mac_address.cpp.

◆ operator<<() [1/2]

roo_logging::Stream & roo_io::operator<< ( roo_logging::Stream &  s,
const MacAddress addr 
)

Definition at line 50 of file mac_address.cpp.

◆ operator<<() [2/2]

roo_logging::Stream & roo_io::operator<< ( roo_logging::Stream &  s,
Status  status 
)
inline

Definition at line 75 of file status.h.

References StatusAsString().

◆ operator<=()

Definition at line 42 of file mac_address.cpp.

◆ operator==()

Definition at line 26 of file mac_address.cpp.

◆ operator>()

Definition at line 38 of file mac_address.cpp.

◆ operator>=()

Definition at line 46 of file mac_address.cpp.

◆ OutputError()

std::unique_ptr< OutputStream > roo_io::OutputError ( Status  error)

Definition at line 45 of file mount_impl.cpp.

Referenced by roo_io::Mount::fopenForWrite().

◆ PatternCompare()

template<int bytes>
bool roo_io::PatternCompare ( const byte buf,
size_t  count,
const byte val 
)
inline

◆ PatternCompare< 1 >()

template<>
bool roo_io::PatternCompare< 1 > ( const byte buf,
size_t  count,
const byte val 
)
inline

Definition at line 23 of file compare.h.

References count.

Referenced by PatternCompareAligned< 1 >().

◆ PatternCompareAligned()

template<int bytes>
bool roo_io::PatternCompareAligned ( const byte buf,
size_t  count,
const byte val 
)
inline

◆ PatternCompareAligned< 1 >()

template<>
bool roo_io::PatternCompareAligned< 1 > ( const byte buf,
size_t  count,
const byte val 
)
inline

Definition at line 38 of file compare.h.

References count, and PatternCompare< 1 >().

◆ PatternFill()

template<int bytes>
void roo_io::PatternFill ( byte buf,
size_t  count,
const byte val 
)
inline

◆ PatternFill< 1 >()

template<>
void roo_io::PatternFill< 1 > ( byte buf,
size_t  count,
const byte val 
)
inline

Definition at line 44 of file fill.h.

References count.

◆ PatternFill< 2 >()

template<>
void roo_io::PatternFill< 2 > ( byte buf,
size_t  count,
const byte val 
)
inline

Definition at line 101 of file fill.h.

References count, and roo_io::internal::pattern_fill_16_aligned().

◆ PatternFill< 3 >()

template<>
void roo_io::PatternFill< 3 > ( byte buf,
size_t  count,
const byte val 
)
inline

Definition at line 152 of file fill.h.

References count.

◆ PatternFill< 4 >()

template<>
void roo_io::PatternFill< 4 > ( byte buf,
size_t  count,
const byte val 
)
inline

Definition at line 240 of file fill.h.

References count, and roo_io::internal::pattern_fill_32_aligned().

◆ PatternWrite()

template<int bytes>
void roo_io::PatternWrite ( byte buf,
const byte val 
)
inline

◆ PatternWrite< 1 >()

template<>
void roo_io::PatternWrite< 1 > ( byte buf,
const byte val 
)
inline

Definition at line 19 of file fill.h.

◆ PatternWrite< 2 >()

template<>
void roo_io::PatternWrite< 2 > ( byte buf,
const byte val 
)
inline

Definition at line 24 of file fill.h.

◆ PatternWrite< 3 >()

template<>
void roo_io::PatternWrite< 3 > ( byte buf,
const byte val 
)
inline

Definition at line 29 of file fill.h.

◆ PatternWrite< 4 >()

template<>
void roo_io::PatternWrite< 4 > ( byte buf,
const byte val 
)
inline

Definition at line 36 of file fill.h.

◆ ReadBeS16()

◆ ReadBeS24()

◆ ReadBeS32()

◆ ReadBeS64()

◆ ReadBeU16()

◆ ReadBeU24()

◆ ReadBeU32()

◆ ReadBeU64()

◆ ReadByteArray()

template<typename InputIterator >
size_t roo_io::ReadByteArray ( InputIterator in,
byte result,
size_t  count 
)

◆ ReadCString()

template<typename InputIterator >
size_t roo_io::ReadCString ( InputIterator in,
char buf,
size_t  capacity = SIZE_MAX 
)

◆ ReadLeS16()

◆ ReadLeS24()

◆ ReadLeS32()

◆ ReadLeS64()

◆ ReadLeU16()

◆ ReadLeU24()

◆ ReadLeU32()

◆ ReadLeU64()

◆ ReadMacAddress()

template<typename InputIterator >
MacAddress roo_io::ReadMacAddress ( InputIterator itr)

Definition at line 65 of file mac_address.h.

◆ ReadS8()

template<typename InputIterator >
constexpr int8_t roo_io::ReadS8 ( InputIterator in)
constexpr

◆ ReadString()

template<typename InputIterator >
std::string roo_io::ReadString ( InputIterator in,
size_t  max_size = SIZE_MAX 
)

◆ ReadStringView()

template<typename InputIterator , typename std::enable_if< internal::MemoryIteratorTraits< InputIterator >::is_memory, bool >::type = true>
roo::string_view roo_io::ReadStringView ( InputIterator in,
size_t  max_size = SIZE_MAX 
)

Definition at line 493 of file read.h.

References kOk, and ReadVarU64().

◆ ReadU16()

template<typename InputIterator , ByteOrder byte_order>
constexpr uint16_t roo_io::ReadU16 ( InputIterator in)
constexpr

Definition at line 369 of file read.h.

◆ ReadU24()

template<typename InputIterator , ByteOrder byte_order>
constexpr uint32_t roo_io::ReadU24 ( InputIterator in)
constexpr

Definition at line 374 of file read.h.

◆ ReadU32()

template<typename InputIterator , ByteOrder byte_order>
constexpr uint32_t roo_io::ReadU32 ( InputIterator in)
constexpr

Definition at line 379 of file read.h.

◆ ReadU64()

template<typename InputIterator , ByteOrder byte_order>
constexpr uint64_t roo_io::ReadU64 ( InputIterator in)
constexpr

Definition at line 384 of file read.h.

◆ ReadU8()

template<typename InputIterator >
constexpr uint8_t roo_io::ReadU8 ( InputIterator in)
constexpr

◆ ReadVarU64()

◆ StatusAsString()

◆ StoreBeS16()

void roo_io::StoreBeS16 ( uint16_t  v,
byte target 
)
inline

Definition at line 91 of file store.h.

References StoreBeU16().

Referenced by StoreS16< kBigEndian >().

◆ StoreBeS24()

void roo_io::StoreBeS24 ( uint32_t  v,
byte target 
)
inline

Definition at line 97 of file store.h.

References StoreBeU24().

Referenced by StoreS24< kBigEndian >().

◆ StoreBeS32()

void roo_io::StoreBeS32 ( uint32_t  v,
byte target 
)
inline

Definition at line 103 of file store.h.

References StoreBeU32().

Referenced by StoreS32< kBigEndian >().

◆ StoreBeS64()

void roo_io::StoreBeS64 ( uint64_t  v,
byte target 
)
inline

Definition at line 109 of file store.h.

References StoreBeU64().

Referenced by StoreS64< kBigEndian >().

◆ StoreBeU16()

void roo_io::StoreBeU16 ( uint16_t  v,
byte target 
)
inline

◆ StoreBeU24()

void roo_io::StoreBeU24 ( uint32_t  v,
byte target 
)
inline

Definition at line 32 of file store.h.

Referenced by StoreBeS24(), and StoreU24< kBigEndian >().

◆ StoreBeU32()

void roo_io::StoreBeU32 ( uint32_t  v,
byte target 
)
inline

◆ StoreBeU64()

void roo_io::StoreBeU64 ( uint64_t  v,
byte target 
)
inline

◆ StoreHostNative()

template<typename T >
void roo_io::StoreHostNative ( const T v,
byte target 
)
inline

Definition at line 165 of file store.h.

◆ StoreInteger()

template<ByteOrder byte_order, typename IntegerType >
void roo_io::StoreInteger ( IntegerType  v,
byte target 
)
inline

◆ StoreInteger< kBigEndian, int8_t >()

template<>
void roo_io::StoreInteger< kBigEndian, int8_t > ( int8_t  v,
byte target 
)
inline

Definition at line 334 of file store.h.

References StoreS8().

◆ StoreInteger< kBigEndian, uint16_t >()

template<>
void roo_io::StoreInteger< kBigEndian, uint16_t > ( uint16_t  v,
byte target 
)
inline

Definition at line 344 of file store.h.

References StoreBeU16().

◆ StoreInteger< kBigEndian, uint32_t >()

template<>
void roo_io::StoreInteger< kBigEndian, uint32_t > ( uint32_t  v,
byte target 
)
inline

Definition at line 354 of file store.h.

References StoreBeU32().

◆ StoreInteger< kBigEndian, uint64_t >()

template<>
void roo_io::StoreInteger< kBigEndian, uint64_t > ( uint64_t  v,
byte target 
)
inline

Definition at line 364 of file store.h.

References StoreBeU64().

◆ StoreInteger< kBigEndian, uint8_t >()

template<>
void roo_io::StoreInteger< kBigEndian, uint8_t > ( uint8_t  v,
byte target 
)
inline

Definition at line 324 of file store.h.

References StoreU8().

◆ StoreInteger< kLittleEndian, int8_t >()

template<>
void roo_io::StoreInteger< kLittleEndian, int8_t > ( int8_t  v,
byte target 
)
inline

Definition at line 339 of file store.h.

References StoreS8().

◆ StoreInteger< kLittleEndian, uint16_t >()

template<>
void roo_io::StoreInteger< kLittleEndian, uint16_t > ( uint16_t  v,
byte target 
)
inline

Definition at line 349 of file store.h.

References StoreLeU16().

◆ StoreInteger< kLittleEndian, uint32_t >()

template<>
void roo_io::StoreInteger< kLittleEndian, uint32_t > ( uint32_t  v,
byte target 
)
inline

Definition at line 359 of file store.h.

References StoreLeU32().

◆ StoreInteger< kLittleEndian, uint64_t >()

template<>
void roo_io::StoreInteger< kLittleEndian, uint64_t > ( uint64_t  v,
byte target 
)
inline

Definition at line 369 of file store.h.

References StoreLeU64().

◆ StoreInteger< kLittleEndian, uint8_t >()

template<>
void roo_io::StoreInteger< kLittleEndian, uint8_t > ( uint8_t  v,
byte target 
)
inline

Definition at line 329 of file store.h.

References StoreU8().

◆ StoreLeS16()

void roo_io::StoreLeS16 ( uint16_t  v,
byte target 
)
inline

Definition at line 94 of file store.h.

References StoreLeU16().

Referenced by StoreS16< kLittleEndian >().

◆ StoreLeS24()

void roo_io::StoreLeS24 ( uint32_t  v,
byte target 
)
inline

Definition at line 100 of file store.h.

References StoreLeU24().

Referenced by StoreS24< kLittleEndian >().

◆ StoreLeS32()

void roo_io::StoreLeS32 ( uint32_t  v,
byte target 
)
inline

Definition at line 106 of file store.h.

References StoreLeU32().

Referenced by StoreS32< kLittleEndian >().

◆ StoreLeS64()

void roo_io::StoreLeS64 ( uint64_t  v,
byte target 
)
inline

Definition at line 112 of file store.h.

References StoreLeU64().

Referenced by StoreS64< kLittleEndian >().

◆ StoreLeU16()

void roo_io::StoreLeU16 ( uint16_t  v,
byte target 
)
inline

◆ StoreLeU24()

void roo_io::StoreLeU24 ( uint32_t  v,
byte target 
)
inline

Definition at line 39 of file store.h.

Referenced by StoreLeS24(), and StoreU24< kLittleEndian >().

◆ StoreLeU32()

void roo_io::StoreLeU32 ( uint32_t  v,
byte target 
)
inline

◆ StoreLeU64()

void roo_io::StoreLeU64 ( uint64_t  v,
byte target 
)
inline

◆ StoreS16()

template<ByteOrder byte_order>
void roo_io::StoreS16 ( int16_t  v,
byte target 
)
inline

◆ StoreS16< kBigEndian >()

template<>
void roo_io::StoreS16< kBigEndian > ( int16_t  v,
byte target 
)
inline

Definition at line 262 of file store.h.

References StoreBeS16().

◆ StoreS16< kLittleEndian >()

template<>
void roo_io::StoreS16< kLittleEndian > ( int16_t  v,
byte target 
)
inline

Definition at line 267 of file store.h.

References StoreLeS16().

◆ StoreS24()

template<ByteOrder byte_order>
void roo_io::StoreS24 ( int32_t  v,
byte target 
)
inline

◆ StoreS24< kBigEndian >()

template<>
void roo_io::StoreS24< kBigEndian > ( int32_t  v,
byte target 
)
inline

Definition at line 272 of file store.h.

References StoreBeS24().

◆ StoreS24< kLittleEndian >()

template<>
void roo_io::StoreS24< kLittleEndian > ( int32_t  v,
byte target 
)
inline

Definition at line 277 of file store.h.

References StoreLeS24().

◆ StoreS32()

template<ByteOrder byte_order>
void roo_io::StoreS32 ( int32_t  v,
byte target 
)
inline

◆ StoreS32< kBigEndian >()

template<>
void roo_io::StoreS32< kBigEndian > ( int32_t  v,
byte target 
)
inline

Definition at line 282 of file store.h.

References StoreBeS32().

◆ StoreS32< kLittleEndian >()

template<>
void roo_io::StoreS32< kLittleEndian > ( int32_t  v,
byte target 
)
inline

Definition at line 287 of file store.h.

References StoreLeS32().

◆ StoreS64()

template<ByteOrder byte_order>
void roo_io::StoreS64 ( int64_t  v,
byte target 
)
inline

◆ StoreS64< kBigEndian >()

template<>
void roo_io::StoreS64< kBigEndian > ( int64_t  v,
byte target 
)
inline

Definition at line 292 of file store.h.

References StoreBeS64().

◆ StoreS64< kLittleEndian >()

template<>
void roo_io::StoreS64< kLittleEndian > ( int64_t  v,
byte target 
)
inline

Definition at line 297 of file store.h.

References StoreLeS64().

◆ StoreS8()

void roo_io::StoreS8 ( int8_t  v,
byte target 
)
inline

Definition at line 88 of file store.h.

References StoreU8().

Referenced by StoreInteger< kBigEndian, int8_t >(), and StoreInteger< kLittleEndian, int8_t >().

◆ StoreU16()

template<ByteOrder byte_order>
void roo_io::StoreU16 ( uint16_t  v,
byte target 
)
inline

◆ StoreU16< kBigEndian >()

template<>
void roo_io::StoreU16< kBigEndian > ( uint16_t  v,
byte target 
)
inline

Definition at line 222 of file store.h.

References StoreBeU16().

◆ StoreU16< kLittleEndian >()

template<>
void roo_io::StoreU16< kLittleEndian > ( uint16_t  v,
byte target 
)
inline

Definition at line 227 of file store.h.

References StoreLeU16().

◆ StoreU24()

template<ByteOrder byte_order>
void roo_io::StoreU24 ( uint32_t  v,
byte target 
)
inline

◆ StoreU24< kBigEndian >()

template<>
void roo_io::StoreU24< kBigEndian > ( uint32_t  v,
byte target 
)
inline

Definition at line 232 of file store.h.

References StoreBeU24().

◆ StoreU24< kLittleEndian >()

template<>
void roo_io::StoreU24< kLittleEndian > ( uint32_t  v,
byte target 
)
inline

Definition at line 237 of file store.h.

References StoreLeU24().

◆ StoreU32()

template<ByteOrder byte_order>
void roo_io::StoreU32 ( uint32_t  v,
byte target 
)
inline

◆ StoreU32< kBigEndian >()

template<>
void roo_io::StoreU32< kBigEndian > ( uint32_t  v,
byte target 
)
inline

Definition at line 242 of file store.h.

References StoreBeU32().

◆ StoreU32< kLittleEndian >()

template<>
void roo_io::StoreU32< kLittleEndian > ( uint32_t  v,
byte target 
)
inline

Definition at line 247 of file store.h.

References StoreLeU32().

◆ StoreU64()

template<ByteOrder byte_order>
void roo_io::StoreU64 ( uint64_t  v,
byte target 
)
inline

◆ StoreU64< kBigEndian >()

template<>
void roo_io::StoreU64< kBigEndian > ( uint64_t  v,
byte target 
)
inline

Definition at line 252 of file store.h.

References StoreBeU64().

◆ StoreU64< kLittleEndian >()

template<>
void roo_io::StoreU64< kLittleEndian > ( uint64_t  v,
byte target 
)
inline

Definition at line 257 of file store.h.

References StoreLeU64().

◆ StoreU8()

void roo_io::StoreU8 ( uint8_t  v,
byte target 
)
inline

◆ StringPrintf()

std::string roo_io::StringPrintf ( const char format,
  ... 
)

Definition at line 7 of file string_printf.cpp.

References StringVPrintf().

Referenced by roo_io::MacAddress::asString().

◆ StringVPrintf()

std::string roo_io::StringVPrintf ( const char format,
va_list  arg 
)

Definition at line 15 of file string_printf.cpp.

Referenced by StringPrintf().

◆ toh()

template<typename storage_type , ByteOrder src>
constexpr storage_type roo_io::toh ( storage_type  in)
constexpr

Definition at line 111 of file byte_order.h.

◆ WriteBeS16()

constexpr void roo_io::WriteBeS16 ( OutputIterator out,
int16_t  v 
)
constexpr

Definition at line 95 of file write.h.

References WriteBeU16().

Referenced by roo_io::OutputStreamWriter::writeBeS16().

◆ WriteBeS24()

constexpr void roo_io::WriteBeS24 ( OutputIterator out,
int32_t  v 
)
constexpr

Definition at line 107 of file write.h.

References WriteBeU24().

Referenced by roo_io::OutputStreamWriter::writeBeS24().

◆ WriteBeS32()

constexpr void roo_io::WriteBeS32 ( OutputIterator out,
int32_t  v 
)
constexpr

Definition at line 119 of file write.h.

References WriteBeU32().

Referenced by roo_io::OutputStreamWriter::writeBeS32().

◆ WriteBeS64()

constexpr void roo_io::WriteBeS64 ( OutputIterator out,
int64_t  v 
)
constexpr

Definition at line 131 of file write.h.

References WriteBeU64().

Referenced by roo_io::OutputStreamWriter::writeBeS64().

◆ WriteBeU16()

constexpr void roo_io::WriteBeU16 ( OutputIterator out,
uint16_t  v 
)
constexpr

◆ WriteBeU24()

constexpr void roo_io::WriteBeU24 ( OutputIterator out,
uint32_t  v 
)
constexpr

◆ WriteBeU32()

◆ WriteBeU64()

constexpr void roo_io::WriteBeU64 ( OutputIterator out,
uint64_t  v 
)
constexpr

Definition at line 73 of file write.h.

References WriteBeU32().

Referenced by WriteBeS64(), and roo_io::OutputStreamWriter::writeBeU64().

◆ WriteByteArray()

size_t roo_io::WriteByteArray ( OutputIterator out,
const byte source,
size_t  count 
)

◆ WriteLeS16()

constexpr void roo_io::WriteLeS16 ( OutputIterator out,
int16_t  v 
)
constexpr

Definition at line 101 of file write.h.

References WriteLeU16().

Referenced by roo_io::OutputStreamWriter::writeLeS16().

◆ WriteLeS24()

constexpr void roo_io::WriteLeS24 ( OutputIterator out,
int32_t  v 
)
constexpr

Definition at line 113 of file write.h.

References WriteLeU24().

Referenced by roo_io::OutputStreamWriter::writeLeS24().

◆ WriteLeS32()

constexpr void roo_io::WriteLeS32 ( OutputIterator out,
int32_t  v 
)
constexpr

Definition at line 125 of file write.h.

References WriteLeU32().

Referenced by roo_io::OutputStreamWriter::writeLeS32().

◆ WriteLeS64()

constexpr void roo_io::WriteLeS64 ( OutputIterator out,
int64_t  v 
)
constexpr

Definition at line 137 of file write.h.

References WriteLeU64().

Referenced by roo_io::OutputStreamWriter::writeLeS64().

◆ WriteLeU16()

constexpr void roo_io::WriteLeU16 ( OutputIterator out,
uint16_t  v 
)
constexpr

◆ WriteLeU24()

constexpr void roo_io::WriteLeU24 ( OutputIterator out,
uint32_t  v 
)
constexpr

◆ WriteLeU32()

◆ WriteLeU64()

constexpr void roo_io::WriteLeU64 ( OutputIterator out,
uint64_t  v 
)
constexpr

Definition at line 80 of file write.h.

References WriteLeU32().

Referenced by WriteLeS64(), and roo_io::OutputStreamWriter::writeLeU64().

◆ WriteMacAddress()

void roo_io::WriteMacAddress ( OutputIterator itr,
const MacAddress addr 
)

Definition at line 72 of file mac_address.h.

◆ WriteS8()

constexpr void roo_io::WriteS8 ( OutputIterator out,
int8_t  v 
)
constexpr

Definition at line 89 of file write.h.

References WriteU8().

Referenced by roo_io::OutputStreamWriter::writeS8().

◆ WriteString() [1/2]

void roo_io::WriteString ( OutputIterator itr,
const char data 
)

Definition at line 244 of file write.h.

References WriteString().

◆ WriteString() [2/2]

void roo_io::WriteString ( OutputIterator itr,
roo::string_view  data 
)

Definition at line 232 of file write.h.

References WriteByteArray(), and WriteVarU64().

Referenced by WriteString(), and roo_io::OutputStreamWriter::writeString().

◆ WriteU16()

template<typename OutputIterator , ByteOrder byte_order>
constexpr void roo_io::WriteU16 ( OutputIterator in,
uint16_t  v 
)
constexpr

Definition at line 337 of file write.h.

◆ WriteU24()

template<typename OutputIterator , ByteOrder byte_order>
constexpr void roo_io::WriteU24 ( OutputIterator in,
uint32_t  v 
)
constexpr

Definition at line 342 of file write.h.

◆ WriteU32()

template<typename OutputIterator , ByteOrder byte_order>
constexpr void roo_io::WriteU32 ( OutputIterator in,
uint32_t  v 
)
constexpr

Definition at line 347 of file write.h.

◆ WriteU8()

constexpr void roo_io::WriteU8 ( OutputIterator out,
uint8_t  v 
)
constexpr

Definition at line 19 of file write.h.

Referenced by WriteS8(), and roo_io::OutputStreamWriter::writeU8().

◆ WriteUtf8Char() [1/3]

int roo_io::WriteUtf8Char ( byte buf,
char32_t  ch 
)
inline

Definition at line 94 of file unicode.h.

◆ WriteUtf8Char() [2/3]

int roo_io::WriteUtf8Char ( char buf,
char32_t  ch 
)
inline

Definition at line 123 of file unicode.h.

References WriteUtf8Char().

◆ WriteUtf8Char() [3/3]

void roo_io::WriteUtf8Char ( OutputIterator itr,
char32_t  v 
)

Definition at line 73 of file unicode.h.

Referenced by WriteUtf8Char().

◆ WriteVarU64()

void roo_io::WriteVarU64 ( OutputIterator out,
uint64_t  data 
)

Definition at line 212 of file write.h.

Referenced by WriteString(), and roo_io::OutputStreamWriter::writeVarU64().

Variable Documentation

◆ count

size_t roo_io::count

Definition at line 45 of file compare.h.

Referenced by BitFill(), NibbleFill(), roo_io::internal::pattern_fill_16_aligned(), roo_io::internal::pattern_fill_32_aligned(), PatternCompare< 1 >(), PatternCompareAligned< 1 >(), PatternFill< 1 >(), PatternFill< 2 >(), PatternFill< 3 >(), PatternFill< 4 >(), roo_io::BufferedInputStreamIterator::read(), roo_io::BufferedMultipassInputStreamIterator::read(), roo_io::FileIterable::FileIterator::read(), roo_io::MemoryInputStream< PtrType >::read(), roo_io::UnsafeGenericMemoryIterator< PtrTypeT >::read(), roo_io::SafeGenericMemoryIterator< PtrTypeT >::read(), roo_io::MultipassGenericMemoryIterator< PtrTypeT >::read(), roo_io::InputStreamReader::readByteArray(), roo_io::MultipassInputStreamReader::readByteArray(), ReadByteArray(), roo_io::InputStream::readFully(), roo_io::BufferedInputStreamIterator::skip(), roo_io::BufferedMultipassInputStreamIterator::skip(), roo_io::InputStreamReader::skip(), roo_io::MultipassInputStreamReader::skip(), roo_io::FileIterable::FileIterator::skip(), roo_io::UnsafeGenericMemoryIterator< PtrTypeT >::skip(), roo_io::SafeGenericMemoryIterator< PtrTypeT >::skip(), roo_io::MultipassGenericMemoryIterator< PtrTypeT >::skip(), roo_io::InputStream::skip(), roo_io::MemoryInputStream< PtrType >::skip(), roo_io::InputStream::tryRead(), roo_io::OutputStream::tryWrite(), roo_io::BufferedOutputStreamIterator::write(), roo_io::UnsafeMemoryOutputIterator::write(), roo_io::MemoryOutputIterator::write(), roo_io::BackInsertingIterator< Collection >::write(), roo_io::MemoryOutputStream< PtrType >::write(), roo_io::OutputStreamWriter::writeByteArray(), WriteByteArray(), and roo_io::OutputStream::writeFully().

◆ kInputStreamIteratorBufferSize

◆ kMultipassInputStreamIteratorBufferSize

◆ kOutputStreamIteratorBufferSize