Property | Type | Description | |
---|---|---|---|
$requestApiVersion |
Property | Type | Description | |
---|---|---|---|
$aclRoles | Scalr\Acl\Role\AccountRoleSuperposition | Acl roles for this user and environment | |
$clientIp | |||
$definitions | |||
$environment | |||
$paramErrors | |||
$params | |||
$paramsIsValid | |||
$requestFiles | |||
$requestHeaders | |||
$requestParams | |||
$requestServer | |||
$requestType | |||
$scope | |||
$user | Scalr_Account_User |
Method | Description | |
---|---|---|
__construct ( $type, $headers, $server, $params, $files ) | ||
addValidationErrors ( $field, $errors ) | ||
checkPermissions ( object $object, boolean | string $modify = null ) | Check whether the user has access permissions to the specified object | |
defineParams ( $defs ) | ||
getAclRoles ( ) : Scalr\Acl\Role\AccountRoleSuperposition | Gets acl roles superposition for the request | |
getAuditLoggerConfig ( ) | ||
getClientIp ( ) | Gets client ip address for the current request | |
getClientIpAddress ( ) : string | Gets client ip address | |
getCloudResourceFilteringDecision ( integer $resourceId, string $platform = SERVER_PLATFORMS::EC2, string $farmId = null ) : Scalr\Acl\Resource\CloudResourceFilteringDecision | Gets Cloud Resource filtering decision for the specified ACL resource | |
getEnvironment ( ) : Scalr_Environment | Gets an environment instance which is associated with the request | |
getFarmSqlQuery ( string $permissionId = null ) : string | Generate conditions for sql query to limit access by only allowable farms. | |
getFileName ( $name ) | ||
getHeaderVar ( $name ) | ||
getInstance ( ) : Scalr_UI_Request | ||
getParam ( $key, boolean $rawValue = false ) : mixed | ||
getParams ( ) | ||
getRemoteAddr ( ) : string | Gets User's IP | |
getRequestParam ( $key ) | ||
getRequestType ( ) | ||
getScope ( ) | ||
getUser ( ) : Scalr_Account_User | ||
getValidationErrors ( ) | ||
getValidationErrorsMessage ( ) | ||
hasParam ( $key ) | ||
hasPermissions ( object $object, boolean | string $modify = null ) : boolean | Check whether the user has access permissions to the specified object | |
initializeInstance ( $type, $headers, $server, $params, $files, $userId, $envId = null ) : Scalr_UI_Request | ||
isAllowed ( integer | string | array $resourceId, string $permissionId = null ) : boolean | Checks if access to ACL resource or unique permission is allowed | |
isFarmDesignerAllowed ( ) : boolean | Checks whether user has access to FarmDesigner | |
isInterfaceBeta ( ) | ||
isInterfaceBetaOrNotHostedScalr ( ) : boolean | Checks whether either it is beta version of interface or not hosted scalr install | |
isValid ( ) | ||
restrictAccess ( $resourceId, $permissionId = null ) | ||
restrictFarmDesignerAccess ( ) | Checks whether user has access to FarmDesigner | |
setParam ( $key, $value ) | ||
setParams ( $params ) | ||
stripValue ( $value ) : string | clear string from prohibited symbols | |
validate ( ) : Scalr_UI_Request |
public addValidationErrors ( $field, $errors ) | ||
$field | string | |
$errors | array|string |
public getAclRoles ( ) : Scalr\Acl\Role\AccountRoleSuperposition | ||
return | Scalr\Acl\Role\AccountRoleSuperposition |
public static getClientIpAddress ( ) : string | ||
return | string | Returns client ip address. |
public getCloudResourceFilteringDecision ( integer $resourceId, string $platform = SERVER_PLATFORMS::EC2, string $farmId = null ) : Scalr\Acl\Resource\CloudResourceFilteringDecision | ||
$resourceId | integer | ACL Resource ID which should have defined Mode which is the instance of CloudResourceScopeMode |
$platform | string | optional The Cloud Platform TODO It isn't supported yet |
$farmId | string | optional The Farm identifier |
return | Scalr\Acl\Resource\CloudResourceFilteringDecision | Returns decision object |
public getEnvironment ( ) : Scalr_Environment | ||
return | Scalr_Environment |
public getFarmSqlQuery ( string $permissionId = null ) : string | ||
$permissionId | string | optional |
return | string |
public static getInstance ( ) : Scalr_UI_Request | ||
return | Scalr_UI_Request |
public getRemoteAddr ( ) : string | ||
return | string | Returns User's IP |
public static initializeInstance ( $type, $headers, $server, $params, $files, $userId, $envId = null ) : Scalr_UI_Request | ||
$type | ||
$headers | ||
$server | ||
$params | ||
$files | ||
$userId | ||
$envId | int optional Could be null, when we check headers (for UI) | |
return | Scalr_UI_Request |
public isAllowed ( integer | string | array $resourceId, string $permissionId = null ) : boolean | ||
$resourceId | integer | string | array | The ID or Name of the ACL resource or array of resources |
$permissionId | string | optional The ID or Name of the unique permission which is related to specified resource. |
return | boolean | Returns TRUE if access is allowed |
public isFarmDesignerAllowed ( ) : boolean | ||
return | boolean |
public isInterfaceBetaOrNotHostedScalr ( ) : boolean | ||
return | boolean | Returns true if it is either a beta version of interface or it isn't hosted scalr install |
public restrictFarmDesignerAccess ( ) |
public stripValue ( $value ) : string | ||
$value | string | |
return | string |
protected AccountRoleSuperposition,Scalr\Acl\Role $aclRoles | ||
return | Scalr\Acl\Role\AccountRoleSuperposition |