Example #1
0
 /**
  * setOutputContext
  *
  * Set output context type
  *
  * @param  string $type Type of output context
  * @return null
  */
 public static function setOutputContext($type)
 {
     if (!in_array($type, self::$_availableContexts)) {
         throw new SystemErrorException(array('title' => 'View error', 'description' => 'Unavailable output context: ' . $type));
     }
     if (!self::$_lockedContext) {
         self::$_outputContext = $type;
     }
 }