PHP Class Scalr\Api\Service\User\V1beta0\Adapter\ScalingRule\DateAndTimeScalingRuleAdapter

Since: 5.11.7 (25.01.2016)
Author: Andrii Penchuk ([email protected])
Inheritance: extends Scalr\Api\Service\User\V1beta0\Adapter\ScalingRuleAdapter
Mostrar archivo Open project: scalr/scalr

Protected Properties

Property Type Description
$dateTimeSettingsMap array Schedule properties mapping
$listOfWeakDays array List of weak days value
$rules

Public Methods

Method Description
_schedule ( $from, $to, $action )
validateEntity ( $entity )
validateTimeInterval ( DateTime $time ) Validate schedule start and end time interval

Protected Methods

Method Description
scheduleToData ( FarmRoleScalingMetric $entity, stdClass $object ) Converts schedule settings entity to data object
scheduleToEntity ( stdClass $object, FarmRoleScalingMetric $entity ) Converts schedule data to entity

Method Details

_schedule() public method

public _schedule ( $from, $to, $action )

scheduleToData() protected method

Converts schedule settings entity to data object
protected scheduleToData ( FarmRoleScalingMetric $entity, stdClass $object )
$entity Scalr\Model\Entity\FarmRoleScalingMetric Object entity
$object stdClass The data to convert into entity

scheduleToEntity() protected method

Converts schedule data to entity
protected scheduleToEntity ( stdClass $object, FarmRoleScalingMetric $entity )
$object stdClass
$entity Scalr\Model\Entity\FarmRoleScalingMetric Object entity

validateEntity() public method

See also: BasicScalingRuleAdapter::validateEntity()
public validateEntity ( $entity )

validateTimeInterval() public method

Validate schedule start and end time interval
public validateTimeInterval ( DateTime $time )
$time DateTime

Property Details

$dateTimeSettingsMap protected_oe static_oe property

Schedule properties mapping
protected static array $dateTimeSettingsMap
return array

$listOfWeakDays protected_oe static_oe property

List of weak days value
protected static array $listOfWeakDays
return array

$rules protected_oe property

protected $rules