LibreOffice Module ucbhelper (master) 1
Public Member Functions | Private Attributes | List of all members
ucbhelper::FdInputStream Class Referencefinal

Implements a seekable InputStream working on a buffer. More...

#include <fd_inputstream.hxx>

Inheritance diagram for ucbhelper::FdInputStream:
[legend]
Collaboration diagram for ucbhelper::FdInputStream:
[legend]

Public Member Functions

 FdInputStream (oslFileHandle tmpfl)
 Defines the storage kind found on which the inputstream acts. More...
 
virtual ~FdInputStream () override
 
virtual sal_Int32 SAL_CALL readBytes (css::uno::Sequence< sal_Int8 > &aData, sal_Int32 nBytesToRead) override
 
virtual sal_Int32 SAL_CALL readSomeBytes (css::uno::Sequence< sal_Int8 > &aData, sal_Int32 nMaxBytesToRead) override
 
virtual void SAL_CALL skipBytes (sal_Int32 nBytesToSkip) override
 
virtual sal_Int32 SAL_CALL available () override
 
virtual void SAL_CALL closeInput () override
 
virtual void SAL_CALL seek (sal_Int64 location) override
 XSeekable. More...
 
virtual sal_Int64 SAL_CALL getPosition () override
 
virtual sal_Int64 SAL_CALL getLength () override
 

Private Attributes

std::mutex m_aMutex
 
oslFileHandle m_tmpfl
 
sal_uInt64 m_nLength
 

Detailed Description

Implements a seekable InputStream working on a buffer.

Definition at line 39 of file fd_inputstream.hxx.

Constructor & Destructor Documentation

◆ FdInputStream()

ucbhelper::FdInputStream::FdInputStream ( oslFileHandle  tmpfl)

Defines the storage kind found on which the inputstream acts.

Definition at line 33 of file fd_inputstream.cxx.

References m_nLength, m_nLength, m_tmpfl, and SAL_WARN_IF.

◆ ~FdInputStream()

ucbhelper::FdInputStream::~FdInputStream ( )
overridevirtual

Definition at line 51 of file fd_inputstream.cxx.

References m_tmpfl.

Member Function Documentation

◆ available()

sal_Int32 SAL_CALL ucbhelper::FdInputStream::available ( )
overridevirtual

Definition at line 99 of file fd_inputstream.cxx.

References getPosition(), m_nLength, and SAL_MAX_INT32.

◆ closeInput()

void SAL_CALL ucbhelper::FdInputStream::closeInput ( )
overridevirtual

Definition at line 105 of file fd_inputstream.cxx.

References m_aMutex, and m_tmpfl.

◆ getLength()

sal_Int64 SAL_CALL ucbhelper::FdInputStream::getLength ( )
overridevirtual

Definition at line 140 of file fd_inputstream.cxx.

References m_nLength.

◆ getPosition()

sal_Int64 SAL_CALL ucbhelper::FdInputStream::getPosition ( )
overridevirtual

Definition at line 128 of file fd_inputstream.cxx.

References m_aMutex, and m_tmpfl.

Referenced by available().

◆ readBytes()

sal_Int32 SAL_CALL ucbhelper::FdInputStream::readBytes ( css::uno::Sequence< sal_Int8 > &  aData,
sal_Int32  nBytesToRead 
)
overridevirtual

Definition at line 57 of file fd_inputstream.cxx.

References aData, m_aMutex, m_nLength, and m_tmpfl.

Referenced by readSomeBytes().

◆ readSomeBytes()

sal_Int32 SAL_CALL ucbhelper::FdInputStream::readSomeBytes ( css::uno::Sequence< sal_Int8 > &  aData,
sal_Int32  nMaxBytesToRead 
)
overridevirtual

Definition at line 81 of file fd_inputstream.cxx.

References aData, and readBytes().

◆ seek()

void SAL_CALL ucbhelper::FdInputStream::seek ( sal_Int64  location)
overridevirtual

XSeekable.

Definition at line 116 of file fd_inputstream.cxx.

References m_aMutex, m_tmpfl, and SAL_WARN_IF.

◆ skipBytes()

void SAL_CALL ucbhelper::FdInputStream::skipBytes ( sal_Int32  nBytesToSkip)
overridevirtual

Definition at line 88 of file fd_inputstream.cxx.

References m_aMutex, m_tmpfl, and SAL_WARN_IF.

Member Data Documentation

◆ m_aMutex

std::mutex ucbhelper::FdInputStream::m_aMutex
private

Definition at line 83 of file fd_inputstream.hxx.

Referenced by closeInput(), getPosition(), readBytes(), seek(), and skipBytes().

◆ m_nLength

sal_uInt64 ucbhelper::FdInputStream::m_nLength
private

Definition at line 85 of file fd_inputstream.hxx.

Referenced by available(), FdInputStream(), getLength(), and readBytes().

◆ m_tmpfl

oslFileHandle ucbhelper::FdInputStream::m_tmpfl
private

The documentation for this class was generated from the following files: