PDFTool 7.0
PdfTk::PtlParamInput Class Reference

ファイルやストリームの入力指定に使うパラメータクラスです。
More...

#include <PtlParamInput.h>

Inheritance diagram for PdfTk::PtlParamInput:
Collaboration diagram for PdfTk::PtlParamInput:

Public Member Functions

int getHandle () const
 PtlParamInput ()
 コンストラクタ
 PtlParamInput (const PtlParamString &path)
 コンストラクタ
 PtlParamInput (const PtlParamString &path, InputStream *inStream)
 コンストラクタ
 PtlParamInput (const PtlParamInput &obj)
 コピーコンストラクタ
 ‾PtlParamInput ()
 デストラクタ
PtlParamInputoperator= (const PtlParamInput &obj)
 コピーオペレータ
bool open ()
 入力ストリームのオープン。
void close ()
 ストリームのクローズ。
int read (char *pBuf, int len)
 入力ストリームの読み込み。
long seekoff (long off, int way, int which)
 入力ストリーム内の移動。
PtlParamString getPath () const
 パスを取得。
InputStream & getStream () const
 InputStreamを取得。
Public Member Functions inherited from PdfTk::PtlParamStream
 PtlParamStream ()
 コンストラクタ
virtual ‾PtlParamStream ()
 デストラクタ
bool canRead () const
 入力ストリームの読み込み可能かを取得。
bool canWrite () const
 出力ストリームの書き込み可能かを取得。
virtual int write (char *pBuf, int len)
 出力ストリームの書き込み。

Additional Inherited Members

Protected Attributes inherited from PdfTk::PtlParamStream
bool m_canRead
bool m_canWrite

Detailed Description

ファイルやストリームの入力指定に使うパラメータクラスです。

パス(ファイル)名を指定して、ストリームを指定しない場合、パス(ファイル)名を使って、ストリームをオープンします。
ストリームを指定した場合、パス(ファイル)名はエラーメッセージの表示などに使われる情報として扱われ、 パス(ファイル)名でストリームをオープンすることはありません。

Constructor & Destructor Documentation

◆ PtlParamInput() [1/4]

PdfTk::PtlParamInput::PtlParamInput ( )

コンストラクタ

Exceptions
PtlException

◆ PtlParamInput() [2/4]

PdfTk::PtlParamInput::PtlParamInput ( const PtlParamString & path)

コンストラクタ

Parameters
pathパス。
Exceptions
PtlException

◆ PtlParamInput() [3/4]

PdfTk::PtlParamInput::PtlParamInput ( const PtlParamString & path,
InputStream * inStream )

コンストラクタ

Parameters
pathパス。
inStreamストリーム。
Exceptions
PtlException

◆ PtlParamInput() [4/4]

PdfTk::PtlParamInput::PtlParamInput ( const PtlParamInput & obj)

コピーコンストラクタ

Parameters
objコピー元オブジェクト。
Exceptions
PtlException

Member Function Documentation

◆ close()

void PdfTk::PtlParamInput::close ( )
virtual

ストリームのクローズ。

Exceptions
PtlException

Reimplemented from PdfTk::PtlParamStream.

◆ getPath()

PtlParamString PdfTk::PtlParamInput::getPath ( ) const
virtual

パスを取得。

Implements PdfTk::PtlParamStream.

◆ getStream()

InputStream & PdfTk::PtlParamInput::getStream ( ) const

InputStreamを取得。

Returns
InputStream
Exceptions
PtlException

◆ open()

bool PdfTk::PtlParamInput::open ( )
virtual

入力ストリームのオープン。

Returns
オープンできた場合はtrue
Exceptions
PtlException

Implements PdfTk::PtlParamStream.

◆ operator=()

PtlParamInput & PdfTk::PtlParamInput::operator= ( const PtlParamInput & obj)

コピーオペレータ

Parameters
objコピー元オブジェクト。

◆ read()

int PdfTk::PtlParamInput::read ( char * pBuf,
int len )
virtual

入力ストリームの読み込み。

Parameters
pBuf読み込んだデータを格納するバッファ
len読み込むサイズ
Returns
読み込んだサイズ
読み込みに失敗した時は-1
Exceptions
PtlException

Reimplemented from PdfTk::PtlParamStream.

◆ seekoff()

long PdfTk::PtlParamInput::seekoff ( long off,
int way,
int which )
virtual

入力ストリーム内の移動。

Parameters
off基準位置からのオフセット
way基準位置
0:入力ストリームの先頭を基準とします。
1:現在の位置を基準とします。
2:入力ストリームの末尾を基準とします。
which未使用
Returns
現在の位置
移動に失敗した時は-1
Exceptions
PtlException

Reimplemented from PdfTk::PtlParamStream.