Location: PHPKode > projects > SimpleQuizzz > Trunk/include/question.class.php
<?php
/*
	simpleQuizz made Quizzs simple
    Copyright (C) 2008 Mathieu Lory <hide@address.com>

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
*/

/**
 * @package    simpleQuizz
 * @subpackage question
 * @author     Mathieu Lory <hide@address.com>
 */

if (basename($_SERVER["SCRIPT_NAME"])==basename(__FILE__))die();

/**
 *
 * @package simpleQuizz
 * 
 * @final
 */
final class Question extends Quizz
{
	private static $name;
	private static $description;
	private static $question = array();
	
	public function __construct($question)
	{
		self::$question = $question;
		return self::$question;
	}
	
	public static function getQuestion()
	{
		return self::$question;
	}
	
	public static function getAnswers()
	{
		return self::$question["answers"];
	}
	
	public static function getGoodAnswers()
	{
		return self::$question["good_answers"];
	}
	
	public static function getName()
	{
		return self::$name;
	}
	
	public static function getDescription()
	{
		return self::$description;
	}
}
?>
Return current item: SimpleQuizzz