Documentation

ISite extends IApplication

Tags
author

Ramone Burrell ramone@ramoneburrell.com

since

Version 0.1.0

Table of Contents

Constants

KIND_API  = 'api'
KIND_CLI  = 'cli'
KIND_SITE  = 'site'

Methods

addRoute()  : mixed
execute()  : mixed
getContext()  : IContext
getDispatcher()  : Dispatcher
getInstance()  : IApplication
getKind()  : string
Gets the kind of this application. Return value will be one of 'cli', 'api', 'site'
getName()  : string
Gets the name of the application.
getRequest()  : IRequest
getResponse()  : IResponse
getRouter()  : IRouter
redirect()  : void
If the current application being run is of the kind 'api' or 'site' then an HTTP 'Location' header for a particular URI will be sent and execution will end. If however the application being run is of the kind 'cli' then execution will be redirected to another controller and action within the cli application
respond()  : mixed
Sends a response from the application.

Constants

Methods

getKind()

Gets the kind of this application. Return value will be one of 'cli', 'api', 'site'

public getKind() : string
Return values
string

redirect()

If the current application being run is of the kind 'api' or 'site' then an HTTP 'Location' header for a particular URI will be sent and execution will end. If however the application being run is of the kind 'cli' then execution will be redirected to another controller and action within the cli application

public redirect(IUri|string $uri) : void
Parameters
$uri : IUri|string

respond()

Sends a response from the application.

public respond([string|Exception|null $message = null ]) : mixed
Parameters
$message : string|Exception|null = null

The message to exit the application with


        
On this page

Search results