Kohana v3.3.2
This commit is contained in:
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_300 extends HTTP_Exception_Redirect {
|
||||
*/
|
||||
protected $_code = 300;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_301 extends HTTP_Exception_Redirect {
|
||||
*/
|
||||
protected $_code = 301;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_302 extends HTTP_Exception_Redirect {
|
||||
*/
|
||||
protected $_code = 302;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_303 extends HTTP_Exception_Redirect {
|
||||
*/
|
||||
protected $_code = 303;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -6,5 +6,5 @@ class Kohana_HTTP_Exception_304 extends HTTP_Exception_Expected {
|
||||
* @var integer HTTP 304 Not Modified
|
||||
*/
|
||||
protected $_code = 304;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -9,7 +9,7 @@ class Kohana_HTTP_Exception_305 extends HTTP_Exception_Expected {
|
||||
|
||||
/**
|
||||
* Specifies the proxy to replay this request via
|
||||
*
|
||||
*
|
||||
* @param string $location URI of the proxy
|
||||
*/
|
||||
public function location($uri = NULL)
|
||||
@@ -24,7 +24,7 @@ class Kohana_HTTP_Exception_305 extends HTTP_Exception_Expected {
|
||||
|
||||
/**
|
||||
* Validate this exception contains everything needed to continue.
|
||||
*
|
||||
*
|
||||
* @throws Kohana_Exception
|
||||
* @return bool
|
||||
*/
|
||||
@@ -38,4 +38,5 @@ class Kohana_HTTP_Exception_305 extends HTTP_Exception_Expected {
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_307 extends HTTP_Exception_Redirect {
|
||||
*/
|
||||
protected $_code = 307;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_400 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 400;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -9,14 +9,14 @@ class Kohana_HTTP_Exception_401 extends HTTP_Exception_Expected {
|
||||
|
||||
/**
|
||||
* Specifies the WWW-Authenticate challenge.
|
||||
*
|
||||
*
|
||||
* @param string $challenge WWW-Authenticate challenge (eg `Basic realm="Control Panel"`)
|
||||
*/
|
||||
public function authenticate($challenge = NULL)
|
||||
{
|
||||
if ($challenge === NULL)
|
||||
return $this->headers('www-authenticate');
|
||||
|
||||
|
||||
$this->headers('www-authenticate', $challenge);
|
||||
|
||||
return $this;
|
||||
@@ -24,7 +24,7 @@ class Kohana_HTTP_Exception_401 extends HTTP_Exception_Expected {
|
||||
|
||||
/**
|
||||
* Validate this exception contains everything needed to continue.
|
||||
*
|
||||
*
|
||||
* @throws Kohana_Exception
|
||||
* @return bool
|
||||
*/
|
||||
@@ -35,4 +35,5 @@ class Kohana_HTTP_Exception_401 extends HTTP_Exception_Expected {
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_402 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 402;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_403 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 403;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_404 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 404;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -9,7 +9,7 @@ class Kohana_HTTP_Exception_405 extends HTTP_Exception_Expected {
|
||||
|
||||
/**
|
||||
* Specifies the list of allowed HTTP methods
|
||||
*
|
||||
*
|
||||
* @param array $methods List of allowed methods
|
||||
*/
|
||||
public function allowed($methods)
|
||||
@@ -26,7 +26,7 @@ class Kohana_HTTP_Exception_405 extends HTTP_Exception_Expected {
|
||||
|
||||
/**
|
||||
* Validate this exception contains everything needed to continue.
|
||||
*
|
||||
*
|
||||
* @throws Kohana_Exception
|
||||
* @return bool
|
||||
*/
|
||||
@@ -38,4 +38,4 @@ class Kohana_HTTP_Exception_405 extends HTTP_Exception_Expected {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_406 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 406;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_407 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 407;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_408 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 408;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_409 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 409;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_410 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 410;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_411 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 411;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_412 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 412;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_413 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 413;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_414 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 414;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_415 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 415;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_416 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 416;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_417 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 417;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_500 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 500;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_501 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 501;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_502 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 502;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_503 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 503;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_504 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 504;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -7,4 +7,4 @@ class Kohana_HTTP_Exception_505 extends HTTP_Exception {
|
||||
*/
|
||||
protected $_code = 505;
|
||||
|
||||
}
|
||||
}
|
||||
|
@@ -1,8 +1,8 @@
|
||||
<?php defined('SYSPATH') OR die('No direct script access.');
|
||||
/**
|
||||
* "Expected" HTTP exception class. Used for all [HTTP_Exception]'s where a standard
|
||||
* Kohana error page should never be shown.
|
||||
*
|
||||
* Kohana error page should never be shown.
|
||||
*
|
||||
* Eg [HTTP_Exception_301], [HTTP_Exception_302] etc
|
||||
*
|
||||
* @package Kohana
|
||||
@@ -39,7 +39,7 @@ abstract class Kohana_HTTP_Exception_Expected extends HTTP_Exception {
|
||||
|
||||
/**
|
||||
* Gets and sets headers to the [Response].
|
||||
*
|
||||
*
|
||||
* @see [Response::headers]
|
||||
* @param mixed $key
|
||||
* @param string $value
|
||||
@@ -57,7 +57,7 @@ abstract class Kohana_HTTP_Exception_Expected extends HTTP_Exception {
|
||||
|
||||
/**
|
||||
* Validate this exception contains everything needed to continue.
|
||||
*
|
||||
*
|
||||
* @throws Kohana_Exception
|
||||
* @return bool
|
||||
*/
|
||||
@@ -68,7 +68,7 @@ abstract class Kohana_HTTP_Exception_Expected extends HTTP_Exception {
|
||||
|
||||
/**
|
||||
* Generate a Response for the current Exception
|
||||
*
|
||||
*
|
||||
* @uses Kohana_Exception::response()
|
||||
* @return Response
|
||||
*/
|
||||
@@ -79,4 +79,4 @@ abstract class Kohana_HTTP_Exception_Expected extends HTTP_Exception {
|
||||
return $this->_response;
|
||||
}
|
||||
|
||||
} // End Kohana_HTTP_Exception
|
||||
}
|
||||
|
@@ -2,7 +2,7 @@
|
||||
/**
|
||||
* Redirect HTTP exception class. Used for all [HTTP_Exception]'s where the status
|
||||
* code indicates a redirect.
|
||||
*
|
||||
*
|
||||
* Eg [HTTP_Exception_301], [HTTP_Exception_302] and most of the other 30x's
|
||||
*
|
||||
* @package Kohana
|
||||
@@ -15,14 +15,14 @@ abstract class Kohana_HTTP_Exception_Redirect extends HTTP_Exception_Expected {
|
||||
|
||||
/**
|
||||
* Specifies the URI to redirect to.
|
||||
*
|
||||
*
|
||||
* @param string $location URI of the proxy
|
||||
*/
|
||||
public function location($uri = NULL)
|
||||
{
|
||||
if ($uri === NULL)
|
||||
return $this->headers('Location');
|
||||
|
||||
|
||||
if (strpos($uri, '://') === FALSE)
|
||||
{
|
||||
// Make the URI into a URL
|
||||
@@ -36,7 +36,7 @@ abstract class Kohana_HTTP_Exception_Redirect extends HTTP_Exception_Expected {
|
||||
|
||||
/**
|
||||
* Validate this exception contains everything needed to continue.
|
||||
*
|
||||
*
|
||||
* @throws Kohana_Exception
|
||||
* @return bool
|
||||
*/
|
||||
@@ -48,4 +48,4 @@ abstract class Kohana_HTTP_Exception_Redirect extends HTTP_Exception_Expected {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
} // End Kohana_HTTP_Exception_Redirect
|
||||
}
|
||||
|
Reference in New Issue
Block a user