Fixed some API doc in controller.

This commit is contained in:
Juan Basso 2011-07-29 00:06:43 -04:00
parent 070980b170
commit fbbfbaf870
8 changed files with 28 additions and 6 deletions

View file

@ -19,7 +19,8 @@ class CakeErrorController extends AppController {
/**
* __construct
*
* @access public
* @param CakeRequest $request
* @param CakeResponse $response
* @return void
*/
public function __construct($request = null, $response = null) {

View file

@ -58,6 +58,8 @@ class AclComponent extends Component {
/**
* Constructor. Will return an instance of the correct ACL class as defined in `Configure::read('Acl.classname')`
*
* @param ComponentCollection $collection
* @param array $settings
* @throws CakeException when Acl.classname could not be loaded.
*/
public function __construct(ComponentCollection $collection, $settings = array()) {

View file

@ -61,7 +61,7 @@ abstract class BaseAuthorize {
/**
* Constructor
*
* @param Controller $controller The controller for this request.
* @param ComponentCollection $collection The controller for this request.
* @param string $settings An array of settings. This class does not use any settings.
*/
public function __construct(ComponentCollection $collection, $settings = array()) {
@ -102,6 +102,7 @@ abstract class BaseAuthorize {
* that need to get information about the plugin, controller, and action being invoked.
*
* @param CakeRequest $request The request a path is needed for.
* @param string $path
* @return string the action path for the given request.
*/
public function action($request, $path = '/:plugin/:controller/:action') {

View file

@ -180,6 +180,8 @@ class CookieComponent extends Component {
/**
* Start CookieComponent for use in the controller
*
* @param Controller $controller
* @return void
*/
public function startup($controller) {
$this->_expire($this->time);
@ -205,6 +207,7 @@ class CookieComponent extends Component {
* @param mixed $value Value
* @param boolean $encrypt Set to true to encrypt value, false otherwise
* @param string $expires Can be either Unix timestamp, or date string
* @return void
*/
public function write($key, $value = null, $encrypt = true, $expires = null) {
if (is_null($encrypt)) {
@ -327,7 +330,7 @@ class CookieComponent extends Component {
* Will allow overriding default encryption method.
*
* @param string $type Encryption method
* @access public
* @return void
* @todo NOT IMPLEMENTED
*/
public function type($type = 'cipher') {
@ -369,6 +372,7 @@ class CookieComponent extends Component {
*
* @param string $name Name for cookie
* @param string $value Value for cookie
* @return void
*/
protected function _write($name, $value) {
$this->_setcookie(
@ -399,6 +403,7 @@ class CookieComponent extends Component {
* Object wrapper for setcookie() so it can be mocked in unit tests.
*
* @param string $name Name of the cookie
* @param string $value Value of the cookie
* @param integer $expire Time the cookie expires in
* @param string $path Path the cookie applies to
* @param string $domain Domain the cookie is for.

View file

@ -291,6 +291,7 @@ class EmailComponent extends Component {
* Initialize component
*
* @param object $controller Instantiating controller
* @return void
*/
public function initialize($controller) {
if (Configure::read('App.encoding') !== null) {
@ -384,6 +385,7 @@ class EmailComponent extends Component {
/**
* Reset all EmailComponent internal variables to be able to send out a new email.
*
* @return void
* @link http://book.cakephp.org/view/1285/Sending-Multiple-Emails-in-a-loop
*/
public function reset() {

View file

@ -191,9 +191,11 @@ class RequestHandlerComponent extends Component {
/**
* Handles (fakes) redirects for Ajax requests using requestAction()
*
* @param object $controller A reference to the controller
* @param mixed $url A string or array containing the redirect location
* @param mixed HTTP Status for redirect
* @param Controller $controller A reference to the controller
* @param string|array $url A string or array containing the redirect location
* @param mixed $status HTTP Status for redirect
* @param boolean $exit
* @return void
*/
public function beforeRedirect($controller, $url, $status = null, $exit = true) {
if (!$this->request->is('ajax')) {
@ -373,6 +375,7 @@ class RequestHandlerComponent extends Component {
/**
* Gets remote client IP
*
* @param boolean $safe
* @return string Client IP address
* @deprecated use $this->request->clientIp() from your, controller instead.
*/

View file

@ -326,6 +326,7 @@ class Controller extends Object {
* Provides backwards compatibility to avoid problems with empty and isset to alias properties.
* Lazy loads models using the loadModel() method if declared in $uses
*
* @param string $name
* @return void
*/
public function __isset($name) {
@ -366,6 +367,7 @@ class Controller extends Object {
* Provides backwards compatibility access to the request object properties.
* Also provides the params alias.
*
* @param string $name
* @return void
*/
public function __get($name) {
@ -393,6 +395,8 @@ class Controller extends Object {
/**
* Provides backwards compatibility access for setting values to the request object.
*
* @param string $name
* @param mixed $value
* @return void
*/
public function __set($name, $value) {
@ -1017,6 +1021,7 @@ class Controller extends Object {
* Called before the controller action. You can use this method to configure and customize components
* or perform logic that needs to happen before each controller action.
*
* @return void
* @link http://book.cakephp.org/view/984/Callbacks
*/
public function beforeFilter() {
@ -1026,6 +1031,7 @@ class Controller extends Object {
* Called after the controller action is run, but before the view is rendered. You can use this method
* to perform logic or set view variables that are required on every request.
*
* @return void
* @link http://book.cakephp.org/view/984/Callbacks
*/
public function beforeRender() {
@ -1051,6 +1057,7 @@ class Controller extends Object {
/**
* Called after the controller action is run and rendered.
*
* @return void
* @link http://book.cakephp.org/view/984/Callbacks
*/
public function afterFilter() {

View file

@ -59,6 +59,7 @@ class PagesController extends AppController {
* Displays a view
*
* @param mixed What page to display
* @return void
*/
public function display() {
$path = func_get_args();