<?php

/**
 * 
 * @author Peter Csubak (chuby)
 * @copyright Peter Csubak (chuby)
 * 
 * //Annotations:
 * @Table
 */
class Transporter extends Entity implements SecurityGroup {
	
	/**
	 * @var string
	 * @Id(hashBy="<<name>><<phone>>")
	 * @Attribute(type="md5")
	 */
	protected $ID;
	
	/**
	 * @var string
	 * @Attribute(type="string", length=25)
	 */
	protected $name;
	
	/**
	 * @var string
	 * @Attribute(type="string", length=16)
	 * @Constraints(regex="^(00-|\+){0,1}[0-9]{2}-[0-9]{1,2}-[0-9]{7}")
	 */
	protected $phone;
	
	/**
	 * @var string
	 * @Attribute(type="string", length=10)
	 */
	protected $userName;
	
	/**
	 * @var string
	 * @Attribute(type="md5")
	 */
	protected $passCode;
	
	/** @XmlSchema */
	public $desktop;
	
	
	public function getGroupName(){
		return "transporter";
	}
	
	public function __construct(){
		$this->desktop = "<transporter>".
							"<name>name</name>".
							"<phone>phone</phone>".
							"<userName>userName</userName>".
							"<passCode>passCode</passCode>".
						"</transporter>";
	}
	
}
?>