MCPcopy Create free account
hub / github.com/MITK/MITK / InputStream

Method InputStream

Modules/Core/src/IO/mitkAbstractFileReader.cpp:33–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

31namespace mitk
32{
33 AbstractFileReader::InputStream::InputStream(IFileReader *reader, std::ios_base::openmode mode)
34 : std::istream(nullptr), m_Stream(nullptr)
35 {
36 std::istream *stream = reader->GetInputStream();
37 if (stream)
38 {
39 this->init(stream->rdbuf());
40 }
41 else
42 {
43 m_Stream = new std::ifstream(reader->GetInputLocation().c_str(), mode);
44 this->init(m_Stream->rdbuf());
45 }
46 }
47
48 AbstractFileReader::InputStream::~InputStream() { delete m_Stream; }
49 class AbstractFileReader::Impl : public FileReaderWriterBase

Callers

nothing calls this directly

Calls 3

GetInputStreamMethod · 0.80
GetInputLocationMethod · 0.80
initMethod · 0.45

Tested by

no test coverage detected