PHP 클래스 Scalr_Environment

Following phpdocumentor comments have been derived from Scalr\DependencyInjection class:
상속: extends Scalr_Model
파일 보기 프로젝트 열기: scalr/scalr 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$clientId
$defaultPriority
$dtAdded
$id
$name
$status

보호된 프로퍼티들

프로퍼티 타입 설명
$dbPropertyMap
$dbTableName

공개 메소드들

메소드 설명
__call ( $name, $arguments )
__get ( string $id ) : mixed
addTeam ( $teamId )
applyGlobalVarsToValue ( $value )
aws ( string | DBServer | DBFarmRole | DBEBSVolume $awsRegion = null, string $awsAccessKeyId = null, string $awsSecretAccessKey = null, string $certificate = null, string $privateKey = null ) : Aws Gets an Amazon Web Service (Aws) factory instance
azure ( ) : Azure Gets an Azure client instance
clearTeams ( )
cloudCredentialsList ( array $clouds = null, array $credentialsFilter = [], array $propertiesFilter = [], boolean $cacheResult = true ) : CloudCredentials[] Gets cloud credentials for listed clouds
cloudstack ( string $platform = 'cloudstack', string $apiUrl = null, string $apiKey = null, string $secretKey = null ) : CloudStack Gets an CloudStack client instance
create ( $name, $clientId )
delete ( $id = null )
enablePlatform ( $platform, $enabled = true )
get ( string $serviceid ) : mixed Gets an service or parameter by its id.
getAccountId ( ) : integer Gets identifier of the Account
getAwsTags ( ) : array Gets AWS tags that should be applied to the resource
getEnabledPlatforms ( $cacheResult = false, $clouds = null )
getFarmsCount ( )
getFullConfiguration ( ) : array Gets client_environment_properties
getLocations ( )
getPlatformConfigValue ( string $key, boolean $encrypted = true, string $group = '' ) : mixed Gets client_environment_properties value.
getRunningServersCount ( )
getTeams ( )
init ( string $className = null ) : Scalr_Environment Init
isPlatformEnabled ( $platform )
keychain ( string $cloud ) : CloudCredentials Gets specified cloud credentials for this environment
loadDefault ( $clientId )
openstack ( OpenStackConfig | string $platform, string $region = null ) : OpenStack Gets an OpenStack client instance
removeTeam ( $teamId )
save ( $forceInsert = false )
setPlatformConfig ( array $props, boolean $encrypt = true, string $group = '' ) Saves platform config value to database.

보호된 메소드들

메소드 설명
decryptValue ( $value )
encryptValue ( $value )

비공개 메소드들

메소드 설명
getEncryptedVariables ( ) : array TODO: remove all variables encapsulated in cloud credentials Gets the list of the variables which need to be encrypted when we store them to database.
getLinkedVariables ( string $linkid = null ) : array TODO: migrate to the new cloud credentials entities Gets array of the linked variables

메소드 상세

__call() 공개 메소드

또한 보기: Scalr_Model::__call()
public __call ( $name, $arguments )

__get() 공개 메소드

public __get ( string $id ) : mixed
$id string serviceid
리턴 mixed

addTeam() 공개 메소드

public addTeam ( $teamId )

applyGlobalVarsToValue() 공개 메소드

public applyGlobalVarsToValue ( $value )

aws() 공개 메소드

This method ensures that aws instance is always from the current environment scope.
public aws ( string | DBServer | DBFarmRole | DBEBSVolume $awsRegion = null, string $awsAccessKeyId = null, string $awsSecretAccessKey = null, string $certificate = null, string $privateKey = null ) : Aws
$awsRegion string | DBServer | DBFarmRole | DBEBSVolume optional The region or object which has both Scalr_Environment instance and cloud location itself
$awsAccessKeyId string optional The AccessKeyId
$awsSecretAccessKey string optional The SecretAccessKey
$certificate string optional Contains x.509 certificate
$privateKey string optional The private key for the certificate
리턴 Scalr\Service\Aws Returns Aws instance

azure() 공개 메소드

This method ensures that azure instance is always from the current environment scope
public azure ( ) : Azure
리턴 Scalr\Service\Azure Returns azure instance from DI container

clearTeams() 공개 메소드

public clearTeams ( )

cloudCredentialsList() 공개 메소드

