3 * A general answer-status handler. So called "answer-status handler" are
4 * classes which handles a message field 'answer-status' which is, alongside
5 * many other node-relevant data, the main part of the answer message. These
6 * answer messages, by the way, are never sent unrequested. This, however,
7 * sounds logical because the answer is a reply from a node that has responded
10 * The answer-status field gives information back to the requesting node if the
11 * receiving node could handle the message properly (all verfication steps are
12 * passed, message type was understood, correct receiver, et cetera) and how
13 * it handles it. Some messages may be rejected, e.g. when the requesting node
14 * is blacklisted or its behavour has changed.
16 * @author Roland Haeder <webmaster@ship-simu.org>
18 * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2012 Hub Developer Team
19 * @license GNU GPL 3.0 or any newer version
20 * @link http://www.ship-simu.org
22 * This program is free software: you can redistribute it and/or modify
23 * it under the terms of the GNU General Public License as published by
24 * the Free Software Foundation, either version 3 of the License, or
25 * (at your option) any later version.
27 * This program is distributed in the hope that it will be useful,
28 * but WITHOUT ANY WARRANTY; without even the implied warranty of
29 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 * GNU General Public License for more details.
32 * You should have received a copy of the GNU General Public License
33 * along with this program. If not, see <http://www.gnu.org/licenses/>.
35 class BaseAnserStatusHandler extends BaseHandler {
37 * Last exception instance from database layer or NULL (default)
39 private $lastException = NULL;
42 * Protected constructor
44 * @param $className Name of the class
47 protected function __construct ($className) {
48 // Call parent constructor
49 parent::__construct($className);
53 * Getter for last exception
55 * @return $lastException Last thrown exception
57 protected final function getLastException () {
58 return $this->lastException;
62 * Adds all required elements from given array into data set instance
64 * @param $dataSetInstance An instance of a StoreableCriteria class
65 * @param $messageData An array with all message data
68 public function addArrayToDataSet (StoreableCriteria $dataSetInstance, array $messageData) {
69 die(__METHOD__.chr(10));