protected function _setup_active_communicator() { $available_communicators = L\Config::get(L\Config::OPTION_COMMUNICATORS); foreach($available_communicators as $communicator) { if($communicator::available()) { $this->_communicator = new $communicator; break; } } if(!$this->_communicator instanceof ICommunicator) throw new E\InvalidCommunicatorException("Communicator must implement ICommunicator class."); }
protected function _setup_reader() { $readers = L\Config::get(L\Config::OPTION_INPUT_READERS); foreach($readers as $reader) { if(!in_array('AIP\\lib\\clnt\\rdrs\\Reader', class_parents($reader))) throw new E\AIPInput_InvalidReaderException("'{$reader}' must extend the \\AIP\\lib\\clnt\\rdrs\\Reader class."); if($reader::supported()) { $this->_reader = new $reader; break; } } }
protected function run_before_loop_exec() { $exec = \AIP\lib\Config::get(\AIP\lib\Config::OPTION_BEFORE_LOOP_EXEC); ob_start(); foreach($exec as $line) $this->tick($line); $output = ob_get_clean(); if(\AIP\lib\Config::get(\AIP\lib\Config::OPTION_VERBOSITY) > 0) { Output::write(\AIP\lib\srvr\evlr\Result::message("Start of 'before_loop_exec'")); Output::raw_write($output); Output::write(\AIP\lib\srvr\evlr\Result::message("End of 'before_loop_exec'")); } }
public function render() { $render = array(); if(L\Config::get(L\Config::OPTION_VERBOSITY) > 0) $this->prepare_php($render); $internal = $this->prepare_internal(); if(!isset($internal)) { $this->prepare_return($render); $this->prepare_output($render); $this->prepare_message($render); } else { $render[] = $internal; } return $this->prepare_render($render); }
protected function __construct() { $this->constructs = L\Config::get(L\Config::OPTION_AIP_LANG_CONSTRUCTS); }
protected function __construct() { $this->_history = array(); $this->_max_size = \AIP\lib\Config::get(\AIP\lib\Config::OPTION_HISTORY_SIZE); $this->_last_index = 0; $this->_unconformed_history = false; }