note 128496 added to language.oop5.constants
| From: | Elpis at main dot php dot net | Date: | Wed, 10 May 2023 17:56:49 +0000 |
| Subject: | note 128496 added to language.oop5.constants | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-220451@lists.php.net to get a copy of this message | ||
<?php
/*******************KALSSE FAHRZEUG*************************/
abstract class Fahrzeug
{
protected $kennzeichen;
protected $kmStand;
protected $seitInspekt;
protected $abstandInspekt;
protected $istFrei;
protected $tagesPreis;
function __construct($kennz,$km)
{
$this->kennzeichen =$kennz;
$this->kmStand=$km;
$this->seitInspekt=$km;
$this->istFrei=true;
}
function vermieten():string
{
if($this->istFrei==true)
{
$this->istFrei=false;
return $this->kennzeichen." wird vermietet.<br>";
}
else
{
return $this->kennzeichen." ist bereits vermietet.<br>";
}
}
function zurueckgeben($gefKm)
{
$this->kmStand+=$gefKm;
$this->seitInspekt+=$gefKm;
if($this->seitInspekt>$this->abstandInspekt)
{
$this->inspektion();
}
$this->istFrei=true;
return "Fahrzeug erfolgreich zurueckgegeben<br>";
}
function inspektion()
{
----
Server IP: 45.112.84.4
Probable Submitter: 80.90.13.130 (proxied: 2a02:8071:886:7200:b566:992f:b83a:107d)
----
Manual Page -- https://php.net/manual/en/language.oop5.constants.php
Edit -- https://main.php.net/note/edit/128496
Del: integrated -- https://main.php.net/note/delete/128496/integrated
Del: useless -- https://main.php.net/note/delete/128496/useless
Del: bad code -- https://main.php.net/note/delete/128496/bad+code
Del: spam -- https://main.php.net/note/delete/128496/spam
Del: non-english -- https://main.php.net/note/delete/128496/non-english
Del: in docs -- https://main.php.net/note/delete/128496/in+docs
Del: other reasons-- https://main.php.net/note/delete/128496
Reject -- https://main.php.net/note/reject/128496
Search -- https://main.php.net/manage/user-notes.php