Advertisement
Guest User

uebung12

a guest
Nov 20th, 2017
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.59 KB | None | 0 0
  1. class Fahrzeug {
  2.  
  3. public $farbe;
  4. public $hersteller;
  5. public $kmStart = 0;
  6. public $kmStop;
  7.  
  8. public function starten() {
  9. echo "Sie sind gestartet";
  10.  
  11. }
  12.  
  13. public function stoppen() {
  14. echo "Sie haben ihre Fahrt beendet";
  15. }
  16.  
  17. /**
  18. * @param mixed $kmStart
  19. */
  20. public function setKmStart($kmStart) {
  21. $this->kmStart = $kmStart;
  22. }
  23.  
  24. /**
  25. * @param mixed $kmStop
  26. */
  27. public function setKmStop($kmStop) {
  28. $this->kmStop = $kmStop;
  29. }
  30.  
  31. /**
  32. * @return mixed
  33. */
  34. public function getKmStart() {
  35. return $this->kmStart;
  36. }
  37.  
  38. /**
  39. * @return mixed
  40. */
  41. public function getKmStop() {
  42. return $this->kmStop;
  43. }
  44.  
  45. /**
  46. * @param mixed $farbe
  47. */
  48. public function setFarbe($farbe) {
  49. $this->farbe = $farbe;
  50. }
  51.  
  52. /**
  53. * @param mixed $hersteller
  54. */
  55. public function setHersteller($hersteller) {
  56. $this->hersteller = $hersteller;
  57. }
  58. }
  59.  
  60. class Auto extends Fahrzeug {
  61. public $kmStand;
  62.  
  63. /*public function starten() {
  64.  
  65. }
  66. public function stoppen() {
  67.  
  68. }*/
  69.  
  70. public function kmStand() {
  71. $this->kmStand += $this->kmStop;
  72. }
  73. }
  74.  
  75. class Bank {
  76. public $kontonr;
  77. public $blz;
  78. public $name;
  79. public $kontostand;
  80. public $kontoart;
  81. public $dispo;
  82. public $zinsatz;
  83.  
  84. public function kontoEinrichten(){}
  85. public function kontoEinzahlung(){}
  86. public function kontoAuszahlung(){}
  87. public function kontoZinsErtrag(){}
  88.  
  89. }
  90.  
  91.  
  92. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement