CWIS Developer Documentation

- Home
- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

PrivilegeSetCompatibilityShim.php
Go to the documentation of this file.
1 <?PHP
2 #
3 # FILE: PrivilegeSet.php
4 #
5 # Part of the Collection Workflow Integration System (CWIS)
6 # Copyright 2014 Edward Almasy and Internet Scout Research Group
7 # http://scout.wisc.edu/cwis/
8 #
9
15 class PrivilegeSetCompatibilityShim {
16
17 function __construct(CWUser $User)
18 {
19 $this->User = $User;
20 }
21
22 function IsGreaterThan(PrivilegeSet $Set, $Resource = PrivilegeSet::NO_RESOURCE)
23 {
24 return $Set->MeetsRequirements($this->User, $Resource);
25 }
26
27 # ---- PRIVATE INTERFACE -------------------------------------------------
28
29 private $User;
30 }
PrivilegeSet\NO_RESOURCE
const NO_RESOURCE
Definition: PrivilegeSet.php:403
User
Definition: User.php:41
PrivilegeSet
Set of privileges used to access resource information or other parts of the system.
Definition: PrivilegeSet.php:16
PrivilegeSet\MeetsRequirements
MeetsRequirements(CWUser $User, $Resource=self::NO_RESOURCE)
Determine if a given user meets the requirements specified by this PrivilegeSet.
Definition: PrivilegeSet.php:92
PHP
PHP
Definition: RSSClient--Test.php:12
PrivilegeSetCompatibilityShim
Compatibility layer allowing interfaces built against the privilege system from CWIS 3...
Definition: PrivilegeSetCompatibilityShim.php:15
PrivilegeSetCompatibilityShim\IsGreaterThan
IsGreaterThan(PrivilegeSet $Set, $Resource=PrivilegeSet::NO_RESOURCE)
Definition: PrivilegeSetCompatibilityShim.php:22
PrivilegeSetCompatibilityShim\__construct
__construct(CWUser $User)
Definition: PrivilegeSetCompatibilityShim.php:17
CWUser
CWIS-specific user class.
Definition: CWUser.php:13