ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilOrgUnitAuthority Class Reference

Class ilOrguAuthority. More...

+ Collaboration diagram for ilOrgUnitAuthority:

Public Member Functions

 __construct ($id=0)
 
 __toString ()
 
 getId ()
 
 getOver ()
 
 withOver (int $over)
 
 getScope ()
 
 withScope (int $scope)
 
 getPositionId ()
 
 withPositionId (int $position_id)
 

Static Public Member Functions

static getScopes ()
 

Data Fields

const FIELD_OVER = 'over'
 
const OVER_EVERYONE = -1
 
const POSITION_ID = "position_id"
 
const SCOPE_SAME_ORGU = 1
 
const SCOPE_SUBSEQUENT_ORGUS = 2
 
const SCOPES
 

Protected Attributes

int $id
 
int $over = self::OVER_EVERYONE
 
int $scope = self::SCOPE_SAME_ORGU
 
int $position_id = 0
 

Detailed Description

Class ilOrguAuthority.

Author
Fabian Schmid fs@st.nosp@m.uder.nosp@m.-raim.nosp@m.ann..nosp@m.ch

Definition at line 25 of file class.ilOrgUnitAuthority.php.

Constructor & Destructor Documentation

◆ __construct()

ilOrgUnitAuthority::__construct (   $id = 0)

Definition at line 42 of file class.ilOrgUnitAuthority.php.

43 {
44 $this->id = $id;
45 }

References $id.

Member Function Documentation

◆ __toString()

ilOrgUnitAuthority::__toString ( )

Definition at line 55 of file class.ilOrgUnitAuthority.php.

55 : string
56 {
57 return (string) $this->id;
58 }

References $id.

◆ getId()

ilOrgUnitAuthority::getId ( )

Definition at line 60 of file class.ilOrgUnitAuthority.php.

60 : int
61 {
62 return $this->id;
63 }

References $id.

Referenced by ilOrgUnitAuthorityDBRepository\store(), and ilOrgUnitAuthorityDBRepository\update().

+ Here is the caller graph for this function:

◆ getOver()

ilOrgUnitAuthority::getOver ( )

Definition at line 65 of file class.ilOrgUnitAuthority.php.

65 : int
66 {
67 return $this->over;
68 }

References $over.

Referenced by ilOrgUnitAuthorityDBRepository\insert(), and ilOrgUnitAuthorityDBRepository\update().

+ Here is the caller graph for this function:

◆ getPositionId()

ilOrgUnitAuthority::getPositionId ( )

Definition at line 92 of file class.ilOrgUnitAuthority.php.

92 : int
93 {
94 return $this->position_id;
95 }

References $position_id.

Referenced by ilOrgUnitAuthorityDBRepository\insert(), and ilOrgUnitAuthorityDBRepository\update().

+ Here is the caller graph for this function:

◆ getScope()

ilOrgUnitAuthority::getScope ( )

Definition at line 77 of file class.ilOrgUnitAuthority.php.

77 : int
78 {
79 return $this->scope;
80 }

References $scope.

Referenced by ilOrgUnitAuthorityDBRepository\insert(), and ilOrgUnitAuthorityDBRepository\update().

+ Here is the caller graph for this function:

◆ getScopes()

static ilOrgUnitAuthority::getScopes ( )
static
Returns
int[]

Definition at line 50 of file class.ilOrgUnitAuthority.php.

50 : array
51 {
52 return self::SCOPES;
53 }

References SCOPES.

Referenced by ilOrgUnitPositionFormGUI\initFormElements().

+ Here is the caller graph for this function:

◆ withOver()

ilOrgUnitAuthority::withOver ( int  $over)

Definition at line 70 of file class.ilOrgUnitAuthority.php.

70 : self
71 {
72 $clone = clone $this;
73 $clone->over = $over;
74 return $clone;
75 }

References $over.

◆ withPositionId()

ilOrgUnitAuthority::withPositionId ( int  $position_id)

Definition at line 97 of file class.ilOrgUnitAuthority.php.

97 : self
98 {
99 $clone = clone $this;
100 $clone->position_id = $position_id;
101 return $clone;
102 }

References $position_id.

◆ withScope()

ilOrgUnitAuthority::withScope ( int  $scope)

Definition at line 82 of file class.ilOrgUnitAuthority.php.

82 : self
83 {
84 if (!in_array($scope, self::SCOPES)) {
85 throw new ilException('Selected Scope in ' . self::class . ' not allowed');
86 }
87 $clone = clone $this;
88 $clone->scope = $scope;
89 return $clone;
90 }
Base class for ILIAS Exception handling.

References $scope.

Field Documentation

◆ $id

int ilOrgUnitAuthority::$id
protected

Definition at line 37 of file class.ilOrgUnitAuthority.php.

Referenced by __construct(), __toString(), and getId().

◆ $over

int ilOrgUnitAuthority::$over = self::OVER_EVERYONE
protected

Definition at line 38 of file class.ilOrgUnitAuthority.php.

Referenced by getOver(), and withOver().

◆ $position_id

int ilOrgUnitAuthority::$position_id = 0
protected

Definition at line 40 of file class.ilOrgUnitAuthority.php.

Referenced by getPositionId(), and withPositionId().

◆ $scope

int ilOrgUnitAuthority::$scope = self::SCOPE_SAME_ORGU
protected

Definition at line 39 of file class.ilOrgUnitAuthority.php.

Referenced by getScope(), and withScope().

◆ FIELD_OVER

const ilOrgUnitAuthority::FIELD_OVER = 'over'

Definition at line 27 of file class.ilOrgUnitAuthority.php.

Referenced by ilOrgUnitAuthorityDBRepository\get().

◆ OVER_EVERYONE

◆ POSITION_ID

◆ SCOPE_SAME_ORGU

◆ SCOPE_SUBSEQUENT_ORGUS

◆ SCOPES

const ilOrgUnitAuthority::SCOPES

The documentation for this class was generated from the following file: