• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP AuthorizationPolicy类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中AuthorizationPolicy的典型用法代码示例。如果您正苦于以下问题:PHP AuthorizationPolicy类的具体用法?PHP AuthorizationPolicy怎么用?PHP AuthorizationPolicy使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了AuthorizationPolicy类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: isValid

 /**
  * @see HandlerValidator::isValid()
  */
 function isValid()
 {
     // Delegate to the AuthorizationPolicy
     if (!$this->_policy->applies()) {
         return false;
     }
     if ($this->_policy->effect() == AUTHORIZATION_DENY) {
         return false;
     } else {
         return true;
     }
 }
开发者ID:master3395,项目名称:CBPPlatform,代码行数:15,代码来源:HandlerValidatorPolicy.inc.php


示例2: isValid

 /**
  * @see HandlerValidator::isValid()
  */
 function isValid()
 {
     // Delegate to the AuthorizationPolicy
     if (!$this->_policy->applies()) {
         return false;
     }
     // Pass the authorized context to the police.
     $this->_policy->setAuthorizedContext($this->handler->getAuthorizedContext());
     if ($this->_policy->effect() == AUTHORIZATION_DENY) {
         return false;
     } else {
         return true;
     }
 }
开发者ID:EreminDm,项目名称:water-cao,代码行数:17,代码来源:HandlerValidatorPolicy.inc.php


示例3: HttpsPolicy

 /**
  * Constructor
  *
  * @param $request PKPRequest
  */
 function HttpsPolicy(&$request)
 {
     parent::AuthorizationPolicy();
     $this->_request =& $request;
     // Add advice
     $callOnDeny = array($request, 'redirectSSL', array());
     $this->setAdvice(AUTHORIZATION_ADVICE_CALL_ON_DENY, $callOnDeny);
 }
开发者ID:EreminDm,项目名称:water-cao,代码行数:13,代码来源:HttpsPolicy.inc.php


示例4: SubmissionRequiredPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  * @param $args array request parameters
  * @param $submissionParameterName string the request parameter we expect
  *  the submission id in.
  * @param $message string
  */
 function SubmissionRequiredPolicy(&$request, &$args, $submissionParameterName = 'submissionId', $message = null)
 {
     parent::AuthorizationPolicy($message);
     $this->_request =& $request;
     assert(is_array($args));
     $this->_args =& $args;
     $this->_submissionParameterName = $submissionParameterName;
 }
开发者ID:master3395,项目名称:CBPPlatform,代码行数:16,代码来源:SubmissionRequiredPolicy.inc.php


示例5: DataObjectRequiredPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  * @param $args array request parameters
  * @param $parameterName string the request parameter we expect
  * @param $message string
  * @param $operations array Optional list of operations for which this check takes effect. If specified, operations outside this set will not be checked against this policy.
  */
 function DataObjectRequiredPolicy(&$request, &$args, $parameterName, $message = null, $operations = null)
 {
     parent::AuthorizationPolicy($message);
     $this->_request =& $request;
     assert(is_array($args));
     $this->_args =& $args;
     $this->_parameterName = $parameterName;
     $this->_operations = $operations;
 }
开发者ID:yuricampos,项目名称:ojs,代码行数:17,代码来源:DataObjectRequiredPolicy.inc.php


示例6: HandlerOperationPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  * @param $operations array|string either a single operation or a list of operations that
  *  this policy is targeting.
  * @param $message string a message to be displayed if the authorization fails
  */
 function HandlerOperationPolicy(&$request, $operations, $message = null)
 {
     parent::AuthorizationPolicy($message);
     $this->_request =& $request;
     // Make sure a single operation doesn't have to
     // be passed in as an array.
     assert(is_string($operations) || is_array($operations));
     if (!is_array($operations)) {
         $operations = array($operations);
     }
     $this->_operations = $operations;
 }
开发者ID:JovanyJeff,项目名称:hrp,代码行数:19,代码来源:HandlerOperationPolicy.inc.php


示例7: WorkflowSettingsAssignmentPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function WorkflowSettingsAssignmentPolicy(&$request)
 {
     parent::AuthorizationPolicy('user.authorization.workflowStageSettingMissing');
     $this->_request =& $request;
 }
开发者ID:ramonsodoma,项目名称:omp,代码行数:9,代码来源:WorkflowSettingsAssignmentPolicy.inc.php


示例8: UserRolesRequiredPolicy

 /**
  * Constructor
  *
  * @param $request PKPRequest
  */
 function UserRolesRequiredPolicy($request)
 {
     parent::AuthorizationPolicy();
     $this->_request = $request;
 }
开发者ID:mczirfusz,项目名称:pkp-lib,代码行数:10,代码来源:UserRolesRequiredPolicy.inc.php


