]> git.mxchange.org Git - friendica.git/blob - object/BaseObject.php
added spaces (coding convention)
[friendica.git] / object / BaseObject.php
1 <?php
2 if (class_exists('BaseObject')) {
3         return;
4 }
5
6 require_once('boot.php');
7
8 /**
9  * Basic object
10  *
11  * Contains what is usefull to any object
12  */
13 class BaseObject {
14         private static $app = null;
15
16         /**
17          * Get the app
18          * 
19          * Same as get_app from boot.php
20          */
21         public function get_app() {
22                 if (self::$app) {
23                         return self::$app;
24                 }
25
26                 self::$app = get_app();
27
28                 return self::$app;
29         }
30
31         /**
32          * Set the app
33          */
34         public static function set_app($app) {
35                 self::$app = $app;
36         }
37 }
38 ?>