probléme avec interface enum
salut :=)
j n’arrive pas a comprend pourquoi l j’ai un problème dans le syntaxe l’interface enum
les deux valeur credit et debite sont inconnu :(
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34
| import java.util.*;
enum TypeOperation {credit,debit};
public class Operation {
// les attribues de la classe Operation
private TypeOperation type;
private float somme;
private String dateOperation;
// constructeur
public Operation(float somme,TypeOperation type);
{
this.somme=somme;
this.type=type;
this.dateOperation=new date().tostring();
}
// les accesseur en lecture
public float getsomme()
{
return somme;
}
public TypeOperation gettype()
{
return type;
}
public String getdateOperation()
{
return dateOperation;
}
} |