Autodoc
  • Namespace
  • Class
  • Tree

Namespaces

  • BlueTihi
    • Context
  • Brickrouge
    • Element
      • Nodes
    • Renderer
    • Widget
  • ICanBoogie
    • ActiveRecord
    • AutoConfig
    • CLDR
    • Composer
    • Core
    • Event
    • Exception
    • HTTP
      • Dispatcher
      • Request
    • I18n
      • Translator
    • Mailer
    • Modules
      • Taxonomy
        • Support
      • Thumbnailer
        • Versions
    • Object
    • Operation
      • Dispatcher
    • Prototype
    • Routes
    • Routing
      • Dispatcher
    • Session
  • Icybee
    • ActiveRecord
      • Model
    • ConfigOperation
    • Document
    • EditBlock
    • Element
      • ActionbarContextual
      • ActionbarSearch
      • ActionbarToolbar
    • FormBlock
    • Installer
    • ManageBlock
    • Modules
      • Articles
      • Cache
        • Collection
        • ManageBlock
      • Comments
        • ManageBlock
      • Contents
        • ManageBlock
      • Dashboard
      • Editor
        • Collection
      • Files
        • File
        • ManageBlock
      • Forms
        • Form
        • ManageBlock
      • I18n
      • Images
        • ManageBlock
      • Members
      • Modules
        • ManageBlock
      • Nodes
        • ManageBlock
        • Module
      • Pages
        • BreadcrumbElement
        • LanguagesElement
        • ManageBlock
        • NavigationBranchElement
        • NavigationElement
        • Page
        • PageController
      • Registry
      • Search
      • Seo
      • Sites
        • ManageBlock
      • Taxonomy
        • Terms
          • ManageBlock
        • Vocabulary
          • ManageBlock
      • Users
        • ManageBlock
        • NonceLogin
        • Roles
      • Views
        • ActiveRecordProvider
        • Collection
        • View
    • Operation
      • ActiveRecord
      • Constructor
      • Module
      • Widget
    • Rendering
  • None
  • Patron
  • PHP

Classes

  • BeforeControlEvent
  • BeforeProcessEvent
  • BeforeValidateEvent
  • ControlEvent
  • ControlEventBase
  • Dispatcher
  • FailureEvent
  • GetFormEvent
  • ProcessEvent
  • RescueEvent
  • Response
  • ValidateEvent
  • ValidateEventBase

Exceptions

  • Failure
  • FormHasExpired

Functions

  • array_to_xml

Class Response

ICanBoogie\Object implements ICanBoogie\ToArrayRecursive uses ICanBoogie\ToArrayRecursiveTrait, ICanBoogie\PrototypeTrait
Extended by ICanBoogie\HTTP\Response
Extended by ICanBoogie\Operation\Response implements ArrayAccess
Namespace: ICanBoogie\Operation
Located at vendor/icanboogie/operation/lib/response.php

Methods summary

protected
# set_message( string $message )

Sets the response message.

Sets the response message.

Parameters

$message
string
$message

Throws

InvalidArgumentException
if the message is an array or an object that do not implement __toString().
protected string
# get_message( )

Returns the response message.

Returns the response message.

Returns

string
public
# __construct( mixed $body = null, integer $status = 200, array $headers = array() )

Initializes the ICanBoogie\Operation\Response::$errors property.

Initializes the ICanBoogie\Operation\Response::$errors property.

Parameters

$body
mixed
$body The body of the response.
$status
integer
$status The status code of the response.
$headers
Headers|array
$headers The initial header fields of the response.

See

ICanBoogie\HTTP\Response::__construct()

Overrides

ICanBoogie\HTTP\Response::__construct
public
# __invoke( )

Issues the HTTP response.

Issues the HTTP response.

The header is modified according to the ICanBoogie\HTTP\Response::$version, status and ICanBoogie\HTTP\Response::$status_message properties.

The usual behaviour of the response is to echo its body and then terminate the script. But if its body is null the following happens :

  • If the $location property is defined the script is terminated.
  • If the $is_ok property is falsy the method returns.

Note: If the body is a string, or an object implementing the __toString() method, the Content-Length header is automatically defined to the lenght of the body string.

Note: If the body is an instance of Closure it MUST echo the response's body.

Overrides

ICanBoogie\HTTP\Response::__invoke
public
# offsetExists( mixed $offset )

Checks if a meta exists.

Checks if a meta exists.

See

ArrayAccess::offsetExists()

Implementation of

ArrayAccess::offsetExists()
public
# offsetGet( mixed $offset )

Returns a meta or null if it is not defined.

Returns a meta or null if it is not defined.

See

ArrayAccess::offsetGet()

Implementation of

ArrayAccess::offsetGet()
public
# offsetSet( mixed $offset, mixed $value )

Sets a meta.

Sets a meta.

See

ArrayAccess::offsetSet()

Implementation of

ArrayAccess::offsetSet()
public
# offsetUnset( mixed $offset )

Unsets a meta.

Unsets a meta.

See

ArrayAccess::offsetUnset()

Implementation of

ArrayAccess::offsetUnset()

Methods inherited from ICanBoogie\HTTP\Response

__clone(), __set(), __toString(), echo_body(), get_age(), get_body(), get_cache_control(), get_content_length(), get_content_type(), get_date(), get_etag(), get_expires(), get_is_cacheable(), get_is_client_error(), get_is_empty(), get_is_forbidden(), get_is_fresh(), get_is_informational(), get_is_not_found(), get_is_ok(), get_is_private(), get_is_redirect(), get_is_server_error(), get_is_successful(), get_is_valid(), get_is_validateable(), get_last_modified(), get_location(), get_status(), get_status_message(), get_ttl(), set_age(), set_body(), set_cache_control(), set_content_length(), set_content_type(), set_date(), set_etag(), set_expires(), set_is_private(), set_last_modified(), set_location(), set_status(), set_ttl()

Methods inherited from ICanBoogie\Object

from(), resolve_facade_properties(), resolve_private_properties(), to_array(), to_json()

Methods inherited from ICanBoogie\ToArrayRecursive

to_array_recursive()

Methods used from ICanBoogie\ToArrayRecursiveTrait

to_array_recursive()

Methods used from ICanBoogie\PrototypeTrait

__call(), __get(), __sleep(), __wakeup(), get_prototype(), has_method(), has_property(), last_chance_get(), last_chance_set()

Magic methods summary

Properties summary

public mixed $rc
#

Result of the response.

Result of the response.

public ICanBoogie\Errors $errors
#

Errors occuring during the response.

Errors occuring during the response.

protected array $metas
#

Properties inherited from ICanBoogie\HTTP\Response

$headers, $status_message, $status_messages, $version

Magic properties

public string $message
#

The response message.

The response message.

public read-only ICanBoogie\Errors $errors
#

Magic properties inherited from ICanBoogie\HTTP\Response

$age, $body, $cache_control, $content_length, $content_type, $date, $etag, $expires, $is_cacheable, $is_client_error, $is_empty, $is_forbidden, $is_fresh, $is_informational, $is_not_found, $is_ok, $is_private, $is_redirect, $is_server_error, $is_successful, $is_valid, $is_validateable, $last_modified, $location, $status, $status_message, $ttl

Magic properties inherited from ICanBoogie\Object

$prototype

Autodoc API documentation generated by ApiGen 2.8.0