European Week of Regions and Cities

Utils

Utils class contains helpers functions.

Table of Contents

Properties

$database  : Connection
The database connection.
$entityTypeManager  : EntityTypeManagerInterface
The entity type manager.

Methods

__construct()  : mixed
Utils helper Constructor.
getAmountIndex()  : mixed
Return amount index based on value.
getSlotsTimes()  : mixed
Return timeslot form specific format and slotIndex.
getTimeSlotIndex()  : mixed
Return split index form specific format and timeslot.
timeslotIsInConflict()  : mixed
Return if there is a conflict between two timeslots.

Properties

$database

The database connection.

protected Connection $database

$entityTypeManager

The entity type manager.

protected EntityTypeManagerInterface $entityTypeManager

Methods

__construct()

Utils helper Constructor.

public __construct(Connection $database, EntityTypeManagerInterface $entity_type_manager) : mixed
Parameters
$database : Connection
$entity_type_manager : EntityTypeManagerInterface

getAmountIndex()

Return amount index based on value.

public getAmountIndex(mixed $amount) : mixed
Parameters
$amount : mixed

getSlotsTimes()

Return timeslot form specific format and slotIndex.

public getSlotsTimes() : mixed

getTimeSlotIndex()

Return split index form specific format and timeslot.

public getTimeSlotIndex(mixed $from, mixed $slots) : mixed
Parameters
$from : mixed
$slots : mixed

timeslotIsInConflict()

Return if there is a conflict between two timeslots.

public timeslotIsInConflict(mixed $slot, mixed $from, mixed $to) : mixed
Parameters
$slot : mixed
$from : mixed
$to : mixed

        
On this page

Search results