added constraint
This commit is contained in:
parent
ebac675b3b
commit
a4fc5e5fe8
2 changed files with 84 additions and 79 deletions
|
@ -41,7 +41,12 @@ end
|
|||
|
||||
class Flotte
|
||||
operations
|
||||
ajouterBateau(bateau: Bateau)
|
||||
ajouterBateau(bateau: Bateau)
|
||||
constraints
|
||||
inv: bateaux->select(b: Bateau | b.type = TypeBateau::Torpilleur)->size() = 1
|
||||
inv: bateaux->select(b: Bateau | b.type = TypeBateau::Contre_Torpilleur)->size() = 2
|
||||
inv: bateaux->select(b: Bateau | b.type = TypeBateau::Croiseur)->size() = 1
|
||||
inv: bateaux->select(b: Bateau | b.type = TypeBateau::Porte_Avions)->size() = 1
|
||||
end
|
||||
|
||||
class Coup
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue