symfony API

sfResponse Class

You are currently browsing
the website for symfony 1

Visit the Symfony2 website


« Back to API menu

1.4 API OpenSearch

Packages

You are currently browsing the symfony API for the 1.4 version. Switch to:

sfResponse provides methods for manipulating client response information such

Inheritence

sfWebResponse  <  sfResponse

Method Summary

  • string getContent()
    Gets the current response content
  • array getOptions()
    Returns the options.
  • bool initialize($dispatcher, $options)
    Initializes this sfResponse.
  • send()
    Sends the content.
  • sendContent()
    Outputs the response content
  • array serialize()
    Serializes the current instance.
  • setContent($content)
    Sets the response content
  • setEventDispatcher($dispatcher)
    Sets the event dispatcher.
  • unserialize($serialized)
    Unserializes a sfResponse instance.
  • mixed __call($method, $arguments)
    Calls methods defined via sfEventDispatcher.
  • __construct()
    Class constructor.

Method Details

  • (string) getContent () Browse code

    Gets the current response content

    returns Content

  • (array) getOptions () Browse code

    Returns the options.

    returns The options.

  • (bool) initialize ($dispatcher, $options) Browse code

    $dispatcher An sfEventDispatcher instance
    $options An array of options

    Initializes this sfResponse.


    Available options:

    * logging: Whether to enable logging or not (false by default)

    returns true, if initialization completes successfully, otherwise false

    throws sfInitializationException If an error occurs while initializing this sfResponse

  • send () Browse code

    Sends the content.

  • sendContent () Browse code

    Outputs the response content

  • (array) serialize () Browse code

    Serializes the current instance.

    returns Objects instance

  • setContent ($content) Browse code

    Sets the response content

  • setEventDispatcher ($dispatcher) Browse code

    $dispatcher An sfEventDispatcher instance

    Sets the event dispatcher.

  • unserialize ($serialized) Browse code

    $serialized A serialized sfResponse instance

    Unserializes a sfResponse instance.


    You need to inject a dispatcher after unserializing a sfResponse instance.

  • (mixed) __call ($method, $arguments) Browse code

    $method The method name
    $arguments The method arguments

    Calls methods defined via sfEventDispatcher.

    returns The returned value of the called method

    throws sfException If the calls fails

  • __construct () Browse code

    Class constructor.