forked from 2211945/WIZARD_PR2_DOP
76 lines
1.8 KiB
Java
76 lines
1.8 KiB
Java
/*
|
|
============================================================
|
|
This is the "Zahlenkarte" file from Author: Philipp Kotte
|
|
written on: 05 / 10 / 2023 at: 23:30
|
|
============================================================
|
|
*/
|
|
package Domain.Karten;
|
|
|
|
import Domain.Enums.Kartenfarbe;
|
|
|
|
public class Zahlenkarte extends Karte {
|
|
|
|
/*------------------------------------------*/
|
|
// statische Konstanten
|
|
/*------------------------------------------*/
|
|
|
|
/*------------------------------------------*/
|
|
// statische Attribute(zB. zähler)
|
|
/*------------------------------------------*/
|
|
|
|
/*------------------------------------------*/
|
|
// Attribute jedes Objektes
|
|
/*------------------------------------------*/
|
|
private Kartenfarbe farbe;
|
|
private int wert;
|
|
|
|
/*------------------------------------------*/
|
|
// Konstruktoren (default und spezifische)
|
|
/*------------------------------------------*/
|
|
public Zahlenkarte() {
|
|
super();
|
|
}
|
|
|
|
public Zahlenkarte(Kartenfarbe farbe, int wert) {
|
|
super();
|
|
setFarbe(farbe);
|
|
setWert(wert);
|
|
|
|
}
|
|
/*------------------------------------------*/
|
|
// statische Methoden
|
|
/*------------------------------------------*/
|
|
|
|
/*------------------------------------------*/
|
|
// Getter und Setter
|
|
/*------------------------------------------*/
|
|
public void setFarbe(Kartenfarbe farbe) {
|
|
this.farbe = farbe;
|
|
}
|
|
|
|
public Kartenfarbe getFarbe() {
|
|
return farbe;
|
|
}
|
|
|
|
public void setWert(int kartenNummer) {
|
|
this.wert = kartenNummer;
|
|
}
|
|
|
|
public int getWert() {
|
|
return wert;
|
|
}
|
|
|
|
/*------------------------------------------*/
|
|
// @Overrides
|
|
/*------------------------------------------*/
|
|
|
|
/*------------------------------------------*/
|
|
// öffentliche Methodes
|
|
/*------------------------------------------*/
|
|
|
|
/*------------------------------------------*/
|
|
// Hilfsmethoden (privat)
|
|
/*------------------------------------------*/
|
|
|
|
}
|