blob: e769fbada8f4fe4e1e6b84712f725cb525b38cb6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
<?php
/**
* SuccessResult
* Generic success result class, extend if you want to do something special.
*
* @author Curverider Ltd <info@elgg.com>
* @package Elgg
* @subpackage Core
*/
class SuccessResult extends GenericResult {
public static $RESULT_SUCCESS = 0; // Do not change this from 0
public function SuccessResult($result) {
$this->setResult($result);
$this->setStatusCode(SuccessResult::$RESULT_SUCCESS);
}
public static function getInstance($result) {
// Return a new error object.
return new SuccessResult($result);
}
}
|