public function getStreamContext()
    {
        if ($this->_options['streamContext'] !== null) {
            if (is_resource($this->_options['streamContext'])) {
                return $this->_options['streamContext'];
            }
            if (is_array($this->_options['streamContext'])) {
                return stream_context_create($this->_options['streamContext']);
            }
        }
        return null;
    }
public function getStreamContext()
    {
        if ($this->_options['streamContext'] !== null) {
            if (is_resource($this->_options['streamContext'])) {
                return $this->_options['streamContext'];
            }
            if (is_array($this->_options['streamContext'])) {
                return stream_context_create($this->_options['streamContext']);
            }
        }
        return null;
    }
public function getStreamContext ( ) { if ( $ this -> _options [ 'streamContext' ] !== null ) { if ( is_resource ( $ this -> _options [ 'streamContext' ] ) ) { return $ this -> _options [ 'streamContext' ] ; } if ( is_array ( $ this -> _options [ 'streamContext' ] ) ) { return stream_context_create ( $ this -> _options [ 'streamContext' ] ) ; } } return null ; }
If a stream context is provided, use it creating the socket.

It's supported to provide either an array with options, or an already created
resource.

@return mixed null or resource
@see    self::connect()
If a stream context is provided use it creating the socket .