ILIAS  release_7 Revision v7.30-3-g800a261c036
All Data Structures Namespaces Files Functions Variables Modules Pages
ReferenceId.php
Go to the documentation of this file.
1 <?php namespace ILIAS\Data;
2 
3 use ilObject2;
4 
13 {
14 
18  private $ref_id;
19 
20 
26  public function __construct(int $ref_id)
27  {
28  $this->ref_id = $ref_id;
29  }
30 
31 
37  public function toInt() : int
38  {
39  return (int) $this->ref_id;
40  }
41 
42 
46  public function toObjectId() : ObjectId
47  {
48  return new ObjectId((int) ilObject2::_lookupObjectId($this->ref_id));
49  }
50 }
toInt()
Get the password-string.
Definition: ReferenceId.php:37
static _lookupObjectId($a_ref_id)
__construct(int $ref_id)
ReferenceId constructor.
Definition: ReferenceId.php:26