7 #include <boost/iostreams/device/array.hpp> 8 #include <boost/iostreams/stream.hpp> 13 #include "fwMemory/stream/in/Buffer.hpp" 25 ::boost::iostreams::stream< ::boost::iostreams::array_source >(buf, size),
30 Buffer::LockType m_counter;
33 Buffer::LockType noFactory()
35 return Buffer::LockType();
38 Buffer::Buffer(
void* buf,
size_t size) :
39 m_buf(buf), m_size(size), m_counterFactory(&noFactory)
44 Buffer::Buffer(
void* buf,
size_t size, CounterFactoryType counterFactory) :
45 m_buf(buf), m_size(size), m_counterFactory(counterFactory)
50 SPTR(std::istream) Buffer::get()
52 namespace io = boost::iostreams;
55 SPTR( ArrayStreamType ) arrayInStream
56 = std::make_shared< ArrayStreamType > (
static_cast<char *
>(m_buf), m_size, m_counterFactory() );
#define OSLM_ASSERT(message, cond)
work like 'assert' from 'cassert', with in addition a message logged by spylog (with FATAL loglevel) ...
The namespace fwMemory contains tools to manage memory. Use for dump.
This file defines fwCore base macros.
This file defines SpyLog macros. These macros are used to log messages to a file or to the console du...