示例9: ContextRequiredPolicy

 /**
  * Constructor
  *
  * @param $request PKPRequest
  */
 function ContextRequiredPolicy(&$request, $message = 'user.authorization.contextRequired')
 {
     parent::AuthorizationPolicy($message);
     $this->_request =& $request;
 }
开发者ID:farhanabbas1983,项目名称:ojs-1,代码行数:10,代码来源:ContextRequiredPolicy.inc.php


示例10: QueryAssignedToUserAccessPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function QueryAssignedToUserAccessPolicy($request)
 {
     parent::AuthorizationPolicy('user.authorization.submissionQuery');
     $this->_request = $request;
 }
开发者ID:jprk,项目名称:pkp-lib,代码行数:9,代码来源:QueryAssignedToUserAccessPolicy.inc.php


示例11: UserAccessibleWorkflowStagePolicy

 /**
  * Constructor
  * @param $stageId The one that will be checked against accessible
  * user workflow stages.
  */
 function UserAccessibleWorkflowStagePolicy($stageId)
 {
     parent::AuthorizationPolicy();
     $this->_stageId = $stageId;
 }
开发者ID:relaciones-internacionales-journal,项目名称:pkp-lib,代码行数:10,代码来源:UserAccessibleWorkflowStagePolicy.inc.php


示例12: ReviewAssignmentAccessPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function ReviewAssignmentAccessPolicy(&$request)
 {
     parent::AuthorizationPolicy('user.authorization.monographReviewer');
     $this->_request =& $request;
 }
开发者ID:jerico-dev,项目名称:omp,代码行数:9,代码来源:ReviewAssignmentAccessPolicy.inc.php


示例13: ReviewAssignmentAccessPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function ReviewAssignmentAccessPolicy($request)
 {
     parent::AuthorizationPolicy('user.authorization.submissionReviewer');
     $this->_request = $request;
 }
开发者ID:mczirfusz,项目名称:pkp-lib,代码行数:9,代码来源:ReviewAssignmentAccessPolicy.inc.php


示例14: ManagerRequiredPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function ManagerRequiredPolicy($request)
 {
     parent::AuthorizationPolicy('user.authorization.managerRequired');
     $this->_request = $request;
 }
开发者ID:jprk,项目名称:pkp-lib,代码行数:9,代码来源:ManagerRequiredPolicy.inc.php


示例15: PluginLevelRequiredPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function PluginLevelRequiredPolicy($request, $contextLevel)
 {
     parent::AuthorizationPolicy();
     $this->_contextLevel =& $contextLevel;
 }
开发者ID:laelnasan,项目名称:UTFPR-ojs,代码行数:9,代码来源:PluginLevelRequiredPolicy.inc.php


示例16: SectionSubmissionAssignmentPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function SectionSubmissionAssignmentPolicy(&$request)
 {
     parent::AuthorizationPolicy('user.authorization.sectionAssignment');
     $this->_request =& $request;
 }
开发者ID:yuricampos,项目名称:ojs,代码行数:9,代码来源:SectionSubmissionAssignmentPolicy.inc.php


示例17: SectionAssignmentPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function SectionAssignmentPolicy($request)
 {
     parent::AuthorizationPolicy('user.authorization.seriesAssignment');
     $this->_request = $request;
 }
开发者ID:jalperin,项目名称:ojs,代码行数:9,代码来源:SectionAssignmentPolicy.inc.php


示例18: CopyeditorSubmissionAssignmentPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function CopyeditorSubmissionAssignmentPolicy(&$request)
 {
     parent::AuthorizationPolicy('user.authorization.copyeditorAssignmentMissing');
     $this->_request =& $request;
 }
开发者ID:ingmarschuster,项目名称:MindResearchRepository,代码行数:9,代码来源:CopyeditorSubmissionAssignmentPolicy.inc.php


示例19: WorkflowStageRequiredPolicy

 /**
  * Constructor
  * @param $stageId integer One of the WORKFLOW_STAGE_ID_* constants.
  */
 function WorkflowStageRequiredPolicy($stageId)
 {
     parent::AuthorizationPolicy('user.authorization.workflowStageRequired');
     $this->_stageId = $stageId;
 }
开发者ID:mczirfusz,项目名称:pkp-lib,代码行数:9,代码来源:WorkflowStageRequiredPolicy.inc.php


示例20: UserAccessibleWorkflowStageRequiredPolicy

 /**
  * Constructor
  * @param $request PKPRequest
  */
 function UserAccessibleWorkflowStageRequiredPolicy($request)
 {
     parent::AuthorizationPolicy('user.authorization.accessibleWorkflowStage');
     $this->_request = $request;
 }
开发者ID:jprk,项目名称:pkp-lib,代码行数:9,代码来源:UserAccessibleWorkflowStageRequiredPolicy.inc.php



注:本文中的AuthorizationPolicy类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP Authorizer类代码示例发布时间:2022-05-23
下一篇:
PHP Authorization类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap