source: Dev/trunk/classes/Question.php @ 113

Last change on this file since 113 was 112, checked in by fpvanagthoven, 14 years ago

Code to get questions and put them in objects

File size: 853 bytes
Line 
1<?php
2
3/*
4 * To change this template, choose Tools | Templates
5 * and open the template in the editor.
6 */
7
8/**
9 * Description of Question
10 *
11 * @author fpvanagthoven
12 */
13class Question {   
14    public $code;
15    public $title;
16    public $type;
17    public $description;
18    public $answers; // format answers['#']
19    public $category;
20   
21    public function __construct($code, $title, $type = null, $description = null)
22    {
23        $this->code = $code;
24        $this->title = $title;
25        $this->type = $type;
26        $this->description = $description;
27        $this->answers = array();
28    }
29   
30    /* reminder that constructor doesn't contain category haha */
31    public function setCategory($category)
32    {
33        $this->category = $category;
34    }
35   
36    public static function getQuestion($questionInfo)
37    {
38       
39    }
40
41}
42
43?>
Note: See TracBrowser for help on using the repository browser.