Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- class Car implements IVehicle
- {
- /**
- * @var bool
- */
- protected $engine;
- public function start()
- {
- $this->engine = true;
- }
- public function stop()
- {
- $this->engine = false;
- }
- public function status()
- {
- return $this->engine ? "Automotor eingeschaltet" : "Automotor ausgeschaltet";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement