ILIAS
release_5-4 Revision v5.4.26-12-gabc799a52e6
|
PHP SAPI. More...
Static Public Member Functions | |
static | getRequest () |
This static method will create a new Request object, based on the current PHP request. More... | |
static | sendResponse (ResponseInterface $response) |
Sends the HTTP response back to a HTTP client. More... | |
static | createFromServerArray (array $serverArray) |
This static method will create a new Request object, based on a PHP $_SERVER array. More... | |
PHP SAPI.
This object is responsible for:
It could be said that this class provides a mapping between the Request and Response objects, and php's:
You can choose to either call all these methods statically, but you can also instantiate this as an object to allow for polymorhpism.
|
static |
This static method will create a new Request object, based on a PHP $_SERVER array.
array | $serverArray |
Definition at line 107 of file Sapi.php.
References $header, $key, GuzzleHttp\Psr7\$protocol, $r, and $url.
Referenced by Sabre\DAV\Locks\MSWordTest\getLockRequest(), Sabre\DAV\Locks\MSWordTest\getLockRequest2(), Sabre\DAV\Locks\MSWordTest\getPutRequest(), Sabre\DAV\Property\SupportedReportSetTest\sendPROPFIND(), Sabre\CalDAV\Schedule\FreeBusyRequestTest\setUp(), Sabre\CalDAV\FreeBusyReportTest\setUp(), Sabre\DAV\GetIfConditionsTest\test2Etags(), Sabre\DAV\GetIfConditionsTest\test2LockTokens(), Sabre\DAV\GetIfConditionsTest\test2UriLockTokens(), Sabre\DAV\GetIfConditionsTest\test2UriMultiLockTokens(), Sabre\DAVACL\PluginAdminTest\testAdminAccess(), Sabre\DAV\ServerEventsTest\testAfterResponse(), Sabre\DAVACL\PrincipalPropertySearchTest\testAND(), Sabre\DAV\ServerSimpleTest\testBaseUri(), Sabre\DAV\ServerEventsTest\testBeforeBindCancel(), Sabre\DAV\HTTPPreferParsingTest\testBrief(), Sabre\DAV\Auth\Backend\BasicCallBackTest\testCallBack(), Sabre\DAV\Auth\Backend\AbstractDigestTest\testCheck(), Sabre\DAV\Auth\Backend\AbstractDigestTest\testCheckBadGetUserInfoResponse(), Sabre\DAV\Auth\Backend\AbstractDigestTest\testCheckBadGetUserInfoResponse2(), Sabre\DAV\Auth\Backend\AbstractDigestTest\testCheckBadPassword(), Sabre\DAV\Auth\Backend\AbstractBearerTest\testCheckInvalidToken(), Sabre\DAV\Auth\Backend\AbstractBasicTest\testCheckSuccess(), Sabre\DAV\Auth\Backend\AbstractBearerTest\testCheckSuccess(), Sabre\DAV\Auth\Backend\AbstractBasicTest\testCheckUnknownUser(), Sabre\DAV\Auth\Backend\AbstractDigestTest\testCheckUnknownUser(), Sabre\DAV\Browser\MapGetToPropFindTest\testCollectionGet(), Sabre\DAV\GetIfConditionsTest\testComplexIf(), Sabre\HTTP\SapiTest\testConstructFromServerArray(), Sabre\HTTP\SapiTest\testConstructPHPAuth(), Sabre\HTTP\SapiTest\testConstructPHPAuthDigest(), Sabre\HTTP\SapiTest\testConstructRedirectAuth(), Sabre\DAV\Issue33Test\testCopyMoveInfo(), Sabre\DAVACL\PrincipalSearchPropertySetTest\testCorrect(), Sabre\DAVACL\PrincipalPropertySearchTest\testCorrect(), Sabre\CalDAV\ValidateICalTest\testCreateFile(), Sabre\CardDAV\ValidateVCardTest\testCreateFile(), Sabre\CalDAV\ValidateICalTest\testCreateFile2Components(), Sabre\CalDAV\ValidateICalTest\testCreateFile2UIDS(), Sabre\CalDAV\ValidateICalTest\testCreateFileInvalidComponent(), Sabre\CalDAV\ValidateICalTest\testCreateFileNoUID(), Sabre\CardDAV\ValidateVCardTest\testCreateFileVCalendar(), Sabre\CalDAV\ValidateICalTest\testCreateFileVCard(), Sabre\CalDAV\ValidateICalTest\testCreateFileWrongComponent(), Sabre\DAV\Locks\PluginTest\testDeleteWithETagOnCollection(), Sabre\DAVACL\PrincipalSearchPropertySetTest\testDepth1(), Sabre\DAVACL\PrincipalPropertySearchTest\testDepth1(), Sabre\DAVACL\PrincipalSearchPropertySetTest\testDepthIncorrectXML(), Sabre\DAV\GetIfConditionsTest\testEtag(), Sabre\DAV\Issue33Test\testEverything(), Sabre\DAV\ServerEventsTest\testException(), Sabre\CalDAV\ExpandEventsDoubleEventsTest\testExpand(), Sabre\DAVACL\ExpandPropertiesTest\testExpand(), Sabre\DAVACL\ExpandPropertiesTest\testExpandDeep(), Sabre\DAVACL\ExpandPropertiesTest\testExpandHrefList(), Sabre\CardDAV\VCFExportTest\testExport(), Sabre\CalDAV\FreeBusyReportTest\testFreeBusyReportWrongNode(), Sabre\HTTP\RequestTest\testGetAbsoluteUrl(), Sabre\DAV\Locks\PluginTest\testGetTimeoutHeader(), Sabre\DAV\Locks\PluginTest\testGetTimeoutHeaderInfinite(), Sabre\DAV\Locks\PluginTest\testGetTimeoutHeaderInvalid(), Sabre\DAV\Locks\PluginTest\testGetTimeoutHeaderTwoItems(), Sabre\DAV\ServerSimpleTest\testGuessBaseUri(), Sabre\DAV\ServerSimpleTest\testGuessBaseUri2(), Sabre\DAV\ServerSimpleTest\testGuessBaseUriBadConfig(), Sabre\DAV\ServerSimpleTest\testGuessBaseUriNoPathInfo(), Sabre\DAV\ServerSimpleTest\testGuessBaseUriNoPathInfo2(), Sabre\DAV\ServerSimpleTest\testGuessBaseUriPercentEncoding(), Sabre\DAV\ServerSimpleTest\testGuessBaseUriQueryString(), Sabre\DAV\Sync\PluginTest\testIfConditions(), Sabre\DAV\Sync\PluginTest\testIfConditionsNoSyncToken(), Sabre\DAV\Sync\PluginTest\testIfConditionsNot(), Sabre\DAV\ServerPreconditionsTest\testIfModifiedSinceInvalidDate(), Sabre\DAV\ServerPreconditionsTest\testIfModifiedSinceInvalidDate2(), Sabre\DAV\ServerPreconditionsTest\testIfModifiedSinceModified(), Sabre\DAV\ServerPreconditionsTest\testIfModifiedSinceUnModified(), Sabre\DAV\ServerPreconditionsTest\testIfUnmodifiedSinceInvalidDate(), Sabre\DAV\ServerPreconditionsTest\testIfUnmodifiedSinceModified(), Sabre\DAV\ServerPreconditionsTest\testIfUnmodifiedSinceUnModified(), Sabre\CalDAV\Schedule\OutboxPostTest\testInvalidIcalBody(), Sabre\CalDAV\SharingPluginTest\testInviteBadXML(), Sabre\CalDAV\SharingPluginTest\testInviteReply(), Sabre\CalDAV\SharingPluginTest\testInviteWrongUrl(), Sabre\CalDAV\Issue205Test\testIssue205(), Sabre\CalDAV\Issue211Test\testIssue211(), Sabre\CalDAV\Issue220Test\testIssue220(), Sabre\CalDAV\Issue228Test\testIssue228(), Sabre\DAV\Locks\PluginTest\testLockCopyLockDestination(), Sabre\DAV\Locks\PluginTest\testLockCopyLockSource(), Sabre\DAV\Locks\PluginTest\testLockDeleteParent(), Sabre\DAV\Locks\PluginTest\testLockDeleteSucceed(), Sabre\DAV\Locks\PluginTest\testLockMoveLockDestination(), Sabre\DAV\Locks\PluginTest\testLockMoveLockParent(), Sabre\DAV\Locks\PluginTest\testLockMoveLockSourceLocked(), Sabre\DAV\Locks\PluginTest\testLockMoveLockSourceSucceed(), Sabre\DAV\Locks\PluginTest\testLockPutBadToken(), Sabre\DAV\Locks\PluginTest\testLockPutGoodToken(), Sabre\DAV\Locks\PluginTest\testLockRetainOwner(), Sabre\DAV\GetIfConditionsTest\testLockTokenUrl(), Sabre\CalDAV\PluginTest\testMkCalendarExistingCalendar(), Sabre\DAV\ServerMKCOLTest\testMkcol(), Sabre\DAV\ServerMKCOLTest\testMKCOLAlreadyExists(), Sabre\DAV\ServerMKCOLTest\testMKCOLBrokenXML(), Sabre\DAV\ServerMKCOLTest\testMKCOLIncorrectResourceType(), Sabre\DAV\ServerMKCOLTest\testMKCOLNoParent(), Sabre\DAV\ServerMKCOLTest\testMKCOLNoResourceType(), Sabre\DAV\ServerMKCOLTest\testMKCOLParentIsNoCollection(), Sabre\DAV\ServerMKCOLTest\testMKCOLSuccess(), Sabre\DAV\ServerMKCOLTest\testMKCOLUnknownBody(), Sabre\DAV\ServerMKCOLTest\testMKCOLUnknownXML(), Sabre\DAV\ServerMKCOLTest\testMKCOLWhiteSpaceResourceType(), Sabre\DAV\Mount\PluginTest\testMountResponse(), Sabre\CardDAV\MultiGetTest\testMultiGet(), Sabre\CardDAV\MultiGetTest\testMultiGetVCard4(), Sabre\DAVACL\PluginAdminTest\testNoAdminAccess(), Sabre\CalDAV\Schedule\OutboxPostTest\testNoMETHOD(), Sabre\DAV\ServerSimpleTest\testNonExistantMethod(), Sabre\DAV\GetIfConditionsTest\testNotLockToken(), Sabre\CalDAV\Schedule\OutboxPostTest\testNoVEVENT(), Sabre\DAV\ServerPluginTest\testOptions(), Sabre\DAVACL\PrincipalPropertySearchTest\testOR(), Sabre\DAV\HTTPPreferParsingTest\testParseMultiple(), Sabre\DAV\HTTPPreferParsingTest\testParseSimple(), Sabre\DAV\HTTPPreferParsingTest\testParseValue(), Sabre\DAV\HTTPPreferParsingTest\testParseWeirdValue(), Sabre\DAV\Mount\PluginTest\testPassThrough(), Sabre\DAV\PartialUpdate\PluginTest\testPatchNoRange(), Sabre\DAV\Browser\PluginTest\testPostMkCol(), Sabre\CalDAV\Schedule\OutboxPostTest\testPostPassThruNoOutBox(), Sabre\CalDAV\Schedule\OutboxPostTest\testPostPassThruNotFound(), Sabre\CalDAV\Schedule\OutboxPostTest\testPostPassThruNotTextCalendar(), Sabre\DAV\HTTPPreferParsingTest\testpropfindMinimal(), Sabre\DAV\Locks\PluginTest\testPutWithCorrectETag(), Sabre\DAV\Locks\PluginTest\testPutWithIncorrectETag(), Sabre\CardDAV\AddressBookQueryTest\testQueryLimit(), Sabre\DAV\Auth\Backend\ApacheTest\testRedirectRemoteUser(), Sabre\DAV\Auth\Backend\ApacheTest\testRemoteUser(), Sabre\DAV\ServerSimpleTest\testReportIntercepted(), Sabre\DAV\ServerSimpleTest\testReportNotFound(), Sabre\DAVACL\ExpandPropertiesTest\testSimple(), Sabre\CardDAV\SogoStripContentTypeTest\testStrip(), Sabre\DAV\Sync\PluginTest\testSubsequentSyncSyncCollection(), Sabre\DAV\Sync\PluginTest\testSubsequentSyncSyncCollectionDepthFallBack(), Sabre\DAV\Sync\PluginTest\testSubsequentSyncSyncCollectionLimit(), Sabre\DAV\Sync\PluginTest\testSyncInvalidToken(), Sabre\DAV\Sync\PluginTest\testSyncInvalidTokenNoPrefix(), Sabre\DAV\Sync\PluginTest\testSyncNoProp(), Sabre\DAV\Sync\PluginTest\testSyncNoSyncCollection(), Sabre\DAV\Sync\PluginTest\testSyncNoSyncInfo(), Sabre\DAV\Sync\PluginTest\testSyncNoSyncToken(), Sabre\DAV\ServerSimpleTest\testTriggerException(), Sabre\CalDAV\SharingPluginTest\testUnknownMethodNoNode(), Sabre\CalDAV\SharingPluginTest\testUnknownMethodNoPOST(), Sabre\CalDAV\SharingPluginTest\testUnknownMethodNoXML(), Sabre\DAVACL\PrincipalPropertySearchTest\testUnknownSearchField(), Sabre\CalDAV\Schedule\OutboxPostTest\testUnsupportedMethod(), Sabre\CalDAV\ValidateICalTest\testUpdateFile(), Sabre\CalDAV\ValidateICalTest\testUpdateFileInvalidComponent(), and Sabre\DAVACL\PrincipalPropertySearchTest\testWrongUri().
|
static |
This static method will create a new Request object, based on the current PHP request.
Definition at line 39 of file Sapi.php.
References $_POST, $_SERVER, and $r.
Referenced by Sabre\HTTP\RequestTest\testCreateFromPHPRequest().
|
static |
Sends the HTTP response back to a HTTP client.
This calls php's header() function and streams the body to php://output.
ResponseInterface | $response |
Definition at line 56 of file Sapi.php.
References $contentLength, $key, Sabre\VObject\$output, Sabre\HTTP\MessageInterface\getBody(), Sabre\HTTP\MessageInterface\getHeader(), Sabre\HTTP\MessageInterface\getHeaders(), Sabre\HTTP\MessageInterface\getHttpVersion(), Sabre\HTTP\ResponseInterface\getStatus(), and Sabre\HTTP\ResponseInterface\getStatusText().
Referenced by Sabre\HTTP\SapiTest\testSend(), Sabre\HTTP\SapiTest\testSendLimitedByContentLengthStream(), and Sabre\HTTP\SapiTest\testSendLimitedByContentLengthString().