Exemplo n.º 1
0
 function __construct($identifier,$user_id, $expiration_date, $request_hash) {
     parent::__construct($identifier);
     
     $this->user_id = $user_id;
      
     $this->request_hash = $request_hash;
     
     if ($expiration instanceof DateTime) {
         $this->expiration_date = $expiration_date;
     } else {
         $this->expiration_date = new DateTime($expiration_date, new DateTimeZone('UTC'));
     }
 }
Exemplo n.º 2
0
 function __construct($identifier, $username,  $email, $name, $surname, $password, $creation_date, $penalties, $account_type = null ) {
     parent::__construct($identifier);
     $this->username = $username;
     $this->password = $password;
     $this->email = $email;
     $this->name = $name;
     $this->surname = $surname;
     $this->password = $password;
     $this->account_type = $account_type;
     if ($creation_date instanceof DateTime) {
         $this->creation_date = $creation_date;
     } else {
         $this->creation_date = new DateTime($creation_date, new DateTimeZone('UTC'));
     }
     $this->penalties = $penalties;
 }
Exemplo n.º 3
0
 function __construct($identifier, $comment, $site, $user, $usability, $reliability, $contents, $language_code, $date_added) {
     parent::__construct($identifier);
     $this->comment = $comment;
     $this->site = $site;
     $this->user = $user;
     $this->usability = $usability;
     $this->reliability = $reliability;
     $this->contents = $contents;
     $this->language_code = $language_code;
     
     if ($date_added instanceof DateTime) {
         $this->date_added = $date_added;
     } else {
         $this->date_added = new DateTime($date_added, new DateTimeZone('UTC'));
     }
     
 }
Exemplo n.º 4
0
 /**
  * 
  * @param string $identifier
  * @param string $domain
  * @param DateTime|integer $date_added
  * @param string $user
  * @param string $tld
  * @param string $category
  */
 function __construct($identifier, $domain, $date_added, $user, $tld, $category, $reliability, $contents, $usability, $cache_date, $no_votes)
 {
     parent::__construct($identifier);
     $this->domain = $domain;
     if ($date_added instanceof DateTime) {
         $this->date_added = $date_added;
     } else {
         $this->date_added = new DateTime($date_added, new DateTimeZone('UTC'));
     }
     $this->user = $user;
     $this->tld = $tld;
     $this->category = $category;
     $this->contents = (double) $contents;
     $this->reliability = (double) $reliability;
     $this->usability = (double) $usability;
     $this->number_of_votes = (int) $no_votes;
     if ($cache_date instanceof DateTime) {
         $this->cached_date = $cache_date;
     } else {
         $this->cached_date = isset($cache_date) ? new DateTime($cache_date, new DateTimeZone('UTC')) : NULL;
     }
 }
Exemplo n.º 5
0
 public function __construct($identifier, $secret)
 {
     parent::__construct($identifier);
     $this->appSecret = $secret;
 }