Spieler getName()

This commit is contained in:
Malin.sieckmann 2020-09-03 18:06:25 +02:00
parent 04d0a80dce
commit d071a1bf3b
3 changed files with 13 additions and 5 deletions

Binary file not shown.

View File

@ -11,9 +11,11 @@ comment4.target=void\ setNiederlagen(int)
comment5.params=pRundenAnzahl
comment5.target=void\ setRundenAnzahl(int)
comment6.params=
comment6.target=int\ getSiege()
comment6.target=java.lang.String\ getName()
comment7.params=
comment7.target=int\ getNiederlagen()
comment7.target=int\ getSiege()
comment8.params=
comment8.target=int\ getRundenAnzahl()
numComments=9
comment8.target=int\ getNiederlagen()
comment9.params=
comment9.target=int\ getRundenAnzahl()
numComments=10

View File

@ -5,7 +5,8 @@ public class Spieler {
int niederlagen;
int rundenAnzahl;
Scanner konsole = new Scanner(System.in);
public Spieler(String pName) {
public Spieler(String pName)
{
name = pName;
}
@ -33,6 +34,11 @@ public class Spieler {
}
//Get-Methoden
public String getName()
{
return name;
}
public int getSiege()
{
return siege;