Overview

Packages

  • None
  • SimplePie

Classes

  • SimplePie
  • SimplePie_Author
  • SimplePie_Autoloader
  • SimplePie_Cache
  • SimplePie_Cache_DB
  • SimplePie_Cache_File
  • SimplePie_Cache_Memcache
  • SimplePie_Cache_MySQL
  • SimplePie_Caption
  • SimplePie_Category
  • SimplePie_Content_Type_Sniffer
  • SimplePie_Copyright
  • SimplePie_Core
  • SimplePie_Credit
  • SimplePie_Decode_HTML_Entities
  • SimplePie_Enclosure
  • SimplePie_File
  • SimplePie_gzdecode
  • SimplePie_HTTP_Parser
  • SimplePie_IRI
  • SimplePie_Item
  • SimplePie_Locator
  • SimplePie_Misc
  • SimplePie_Net_IPv6
  • SimplePie_Parse_Date
  • SimplePie_Parser
  • SimplePie_Rating
  • SimplePie_Registry
  • SimplePie_Restriction
  • SimplePie_Sanitize
  • SimplePie_Source
  • SimplePie_XML_Declaration_Parser

Interfaces

  • SimplePie_Cache_Base
  • Overview
  • Package
  • Class
  • Tree
  • Deprecated
  • Todo

Class SimplePie_HTTP_Parser

HTTP Response Parser

Package: SimplePie
Located at SimplePie/HTTP/Parser.php
Methods summary
public
# __construct( string $data )

Create an instance of the class with the input data

Create an instance of the class with the input data

Parameters

$data
string
Input data
public boolean
# parse( )

Parse the input data

Parse the input data

Returns

boolean
true on success, false on failure
protected boolean
# has_data( )

Check whether there is data beyond the pointer

Check whether there is data beyond the pointer

Returns

boolean
true if there is further data, false if not
protected boolean
# is_linear_whitespace( )

See if the next character is LWS

See if the next character is LWS

Returns

boolean
true if the next character is LWS, false if not
protected
# http_version( )

Parse the HTTP version

Parse the HTTP version

protected
# status( )

Parse the status code

Parse the status code

protected
# reason( )

Parse the reason phrase

Parse the reason phrase

protected
# new_line( )

Deal with a new line, shifting data around as needed

Deal with a new line, shifting data around as needed

protected
# name( )

Parse a header name

Parse a header name

protected
# linear_whitespace( )

Parse LWS, replacing consecutive LWS characters with a single space

Parse LWS, replacing consecutive LWS characters with a single space

protected
# value( )

See what state to move to while within non-quoted header values

See what state to move to while within non-quoted header values

protected
# value_char( )

Parse a header value while outside quotes

Parse a header value while outside quotes

protected
# quote( )

See what state to move to while within quoted header values

See what state to move to while within quoted header values

protected
# quote_char( )

Parse a header value while within quotes

Parse a header value while within quotes

protected
# quote_escaped( )

Parse an escaped character within quotes

Parse an escaped character within quotes

protected
# body( )

Parse the body

Parse the body

protected
# chunked( )

Parsed a "Transfer-Encoding: chunked" body

Parsed a "Transfer-Encoding: chunked" body

Properties summary
public float $http_version 0.0
#

HTTP Version

HTTP Version

public integer $status_code 0
#

Status code

Status code

public string $reason ''
#

Reason phrase

Reason phrase

public array $headers array()
#

Key/value pairs of the headers

Key/value pairs of the headers

public string $body ''
#

Body of the response

Body of the response

protected string $state 'http_version'
#

Current state of the state machine

Current state of the state machine

protected string $data ''
#

Input data

Input data

protected integer $data_length 0
#

Input data length (to avoid calling strlen() everytime this is needed)

Input data length (to avoid calling strlen() everytime this is needed)

protected integer $position 0
#

Current position of the pointer

Current position of the pointer

protected string $name ''
#

Name of the hedaer currently being parsed

Name of the hedaer currently being parsed

protected string $value ''
#

Value of the hedaer currently being parsed

Value of the hedaer currently being parsed

SimplePie Documentation API documentation generated by ApiGen 2.4.0