ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
class.arMessage.php
Go to the documentation of this file.
1 <?php
2 require_once('./Services/ActiveRecord/class.ActiveRecord.php');
3 require_once(dirname(__FILE__) . '/../../Connector/class.arConnectorSession.php');
4 
11 class arMessage extends ActiveRecord
12 {
13  const TYPE_NEW = 1;
14  const TYPE_READ = 2;
15  const PRIO_LOW = 1;
16  const PRIO_NORMAL = 5;
17  const PRIO_HIGH = 9;
18 
19 
23  public static function returnDbTableName()
24  {
25  return 'ar_message';
26  }
27 
28 
38  protected $id;
46  protected $title = '';
54  protected $body = '';
62  protected $sender_id = 0;
71  protected $receiver_id = 0;
80  protected $priority = self::PRIO_NORMAL;
89  protected $type = self::TYPE_NEW;
90 
91 
95  public function setBody($body)
96  {
97  $this->body = $body;
98  }
99 
100 
104  public function getBody()
105  {
106  return $this->body;
107  }
108 
109 
113  public function setPriority($priority)
114  {
115  $this->priority = $priority;
116  }
117 
118 
122  public function getPriority()
123  {
124  return $this->priority;
125  }
126 
127 
131  public function setReceiverId($receiver_id)
132  {
133  $this->receiver_id = $receiver_id;
134  }
135 
136 
140  public function getReceiverId()
141  {
142  return $this->receiver_id;
143  }
144 
145 
149  public function setSenderId($sender_id)
150  {
151  $this->sender_id = $sender_id;
152  }
153 
154 
158  public function getSenderId()
159  {
160  return $this->sender_id;
161  }
162 
163 
167  public function setTitle($title)
168  {
169  $this->title = $title;
170  }
171 
172 
176  public function getTitle()
177  {
178  return $this->title;
179  }
180 
181 
185  public function setType($type)
186  {
187  $this->type = $type;
188  }
189 
190 
194  public function getType()
195  {
196  return $this->type;
197  }
198 
199 
204  // public function __construct($primary_key = 0, $dev = false) {
205  // parent::__construct($primary_key, new arConnectorSession());
206  // }
207 }
static returnDbTableName()
Class ActiveRecord.
setSenderId($sender_id)
Class arMessage.
setTitle($title)
const PRIO_NORMAL
setPriority($priority)
setReceiverId($receiver_id)
setBody($body)