Joywork/import/reservation/state/BaseState.php

33 lines
691 B
PHP
Raw Normal View History

2026-05-22 20:21:54 +02:00
<?php
abstract class BaseState implements IReservationState
{
protected $context;
protected static $currentState;
public function getStateId()
{
return static::$currentState;
}
public function __construct(Reservation $context)
{
$this->context = $context;
}
public function startWork() {
throw new \Exception("Unsupportable operation");
}
public function cancel() {
throw new \Exception("Unsupportable operation");
}
public function sell() {
throw new \Exception("Unsupportable operation");
}
public function remove() {
throw new \Exception("Unsupportable operation");
}
}