Overview

Namespaces

  • Contrib
    • Bundle
      • CoverallsBundle
        • Console
        • Entity
      • CoverallsV1Bundle
        • Api
        • Collector
        • Command
        • Config
        • Entity
          • Git
    • Component
      • File
      • Log
      • System
        • Git
  • Guzzle
    • Batch
      • Exception
    • Cache
    • Common
      • Exception
    • Http
      • Curl
      • Exception
      • Message
      • QueryAggregator
    • Inflection
    • Iterator
    • Log
    • Parser
      • Cookie
      • Message
      • UriTemplate
      • Url
    • Plugin
      • Async
      • Backoff
      • Cache
      • Cookie
        • CookieJar
        • Exception
      • CurlAuth
      • ErrorResponse
        • Exception
      • History
      • Log
      • Md5
      • Mock
      • Oauth
    • Service
      • Builder
      • Command
        • Factory
        • LocationVisitor
          • Request
          • Response
      • Description
      • Exception
      • Resource
    • Stream
  • PHP
  • Psr
    • Log
  • Symfony
    • Component
      • Config
        • Definition
          • Builder
          • Exception
        • Exception
        • Loader
        • Resource
        • Util
      • Console
        • Command
        • Formatter
        • Helper
        • Input
        • Output
        • Tester
      • EventDispatcher
        • Debug
      • Finder
        • Adapter
        • Comparator
        • Exception
        • Expression
        • Iterator
        • Shell
      • Stopwatch
      • Yaml
        • Exception

Classes

  • PhpStreamRequestFactory
  • Stream

Interfaces

  • StreamInterface
  • StreamRequestFactoryInterface
  • Overview
  • Namespace
  • Class
  • Tree
  • Todo

Interface StreamInterface

OO interface to PHP streams

Direct known implementers

Guzzle\Http\EntityBodyInterface, Guzzle\Stream\Stream

Indirect known implementers

Guzzle\Http\AbstractEntityBodyDecorator, Guzzle\Http\CachingEntityBody, Guzzle\Http\EntityBody, Guzzle\Http\IoEmittingEntityBody, Guzzle\Http\ReadLimitEntityBody
Namespace: Guzzle\Stream
Located at Guzzle/Stream/StreamInterface.php
Methods summary
public string
# __toString( )

Convert the stream to a string if the stream is readable and the stream is seekable.

Convert the stream to a string if the stream is readable and the stream is seekable.

Returns

string
public
# close( )

Close the underlying stream

Close the underlying stream

public array|mixed|null
# getMetaData( string $key = null )

Get stream metadata

Get stream metadata

Parameters

$key
string
$key Specific metadata to retrieve

Returns

array|mixed|null
public resource
# getStream( )

Get the stream resource

Get the stream resource

Returns

resource
public Guzzle\Stream\StreamInterface
# setStream( resource $stream, integer $size = null )

Set the stream that is wrapped by the object

Set the stream that is wrapped by the object

Parameters

$stream
resource
$stream Stream resource to wrap
$size
integer
$size Size of the stream in bytes. Only pass if the size cannot be obtained from the stream.

Returns

Guzzle\Stream\StreamInterface
public string
# getWrapper( )

Get the stream wrapper type

Get the stream wrapper type

Returns

string
public array
# getWrapperData( )

Wrapper specific data attached to this stream.

Wrapper specific data attached to this stream.

Returns

array
public string
# getStreamType( )

Get a label describing the underlying implementation of the stream

Get a label describing the underlying implementation of the stream

Returns

string
public string
# getUri( )

Get the URI/filename associated with this stream

Get the URI/filename associated with this stream

Returns

string
public integer|boolean
# getSize( )

Get the size of the stream if able

Get the size of the stream if able

Returns

integer|boolean
public boolean
# isReadable( )

Check if the stream is readable

Check if the stream is readable

Returns

boolean
public boolean
# isWritable( )

Check if the stream is writable

Check if the stream is writable

Returns

boolean
public boolean
# isConsumed( )

Check if the stream has been consumed

Check if the stream has been consumed

Returns

boolean
public boolean
# feof( )

Alias of isConsumed

Alias of isConsumed

Returns

boolean
public boolean
# isLocal( )

Check if the stream is a local stream vs a remote stream

Check if the stream is a local stream vs a remote stream

Returns

boolean
public boolean
# isSeekable( )

Check if the string is repeatable

Check if the string is repeatable

Returns

boolean
public Guzzle\Stream\StreamInterface
# setSize( integer $size )

Specify the size of the stream in bytes

Specify the size of the stream in bytes

Parameters

$size
integer
$size Size of the stream contents in bytes

Returns

Guzzle\Stream\StreamInterface
public boolean
# seek( integer $offset, integer $whence = SEEK_SET )

Seek to a position in the stream

Seek to a position in the stream

Parameters

$offset
integer
$offset Stream offset
$whence
integer
$whence Where the offset is applied

Returns

boolean
Returns TRUE on success or FALSE on failure

Link

http://www.php.net/manual/en/function.fseek.php
public string|boolean
# read( integer $length )

Read data from the stream

Read data from the stream

Parameters

$length
integer
$length Up to length number of bytes read.

Returns

string|boolean
Returns the data read from the stream or FALSE on failure or EOF
public integer|boolean
# write( string $string )

Write data to the stream

Write data to the stream

Parameters

$string
string
$string The string that is to be written.

Returns

integer|boolean
Returns the number of bytes written to the stream on success or FALSE on failure.
public integer|boolean
# ftell( )

Returns the current position of the file read/write pointer

Returns the current position of the file read/write pointer

Returns

integer|boolean
Returns the position of the file pointer or false on error
public boolean
# rewind( )

Rewind to the beginning of the stream

Rewind to the beginning of the stream

Returns

boolean
Returns true on success or false on failure
public string|boolean
# readLine( integer $maxLength = null )

Read a line from the stream up to the maximum allowed buffer length

Read a line from the stream up to the maximum allowed buffer length

Parameters

$maxLength
integer
$maxLength Maximum buffer length

Returns

string|boolean
public Guzzle\Stream\StreamInterface
# setCustomData( string $key, mixed $value )

Set custom data on the stream

Set custom data on the stream

Parameters

$key
string
$key Key to set
$value
mixed
$value Value to set

Returns

Guzzle\Stream\StreamInterface
public null|mixed
# getCustomData( string $key )

Get custom data from the stream

Get custom data from the stream

Parameters

$key
string
$key Key to retrieve

Returns

null|mixed
php-coveralls API documentation generated by ApiGen 2.8.0