BufferDaysRule extends AbstractRule
in package

Tags
since
3.9

Table of Contents

$bufferDays  : int
$roomTypeIds  : array<string|int, int>
$seasonIds  : array<string|int, int>
__construct()  : mixed
getBufferDays()  : int
getRoomTypeIds()  : array<string|int, int>
getSeasonIds()  : array<string|int, int>
isFor()  : bool
isForAllRoomTypes()  : bool
isForAllSeasons()  : bool
isForDate()  : bool
isForRoomType()  : bool
toArray()  : array<string|int, mixed>
verify()  : bool

Properties

$bufferDays

protected int $bufferDays = 0
Tags
since
3.9

$roomTypeIds

protected array<string|int, int> $roomTypeIds = array()
Tags
since
3.9

$seasonIds

protected array<string|int, int> $seasonIds = array()
Tags
since
3.9

Methods

__construct()

public __construct(array<string|int, mixed> $atts) : mixed
Parameters
$atts : array<string|int, mixed>

@param array $atts['season_ids'] @param array $atts['room_type_ids'] @param int $atts['buffer_day']

Tags
since
3.9
since
3.9.9
  • don't use buffer days if rules for admin are disabled.
Return values
mixed

getBufferDays()

public getBufferDays() : int
Tags
since
3.9
Return values
int

getRoomTypeIds()

public getRoomTypeIds() : array<string|int, int>
Tags
since
3.9
Return values
array<string|int, int>

getSeasonIds()

public getSeasonIds() : array<string|int, int>
Tags
since
3.9
Return values
array<string|int, int>

isFor()

public isFor(DateTime $date, int $roomTypeId) : bool
Parameters
$date : DateTime
$roomTypeId : int
Tags
since
3.9
Return values
bool

isForAllRoomTypes()

public isForAllRoomTypes() : bool
Tags
since
3.9
Return values
bool

isForAllSeasons()

public isForAllSeasons() : bool
Tags
since
3.9
Return values
bool

isForDate()

public isForDate(DateTime $date) : bool
Parameters
$date : DateTime
Tags
since
3.9
Return values
bool

isForRoomType()

public isForRoomType(int $roomTypeId) : bool
Parameters
$roomTypeId : int
Tags
since
3.9
Return values
bool

toArray()

public toArray() : array<string|int, mixed>
Tags
since
3.9
Return values
array<string|int, mixed>

verify()

public verify(DateTime $checkInDate, DateTime $checkOutDate, int $roomTypeId) : bool
Parameters
$checkInDate : DateTime
$checkOutDate : DateTime
$roomTypeId : int

Optional.

Tags
since
3.9
Return values
bool

Search results