Gets cloud credentials for listed clouds
public cloudCredentialsList ( array $clouds = null, array $credentialsFilter = [], array $propertiesFilter = [], boolean $cacheResult = true ) : CloudCredentials[]
$clouds array optional Clouds list
$credentialsFilter array optional Criteria to filter by CloudCredentials properties
$propertiesFilter array optional Criteria to filter by CloudCredentialsProperties
$cacheResult boolean optional Cache result
리턴 Scalr\Model\Entity\CloudCredentials[]

cloudstack() 공개 메소드

This method ensures that cloudstack instance is always from the current environment scope
public cloudstack ( string $platform = 'cloudstack', string $apiUrl = null, string $apiKey = null, string $secretKey = null ) : CloudStack
$platform string Platform name
$apiUrl string The endpoint name url
$apiKey string Api key
$secretKey string Secret key
리턴 Scalr\Service\CloudStack\CloudStack Returns cloudstack instance from DI container

create() 공개 메소드

public create ( $name, $clientId )

decryptValue() 보호된 메소드

protected decryptValue ( $value )

delete() 공개 메소드

또한 보기: Scalr_Model::delete()
public delete ( $id = null )

enablePlatform() 공개 메소드

public enablePlatform ( $platform, $enabled = true )

encryptValue() 보호된 메소드

protected encryptValue ( $value )

get() 공개 메소드

Gets an service or parameter by its id.
public get ( string $serviceid ) : mixed
$serviceid string
리턴 mixed

getAccountId() 공개 메소드

Gets identifier of the Account
public getAccountId ( ) : integer
리턴 integer Returns identifier of the Account

getAwsTags() 공개 메소드

Gets AWS tags that should be applied to the resource
public getAwsTags ( ) : array
리턴 array Returns list of the AWS tags

getEnabledPlatforms() 공개 메소드

public getEnabledPlatforms ( $cacheResult = false, $clouds = null )

getFarmsCount() 공개 메소드

public getFarmsCount ( )

getFullConfiguration() 공개 메소드

Gets client_environment_properties
public getFullConfiguration ( ) : array
리턴 array Returns all config entries

getLocations() 공개 메소드

public getLocations ( )

getPlatformConfigValue() 공개 메소드

Gets client_environment_properties value.
public getPlatformConfigValue ( string $key, boolean $encrypted = true, string $group = '' ) : mixed
$key string Property name.
$encrypted boolean optional This value is ignored and never taken into account
$group string optional Group name.
리턴 mixed Returns config value on success or NULL if value does not exist.

getRunningServersCount() 공개 메소드

getTeams() 공개 메소드

public getTeams ( )

init() 공개 정적인 메소드

Init
public static init ( string $className = null ) : Scalr_Environment
$className string
리턴 Scalr_Environment

isPlatformEnabled() 공개 메소드

public isPlatformEnabled ( $platform )

keychain() 공개 메소드

Gets specified cloud credentials for this environment
public keychain ( string $cloud ) : CloudCredentials
$cloud string The cloud name
리턴 Scalr\Model\Entity\CloudCredentials

loadDefault() 공개 메소드

public loadDefault ( $clientId )

openstack() 공개 메소드

This method ensures that openstack instance is always from the current environment scope
public openstack ( OpenStackConfig | string $platform, string $region = null ) : OpenStack
$platform Scalr\Service\OpenStack\OpenStackConfig | string The platform name or Openstack config
$region string optional The region
리턴 Scalr\Service\OpenStack\OpenStack Returns openstack instance from DI container

removeTeam() 공개 메소드

public removeTeam ( $teamId )

save() 공개 메소드

또한 보기: Scalr_Model::save()
public save ( $forceInsert = false )

setPlatformConfig() 공개 메소드

This operation will update client_environment_properties table or delete if value is null.
public setPlatformConfig ( array $props, boolean $encrypt = true, string $group = '' )
$props array List of properties with its values keypairs to save.
$encrypt boolean optional This value is ignored and never taken into account.
$group string Group

프로퍼티 상세

$clientId 공개적으로 프로퍼티

public $clientId

$dbPropertyMap 보호되어 있는 프로퍼티

protected $dbPropertyMap

$dbTableName 보호되어 있는 프로퍼티

protected $dbTableName

$defaultPriority 공개적으로 프로퍼티

public $defaultPriority

$dtAdded 공개적으로 프로퍼티

public $dtAdded

$id 공개적으로 프로퍼티

public $id

$name 공개적으로 프로퍼티

public $name

$status 공개적으로 프로퍼티

public $status