StringInputStream Class Reference
[Various accompanying utilities]

Inheritance diagram for StringInputStream:

Inheritance graph
[legend]

List of all members.

Public Member Functions

 __construct ($string)
 isEof ()
 mark ()
 
Returns:
StringInputStream

 markSupported ()
 reset ()
 
Returns:
StringInputStream

 close ()
 
Returns:
StringInputStream

 read ($count)
 reads a maximum of $length bytes

Static Public Member Functions

static create ($string)
 
Returns:
StringInputStream


Private Attributes

 $string = null
 $length = null
 $position = 0
 $mark = 0


Detailed Description

Definition at line 16 of file StringInputStream.class.php.


Constructor & Destructor Documentation

StringInputStream::__construct ( string  ) 

Definition at line 24 of file StringInputStream.class.php.

References $string.


Member Function Documentation

static StringInputStream::create ( string  )  [static]

Returns:
StringInputStream

Definition at line 35 of file StringInputStream.class.php.

References $string.

Referenced by OpenIdCredentials::__construct().

StringInputStream::isEof (  ) 

Reimplemented from InputStream.

Definition at line 40 of file StringInputStream.class.php.

Referenced by read().

StringInputStream::mark (  ) 

Returns:
StringInputStream

Reimplemented from InputStream.

Definition at line 48 of file StringInputStream.class.php.

Referenced by reset().

StringInputStream::markSupported (  ) 

Reimplemented from InputStream.

Definition at line 55 of file StringInputStream.class.php.

StringInputStream::reset (  ) 

Returns:
StringInputStream

Reimplemented from InputStream.

Definition at line 63 of file StringInputStream.class.php.

References mark().

Here is the call graph for this function:

StringInputStream::close (  ) 

Returns:
StringInputStream

Reimplemented from InputStream.

Definition at line 73 of file StringInputStream.class.php.

StringInputStream::read ( length  ) 

reads a maximum of $length bytes

returns null on eof or if length == 0. Otherwise MUST return at least one byte or throw IOException

NOTE: if length is too large to read all data at once and eof has not been reached, it MUST BLOCK until all data is read or eof is reached or throw IOException.

It is abnormal state. Maybe you should use some kind of non-blocking channels instead?

Reimplemented from InputStream.

Definition at line 80 of file StringInputStream.class.php.

References isEof().

Here is the call graph for this function:


Member Data Documentation

StringInputStream::$string = null [private]

Definition at line 18 of file StringInputStream.class.php.

Referenced by __construct(), and create().

StringInputStream::$length = null [private]

Definition at line 19 of file StringInputStream.class.php.

StringInputStream::$position = 0 [private]

Definition at line 21 of file StringInputStream.class.php.

StringInputStream::$mark = 0 [private]

Definition at line 22 of file StringInputStream.class.php.


The documentation for this class was generated from the following file:
Generated on Sun Dec 9 21:58:33 2007 for onPHP by  doxygen 1.5.4