💩 mon vpn marche pas zebi, fuck vclass

This commit is contained in:
Laurent Fainsin 2021-12-08 23:03:51 +01:00
parent e5c1f8058c
commit 05b85ab56c
31 changed files with 18118 additions and 16426 deletions

View file

@ -11,47 +11,47 @@
"Territoire": { "Territoire": {
"Lieux": [ "Lieux": [
{ {
"nom": "Énigme", "nom": "Enigme",
"deposable": "false", "deposable": true,
"depart": "true", "depart": true,
"fin": "false", "fin": false,
"personnes": [ "personnes": [
"Sphinx" "Sphinx"
], ],
"descriptions": [ "descriptions": [
{ {
"texte": "lieu de départ", "texte": "lieu de depart",
"condition": "true" "condition": true
} }
], ],
"objets": [], "objets": [],
"connaissances": [] "connaissances": []
}, },
{ {
"nom": "Succès", "nom": "Succes",
"deposable": "false", "deposable": false,
"depart": "false", "depart": false,
"fin": "true", "fin": true,
"personnes": [], "personnes": [],
"descriptions": [ "descriptions": [
{ {
"texte": "lieu succès", "texte": "lieu succes",
"condition": "true" "condition": true
} }
], ],
"objets": [], "objets": [],
"connaissances": [] "connaissances": []
}, },
{ {
"nom": "Échec", "nom": "Echec",
"deposable": "false", "deposable": false,
"depart": "false", "depart": false,
"fin": "true", "fin": true,
"personnes": [], "personnes": [],
"descriptions": [ "descriptions": [
{ {
"texte": "lieu échec", "texte": "lieu echec",
"condition": "true" "condition": true
} }
], ],
"objets": [], "objets": [],
@ -60,34 +60,36 @@
], ],
"Chemins": [ "Chemins": [
{ {
"lieu_in": "Énigme", "nom": "win",
"lieu_out": "Succès", "lieu_in": "Enigme",
"ouvert": "true", "lieu_out": "Succes",
"visible": "Réussite", "ouvert": true,
"obligatoire": "true", "visible": Reussite,
"obligatoire": true,
"connaissances": [], "connaissances": [],
"objets_recus": [], "objets_recus": [],
"objets_conso": [], "objets_conso": [],
"descriptions": [ "descriptions": [
{ {
"texte": "Le chemin de la victoire !", "texte": "Le chemin de la victoire !",
"condition": "true" "condition": true
} }
] ]
}, },
{ {
"lieu_in": "Énigme", "nom": "loose",
"lieu_out": "Échec", "lieu_in": "Enigme",
"ouvert": "true", "lieu_out": "Echec",
"visible": "tentatives == 0", "ouvert": true,
"obligatoire": "true", "visible": tentatives == 0,
"obligatoire": true,
"connaissances": [], "connaissances": [],
"objets_recus": [], "objets_recus": [],
"objets_conso": [], "objets_conso": [],
"descriptions": [ "descriptions": [
{ {
"texte": "Le chemin de la loose !", "texte": "Le chemin de la loose !",
"condition": "true" "condition": true
} }
] ]
} }
@ -97,23 +99,23 @@
{ {
"nom": "tentative", "nom": "tentative",
"taille": 1, "taille": 1,
"visible": "true", "visible": true,
"descriptions": [ "descriptions": [
{ {
"texte": "permet répondre une question du sphinx", "texte": "permet repondre une question du sphinx",
"condition": "true" "condition": true
} }
] ]
} }
], ],
"Connaissances": [ "Connaissances": [
{ {
"nom": "Réussite", "nom": "Reussite",
"visible": "true", "visible": true,
"descriptions": [ "descriptions": [
{ {
"texte": "Permet de se casser de là", "texte": "Permet de se casser de la",
"condition": "true" "condition": true
} }
] ]
} }
@ -121,33 +123,33 @@
"Personnes": [ "Personnes": [
{ {
"nom": "Sphinx", "nom": "Sphinx",
"visible": "!Reussite && tentative > 0", "visible": ! Reussite && tentative > 0,
"obligatoire": "true", "obligatoire": true,
"interactions": [ "interactions": [
{ {
"visible": "true", "visible": true,
"connaissances": [], "connaissances": [],
"objets_recus": [], "objets_recus": [],
"objets_conso": [], "objets_conso": [],
"actions": [ "actions": [
{ {
"visible": "true", "visible": true,
"fin_interaction": "true", "fin_interaction": true,
"connaissances": [ "connaissances": [
"Réussite" "Reussite"
], ],
"objets_recus": [], "objets_recus": [],
"objets_conso": [], "objets_conso": [],
"descriptions" : [ "descriptions" : [
{ {
"texte": "la bonne réponse", "texte": "la bonne reponse",
"condition": "true" "condition": true
} }
] ]
}, },
{ {
"visible": "true", "visible": true,
"fin_interaction": "true", "fin_interaction": true,
"connaissances": [], "connaissances": [],
"objets_recus": [], "objets_recus": [],
"objets_conso": [ "objets_conso": [
@ -155,8 +157,8 @@
], ],
"descriptions" : [ "descriptions" : [
{ {
"texte": "la mauvaise réponse", "texte": "la mauvaise reponse",
"condition": "true" "condition": true
} }
] ]
} }

View file

@ -6,87 +6,91 @@ List<Objet> jeu_objets = new ArrayList<>();
List<Description> objet_tentative_descriptions = new ArrayList<>(); List<Description> objet_tentative_descriptions = new ArrayList<>();
List<ConditionEt> objet_tentative_description_condition_1_conditions_ET = new ArrayList<>(); List<ConditionEt> objet_tentative_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> objet_tentative_description_condition_1_conditions_TEST_1 = new ArrayList<>(); List<ConditionTest> objet_tentative_description_1_conditions_TEST_1 = new ArrayList<>();
objet_tentative_description_condition_1_conditions_TEST_1.add( objet_tentative_description_1_conditions_TEST_1.add(
new ConditionConnaissance( new ConditionBoolean(true)
connaissance_true,
false
)
); );
objet_tentative_description_condition_1_conditions_ET.add(objet_tentative_description_condition_1_conditions_TEST_1) objet_tentative_description_1_conditions_ET.add(objet_tentative_description_1_conditions_TEST_1)
Condition objet_tentative_description_condition_1_condition = new Condition(objet_tentative_description_condition_1_conditions_ET);
Condition objet_tentative_description_1_condition = new Condition(objet_tentative_description_1_conditions_ET);
objet_tentative_descriptions.add( objet_tentative_descriptions.add(
new Description( new Description(
"permet répondre une question du sphinx", "permet repondre une question du sphinx",
objet_tentative_description_1_condition objet_tentative_description_1_condition
) )
); );
List<ConditionEt> objet_visible_tentative_conditions_ET = new ArrayList<>();
List<ConditionTest> objet_visible_tentative_conditions_TEST_1 = new ArrayList<>();
objet_visible_tentative_conditions_TEST_1.add(
new ConditionBoolean(true)
);
objet_visible_tentative_conditions_ET.add(objet_visible_tentative_conditions_TEST_1)
Condition objet_visible_tentative_condition = new Condition(objet_visible_tentative_conditions_ET);
Objet objet_tentative = new Objet( Objet objet_tentative = new Objet(
"tentative", "tentative",
1, 1,
vraie, objet_visible_tentative_condition,
objet_tentative_descriptions objet_tentative_descriptions
); );
jeu_objets.add(objet_tentative); jeu_objets.add(objet_tentative);
// "Connaissances" // "Connaissances"
List<Conaissance> jeu_connaissances = new ArrayList<>(); List<Conaissance> jeu_connaissances = new ArrayList<>();
List<Description> connaissance_Réussite_descriptions = new ArrayList<>(); List<Description> connaissance_Reussite_descriptions = new ArrayList<>();
List<ConditionEt> connaissance_Réussite_description_condition_1_conditions_ET = new ArrayList<>(); List<ConditionEt> connaissance_Reussite_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> connaissance_Réussite_description_condition_1_conditions_TEST_1 = new ArrayList<>(); List<ConditionTest> connaissance_Reussite_description_1_conditions_TEST_1 = new ArrayList<>();
connaissance_Réussite_description_condition_1_conditions_TEST_1.add( connaissance_Reussite_description_1_conditions_TEST_1.add(
new ConditionConnaissance( new ConditionBoolean(true)
connaissance_true,
false
)
); );
connaissance_Réussite_description_condition_1_conditions_ET.add(connaissance_Réussite_description_condition_1_conditions_TEST_1) connaissance_Reussite_description_1_conditions_ET.add(connaissance_Reussite_description_1_conditions_TEST_1)
Condition connaissance_Réussite_description_condition_1_condition = new Condition(connaissance_Réussite_description_condition_1_conditions_ET);
connaissance_Réussite_descriptions.add( Condition connaissance_Reussite_description_1_condition = new Condition(connaissance_Reussite_description_1_conditions_ET);
connaissance_Reussite_descriptions.add(
new Description( new Description(
"Permet de se casser de là", "Permet de se casser de la",
connaissance_Réussite_description_1_condition connaissance_Reussite_description_1_condition
) )
); );
List<ConditionEt> connaissance_Réussite_visible_conditions_ET = new ArrayList<>(); List<ConditionEt> connaissance_visible_Reussite_conditions_ET = new ArrayList<>();
List<ConditionTest> connaissance_Réussite_visible_conditions_TEST_1 = new ArrayList<>(); List<ConditionTest> connaissance_visible_Reussite_conditions_TEST_1 = new ArrayList<>();
connaissance_Réussite_visible_conditions_TEST_1.add( connaissance_visible_Reussite_conditions_TEST_1.add(
new ConditionConnaissance( new ConditionBoolean(true)
connaissance_true,
false
)
); );
connaissance_Réussite_visible_conditions_ET.add(connaissance_Réussite_visible_conditions_TEST_1) connaissance_visible_Reussite_conditions_ET.add(connaissance_visible_Reussite_conditions_TEST_1)
Condition connaissance_Réussite_visible_condition = new Condition(connaissance_Réussite_visible_conditions_ET);
Connaissance connaissance_Réussite = new Connaissance( Condition connaissance_visible_Reussite_condition = new Condition(connaissance_visible_Reussite_conditions_ET);
"Réussite", Connaissance connaissance_Reussite = new Connaissance(
connaissance_Réussite_visible, "Reussite",
connaissance_Réussite_descriptions connaissance_visible_Reussite_condition,
connaissance_Reussite_descriptions
); );
jeu_connaissances.add(connaissance_Réussite); jeu_connaissances.add(connaissance_Reussite);
// "Transformations" // "Transformations"
List<Transformation> jeu_transformations = new ArrayList<>(); List<Transformation> jeu_transformations = new ArrayList<>();
// "Explorateur" // "Explorateur"
List<Objet> explorateur_inventaire = new ArrayList<>();
List<Objet> explorateur_inventaire = new ArrayList<>();
explorateur_inventaire.add(objet_tentative); explorateur_inventaire.add(objet_tentative);
explorateur_inventaire.add(objet_tentative); explorateur_inventaire.add(objet_tentative);
explorateur_inventaire.add(objet_tentative); explorateur_inventaire.add(objet_tentative);
@ -99,4 +103,573 @@ Jeu.explorateur = new Explorateur(
explorateur_inventaire explorateur_inventaire
); );
// "Personnes"
List<Personne> jeu_personnes = new ArrayList<>();
List<ConditionEt> personne_visible_Sphinx_1_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_visible_Sphinx_1_conditions_TEST_1 = new ArrayList<>();
personne_visible_Sphinx_1_conditions_TEST_1.add(
new ConditionConnaissance(
connaissance_Reussite,
false
)
);
personne_visible_Sphinx_1_conditions_ET.add(personne_visible_Sphinx_1_conditions_TEST_1)
personne_visible_Sphinx_1_conditions_TEST_2.add(
new ConditionObjet(
objet_tentative,
">",
0
)
);
personne_visible_Sphinx_1_conditions_ET.add(personne_visible_Sphinx_1_conditions_TEST_2)
Condition personne_visible_Sphinx_1_condition = new Condition(personne_visible_Sphinx_1_conditions_ET);
List<ConditionEt> personne_obligatoire_Sphinx_1_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_obligatoire_Sphinx_1_conditions_TEST_1 = new ArrayList<>();
personne_obligatoire_Sphinx_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
personne_obligatoire_Sphinx_1_conditions_ET.add(personne_obligatoire_Sphinx_1_conditions_TEST_1)
Condition personne_obligatoire_Sphinx_1_condition = new Condition(personne_obligatoire_Sphinx_1_conditions_ET);
List<Action> personne_Sphinx_1_interactions = new ArrayList<>();
List<ConditionEt> personne_Sphinx_1_interaction_visible_1_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_Sphinx_1_interaction_visible_1_conditions_TEST_1 = new ArrayList<>();
personne_Sphinx_1_interaction_visible_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
personne_Sphinx_1_interaction_visible_1_conditions_ET.add(personne_Sphinx_1_interaction_visible_1_conditions_TEST_1)
Condition personne_Sphinx_1_interaction_visible_1_condition = new Condition(personne_Sphinx_1_interaction_visible_1_conditions_ET);
List<Action> personne_Sphinx_1_interaction_1_actions = new ArrayList<>();
List<ConditionEt> personne_Sphinx_1_interaction_1_action_visible_1_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_Sphinx_1_interaction_1_action_visible_1_conditions_TEST_1 = new ArrayList<>();
personne_Sphinx_1_interaction_1_action_visible_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
personne_Sphinx_1_interaction_1_action_visible_1_conditions_ET.add(personne_Sphinx_1_interaction_1_action_visible_1_conditions_TEST_1)
Condition personne_Sphinx_1_interaction_1_action_visible_1_condition = new Condition(personne_Sphinx_1_interaction_1_action_visible_1_conditions_ET);
List<ConditionEt> personne_Sphinx_1_interaction_1_action_fin_1_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_Sphinx_1_interaction_1_action_fin_1_conditions_TEST_1 = new ArrayList<>();
personne_Sphinx_1_interaction_1_action_fin_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
personne_Sphinx_1_interaction_1_action_fin_1_conditions_ET.add(personne_Sphinx_1_interaction_1_action_fin_1_conditions_TEST_1)
Condition personne_Sphinx_1_interaction_1_action_fin_1_condition = new Condition(personne_Sphinx_1_interaction_1_action_fin_1_conditions_ET);
List<Description> personne_Sphinx_1_interaction_1_descriptions = new ArrayList<>();
List<ConditionEt> personne_Sphinx_1_interaction_1_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_Sphinx_1_interaction_1_description_1_conditions_TEST_1 = new ArrayList<>();
personne_Sphinx_1_interaction_1_description_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
personne_Sphinx_1_interaction_1_description_1_conditions_ET.add(personne_Sphinx_1_interaction_1_description_1_conditions_TEST_1)
Condition personne_Sphinx_1_interaction_1_description_1_condition = new Condition(personne_Sphinx_1_interaction_1_description_1_conditions_ET);
personne_Sphinx_1_interaction_1_descriptions.add(
new Description(
"la bonne reponse",
personne_Sphinx_1_interaction_1_description_1_condition
)
);
List<Connaissance> personne_Sphinx_1_interaction_1_action_1_connaissances = new ArrayList<>();
personne_Sphinx_1_interaction_1_action_1_connaissances.add(connaissance_Reussite);
List<Objet> personne_Sphinx_1_interaction_1_action_1_objets_conso = new ArrayList<>();
List<Objet> personne_Sphinx_1_interaction_1_action_1_objets_recus = new ArrayList<>();
personne_Sphinx_1_interaction_1_actions.add(
new Action(
personne_Sphinx_1_interaction_1_action_visible_1_condition,
personne_Sphinx_1_interaction_1_action_fin_1_condition,
personne_Sphinx_1_interaction_1_action_1_connaissances,
personne_Sphinx_1_interaction_1_action_1_objets_conso,
personne_Sphinx_1_interaction_1_action_1_objets_recus,
personne_Sphinx_1_interaction_1_action_1_descriptions
)
);
List<ConditionEt> personne_Sphinx_1_interaction_1_action_visible_2_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_Sphinx_1_interaction_1_action_visible_2_conditions_TEST_1 = new ArrayList<>();
personne_Sphinx_1_interaction_1_action_visible_2_conditions_TEST_1.add(
new ConditionBoolean(true)
);
personne_Sphinx_1_interaction_1_action_visible_2_conditions_ET.add(personne_Sphinx_1_interaction_1_action_visible_2_conditions_TEST_1)
Condition personne_Sphinx_1_interaction_1_action_visible_2_condition = new Condition(personne_Sphinx_1_interaction_1_action_visible_2_conditions_ET);
List<ConditionEt> personne_Sphinx_1_interaction_1_action_fin_2_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_Sphinx_1_interaction_1_action_fin_2_conditions_TEST_1 = new ArrayList<>();
personne_Sphinx_1_interaction_1_action_fin_2_conditions_TEST_1.add(
new ConditionBoolean(true)
);
personne_Sphinx_1_interaction_1_action_fin_2_conditions_ET.add(personne_Sphinx_1_interaction_1_action_fin_2_conditions_TEST_1)
Condition personne_Sphinx_1_interaction_1_action_fin_2_condition = new Condition(personne_Sphinx_1_interaction_1_action_fin_2_conditions_ET);
List<Description> personne_Sphinx_1_interaction_1_descriptions = new ArrayList<>();
List<ConditionEt> personne_Sphinx_1_interaction_1_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> personne_Sphinx_1_interaction_1_description_1_conditions_TEST_1 = new ArrayList<>();
personne_Sphinx_1_interaction_1_description_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
personne_Sphinx_1_interaction_1_description_1_conditions_ET.add(personne_Sphinx_1_interaction_1_description_1_conditions_TEST_1)
Condition personne_Sphinx_1_interaction_1_description_1_condition = new Condition(personne_Sphinx_1_interaction_1_description_1_conditions_ET);
personne_Sphinx_1_interaction_1_descriptions.add(
new Description(
"la mauvaise reponse",
personne_Sphinx_1_interaction_1_description_1_condition
)
);
List<Connaissance> personne_Sphinx_1_interaction_1_action_2_connaissances = new ArrayList<>();
List<Objet> personne_Sphinx_1_interaction_1_action_2_objets_conso = new ArrayList<>();
personne_Sphinx_1_interaction_1_action_1_objets_conso.add(objet_tentative);
List<Objet> personne_Sphinx_1_interaction_1_action_2_objets_recus = new ArrayList<>();
personne_Sphinx_1_interaction_1_actions.add(
new Action(
personne_Sphinx_1_interaction_1_action_visible_2_condition,
personne_Sphinx_1_interaction_1_action_fin_2_condition,
personne_Sphinx_1_interaction_1_action_2_connaissances,
personne_Sphinx_1_interaction_1_action_2_objets_conso,
personne_Sphinx_1_interaction_1_action_2_objets_recus,
personne_Sphinx_1_interaction_1_action_2_descriptions
)
);
List<Connaissance> personne_Sphinx_1_interaction_1_connaissances = new ArrayList<>();
List<Objet> personne_Sphinx_1_interaction_1_objets_conso = new ArrayList<>();
List<Objet> personne_Sphinx_1_interaction_1_objets_recus = new ArrayList<>();
personne_Sphinx_1_actions.add(
new Action(
personne_Sphinx_1_interaction_visible_1_condition,
personne_Sphinx_1_interaction_1_connaissances,
personne_Sphinx_1_interaction_1_objets_conso,
personne_Sphinx_1_interaction_1_objets_recus,
personne_Sphinx_1_interaction_1_actions
)
);
Personne personne_Sphinx = new Personne(
"Sphinx",
personne_visible_Sphinx_1_condition,
personne_obligatoire_Sphinx_1_condition,
personne_Sphinx_1_interactions
);
jeu_personnes.add(personne_Sphinx);
// "Lieux"
List<Lieu> territoire_lieux = new ArrayList<>();
List<ConditionEt> lieu_deposable_1_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_deposable_1_conditions_TEST_1 = new ArrayList<>();
lieu_deposable_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
lieu_deposable_1_conditions_ET.add(lieu_deposable_1_conditions_TEST_1)
Condition lieu_deposable_1_condition = new Condition(lieu_deposable_1_conditions_ET);
List<ConditionEt> lieu_depart_1_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_depart_1_conditions_TEST_1 = new ArrayList<>();
lieu_depart_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
lieu_depart_1_conditions_ET.add(lieu_depart_1_conditions_TEST_1)
Condition lieu_depart_1_condition = new Condition(lieu_depart_1_conditions_ET);
List<ConditionEt> lieu_fin_1_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_fin_1_conditions_TEST_1 = new ArrayList<>();
lieu_fin_1_conditions_TEST_1.add(
new ConditionBoolean(false)
);
lieu_fin_1_conditions_ET.add(lieu_fin_1_conditions_TEST_1)
Condition lieu_fin_1_condition = new Condition(lieu_fin_1_conditions_ET);
List<Description> lieu_Enigme_1_descriptions = new ArrayList<>();
List<ConditionEt> lieu_Enigme_1_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_Enigme_1_description_1_conditions_TEST_1 = new ArrayList<>();
lieu_Enigme_1_description_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
lieu_Enigme_1_description_1_conditions_ET.add(lieu_Enigme_1_description_1_conditions_TEST_1)
Condition lieu_Enigme_1_description_1_condition = new Condition(lieu_Enigme_1_description_1_conditions_ET);
lieu_Enigme_1_descriptions.add(
new Description(
"lieu de depart",
lieu_Enigme_1_description_1_condition
)
);
List<Personne> lieu_Enigme_1_personnes = new ArrayList<>();
lieu_Enigme_1_personnes.add(objet_Sphinx);
List<Objet> lieu_Enigme_1_objets = new ArrayList<>();
List<Connaissance> lieu_Enigme_1_connaissances = new ArrayList<>();
// TODO: utiliser un search dans la liste plutot que de déclarer les objets
Lieu lieu_Enigme = new Lieu(
"Enigme",
lieu_deposable_1_condition,
lieu_depart_1_condition,
lieu_fin_1_condition,
lieu_Enigme_1_personnes,
lieu_Enigme_1_descriptions,
lieu_Enigme_1_objets,
lieu_Enigme_1_connaissances
);
territoire_lieux.add(lieu_Enigme);
List<ConditionEt> lieu_deposable_2_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_deposable_2_conditions_TEST_1 = new ArrayList<>();
lieu_deposable_2_conditions_TEST_1.add(
new ConditionBoolean(false)
);
lieu_deposable_2_conditions_ET.add(lieu_deposable_2_conditions_TEST_1)
Condition lieu_deposable_2_condition = new Condition(lieu_deposable_2_conditions_ET);
List<ConditionEt> lieu_depart_2_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_depart_2_conditions_TEST_1 = new ArrayList<>();
lieu_depart_2_conditions_TEST_1.add(
new ConditionBoolean(false)
);
lieu_depart_2_conditions_ET.add(lieu_depart_2_conditions_TEST_1)
Condition lieu_depart_2_condition = new Condition(lieu_depart_2_conditions_ET);
List<ConditionEt> lieu_fin_2_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_fin_2_conditions_TEST_1 = new ArrayList<>();
lieu_fin_2_conditions_TEST_1.add(
new ConditionBoolean(true)
);
lieu_fin_2_conditions_ET.add(lieu_fin_2_conditions_TEST_1)
Condition lieu_fin_2_condition = new Condition(lieu_fin_2_conditions_ET);
List<Description> lieu_Succes_2_descriptions = new ArrayList<>();
List<ConditionEt> lieu_Succes_2_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_Succes_2_description_1_conditions_TEST_1 = new ArrayList<>();
lieu_Succes_2_description_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
lieu_Succes_2_description_1_conditions_ET.add(lieu_Succes_2_description_1_conditions_TEST_1)
Condition lieu_Succes_2_description_1_condition = new Condition(lieu_Succes_2_description_1_conditions_ET);
lieu_Succes_2_descriptions.add(
new Description(
"lieu succes",
lieu_Succes_2_description_1_condition
)
);
List<Personne> lieu_Succes_2_personnes = new ArrayList<>();
List<Objet> lieu_Succes_2_objets = new ArrayList<>();
List<Connaissance> lieu_Succes_2_connaissances = new ArrayList<>();
// TODO: utiliser un search dans la liste plutot que de déclarer les objets
Lieu lieu_Succes = new Lieu(
"Succes",
lieu_deposable_2_condition,
lieu_depart_2_condition,
lieu_fin_2_condition,
lieu_Succes_2_personnes,
lieu_Succes_2_descriptions,
lieu_Succes_2_objets,
lieu_Succes_2_connaissances
);
territoire_lieux.add(lieu_Succes);
List<ConditionEt> lieu_deposable_3_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_deposable_3_conditions_TEST_1 = new ArrayList<>();
lieu_deposable_3_conditions_TEST_1.add(
new ConditionBoolean(false)
);
lieu_deposable_3_conditions_ET.add(lieu_deposable_3_conditions_TEST_1)
Condition lieu_deposable_3_condition = new Condition(lieu_deposable_3_conditions_ET);
List<ConditionEt> lieu_depart_3_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_depart_3_conditions_TEST_1 = new ArrayList<>();
lieu_depart_3_conditions_TEST_1.add(
new ConditionBoolean(false)
);
lieu_depart_3_conditions_ET.add(lieu_depart_3_conditions_TEST_1)
Condition lieu_depart_3_condition = new Condition(lieu_depart_3_conditions_ET);
List<ConditionEt> lieu_fin_3_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_fin_3_conditions_TEST_1 = new ArrayList<>();
lieu_fin_3_conditions_TEST_1.add(
new ConditionBoolean(true)
);
lieu_fin_3_conditions_ET.add(lieu_fin_3_conditions_TEST_1)
Condition lieu_fin_3_condition = new Condition(lieu_fin_3_conditions_ET);
List<Description> lieu_Echec_3_descriptions = new ArrayList<>();
List<ConditionEt> lieu_Echec_3_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> lieu_Echec_3_description_1_conditions_TEST_1 = new ArrayList<>();
lieu_Echec_3_description_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
lieu_Echec_3_description_1_conditions_ET.add(lieu_Echec_3_description_1_conditions_TEST_1)
Condition lieu_Echec_3_description_1_condition = new Condition(lieu_Echec_3_description_1_conditions_ET);
lieu_Echec_3_descriptions.add(
new Description(
"lieu echec",
lieu_Echec_3_description_1_condition
)
);
List<Personne> lieu_Echec_3_personnes = new ArrayList<>();
List<Objet> lieu_Echec_3_objets = new ArrayList<>();
List<Connaissance> lieu_Echec_3_connaissances = new ArrayList<>();
// TODO: utiliser un search dans la liste plutot que de déclarer les objets
Lieu lieu_Echec = new Lieu(
"Echec",
lieu_deposable_3_condition,
lieu_depart_3_condition,
lieu_fin_3_condition,
lieu_Echec_3_personnes,
lieu_Echec_3_descriptions,
lieu_Echec_3_objets,
lieu_Echec_3_connaissances
);
territoire_lieux.add(lieu_Echec);
// "Chemins"
List<Chemin> territoire_chemins = new ArrayList<>();
List<ConditionEt> chemin_ouvert_win_1_conditions_ET = new ArrayList<>();
List<ConditionTest> chemin_ouvert_win_1_conditions_TEST_1 = new ArrayList<>();
chemin_ouvert_win_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
chemin_ouvert_win_1_conditions_ET.add(chemin_ouvert_win_1_conditions_TEST_1)
Condition chemin_ouvert_win_1_condition = new Condition(chemin_ouvert_win_1_conditions_ET);
List<ConditionEt> chemin_visible_win_1_conditions_ET = new ArrayList<>();
List<ConditionTest> chemin_visible_win_1_conditions_TEST_1 = new ArrayList<>();
chemin_visible_win_1_conditions_TEST_1.add(
new ConditionConnaissance(
connaissance_Reussite,
false
)
);
chemin_visible_win_1_conditions_ET.add(chemin_visible_win_1_conditions_TEST_1)
Condition chemin_visible_win_1_condition = new Condition(chemin_visible_win_1_conditions_ET);
List<ConditionEt> chemin_obligatoire_win_1_conditions_ET = new ArrayList<>();
List<ConditionTest> chemin_obligatoire_win_1_conditions_TEST_1 = new ArrayList<>();
chemin_obligatoire_win_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
chemin_obligatoire_win_1_conditions_ET.add(chemin_obligatoire_win_1_conditions_TEST_1)
Condition chemin_obligatoire_win_1_condition = new Condition(chemin_obligatoire_win_1_conditions_ET);
List<Description> chemin_win_1_descriptions = new ArrayList<>();
List<ConditionEt> chemin_win_1_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> chemin_win_1_description_1_conditions_TEST_1 = new ArrayList<>();
chemin_win_1_description_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
chemin_win_1_description_1_conditions_ET.add(chemin_win_1_description_1_conditions_TEST_1)
Condition chemin_win_1_description_1_condition = new Condition(chemin_win_1_description_1_conditions_ET);
chemin_win_1_descriptions.add(
new Description(
"Le chemin de la victoire !",
chemin_win_1_description_1_condition
)
);
List<Connaissance> chemin_win_1_connaissances = new ArrayList<>();
List<Objet> chemin_win_1_objet_recus = new ArrayList<>();
List<Objet> chemin_win_1_objet_conso = new ArrayList<>();
Chemin chemins_win new Chemin(
"win",
lieu_Enigme,
lieu_Succes,
chemin_ouvert_win_1_condition,
chemin_visible_win_1_condition,
chemin_obligatoire_win_1_condition,
chemin_win_1_connaissances
chemin_win_1_objets_recus,
chemin_win_1_objets_conso,
chemin_win_1_descriptions,
);
territoire_chemins.add(chemins_win);
List<ConditionEt> chemin_ouvert_loose_2_conditions_ET = new ArrayList<>();
List<ConditionTest> chemin_ouvert_loose_2_conditions_TEST_1 = new ArrayList<>();
chemin_ouvert_loose_2_conditions_TEST_1.add(
new ConditionBoolean(true)
);
chemin_ouvert_loose_2_conditions_ET.add(chemin_ouvert_loose_2_conditions_TEST_1)
Condition chemin_ouvert_loose_2_condition = new Condition(chemin_ouvert_loose_2_conditions_ET);
List<ConditionEt> chemin_visible_loose_2_conditions_ET = new ArrayList<>();
List<ConditionTest> chemin_visible_loose_2_conditions_TEST_1 = new ArrayList<>();
chemin_visible_loose_2_conditions_TEST_1.add(
new ConditionObjet(
objet_tentatives,
"==",
0
)
);
chemin_visible_loose_2_conditions_ET.add(chemin_visible_loose_2_conditions_TEST_1)
Condition chemin_visible_loose_2_condition = new Condition(chemin_visible_loose_2_conditions_ET);
List<ConditionEt> chemin_obligatoire_loose_2_conditions_ET = new ArrayList<>();
List<ConditionTest> chemin_obligatoire_loose_2_conditions_TEST_1 = new ArrayList<>();
chemin_obligatoire_loose_2_conditions_TEST_1.add(
new ConditionBoolean(true)
);
chemin_obligatoire_loose_2_conditions_ET.add(chemin_obligatoire_loose_2_conditions_TEST_1)
Condition chemin_obligatoire_loose_2_condition = new Condition(chemin_obligatoire_loose_2_conditions_ET);
List<Description> chemin_loose_2_descriptions = new ArrayList<>();
List<ConditionEt> chemin_loose_2_description_1_conditions_ET = new ArrayList<>();
List<ConditionTest> chemin_loose_2_description_1_conditions_TEST_1 = new ArrayList<>();
chemin_loose_2_description_1_conditions_TEST_1.add(
new ConditionBoolean(true)
);
chemin_loose_2_description_1_conditions_ET.add(chemin_loose_2_description_1_conditions_TEST_1)
Condition chemin_loose_2_description_1_condition = new Condition(chemin_loose_2_description_1_conditions_ET);
chemin_loose_2_descriptions.add(
new Description(
"Le chemin de la loose !",
chemin_loose_2_description_1_condition
)
);
List<Connaissance> chemin_loose_2_connaissances = new ArrayList<>();
List<Objet> chemin_loose_2_objet_recus = new ArrayList<>();
List<Objet> chemin_loose_2_objet_conso = new ArrayList<>();
Chemin chemins_loose new Chemin(
"loose",
lieu_Enigme,
lieu_Echec,
chemin_ouvert_loose_2_condition,
chemin_visible_loose_2_condition,
chemin_obligatoire_loose_2_condition,
chemin_loose_2_connaissances
chemin_loose_2_objets_recus,
chemin_loose_2_objets_conso,
chemin_loose_2_descriptions,
);
territoire_chemins.add(chemins_loose);
}
} }

View file

@ -13,15 +13,15 @@ public static void main(String['['/][']'/] args) {
List<Objet> jeu_objets = new ArrayList<>(); List<Objet> jeu_objets = new ArrayList<>();
[for (o : Objet | jeu.objets)] [for (o : Objet | jeu.objets)]
[print(o.descriptions, 'objet_' + o.nom.nom)/] [print_descriptions(o.descriptions, 'objet_' + o.nom.nom)/]
[print_condition(o.visible, 'objet_visible_' + o.nom.nom)/]
Objet objet_[o.nom.nom/] = new Objet( Objet objet_[o.nom.nom/] = new Objet(
"[o.nom.nom/]", "[o.nom.nom/]",
[o.taille/], [o.taille/],
vraie, objet_visible_[o.nom.nom/]_condition,
objet_[o.nom.nom/]_descriptions objet_[o.nom.nom/]_descriptions
); );
jeu_objets.add(objet_[o.nom.nom/]); jeu_objets.add(objet_[o.nom.nom/]);
[/for] [/for]
[comment Connaissances /] [comment Connaissances /]
@ -29,11 +29,11 @@ List<Objet> jeu_objets = new ArrayList<>();
List<Conaissance> jeu_connaissances = new ArrayList<>(); List<Conaissance> jeu_connaissances = new ArrayList<>();
[for (c : Connaissance | jeu.connaissances)] [for (c : Connaissance | jeu.connaissances)]
[print(c.descriptions, 'connaissance_' + c.nom.nom)/] [print_descriptions(c.descriptions, 'connaissance_' + c.nom.nom)/]
[print(c.visible, 'connaissance_' + c.nom.nom + '_visible')/] [print_condition(c.visible, 'connaissance_visible_' + c.nom.nom)/]
Connaissance connaissance_[c.nom.nom/] = new Connaissance( Connaissance connaissance_[c.nom.nom/] = new Connaissance(
"[c.nom.nom/]", "[c.nom.nom/]",
connaissance_[c.nom.nom/]_visible, connaissance_visible_[c.nom.nom/]_condition,
connaissance_[c.nom.nom/]_descriptions connaissance_[c.nom.nom/]_descriptions
); );
jeu_connaissances.add(connaissance_[c.nom.nom/]); jeu_connaissances.add(connaissance_[c.nom.nom/]);
@ -44,7 +44,7 @@ List<Conaissance> jeu_connaissances = new ArrayList<>();
List<Transformation> jeu_transformations = new ArrayList<>(); List<Transformation> jeu_transformations = new ArrayList<>();
[for (t : Transformation | jeu.transformations)] [for (t : Transformation | jeu.transformations)]
[print(t.condition, 'transformation_' + i.toString())/] [print_condition(t.condition, 'transformation_' + i.toString())/]
List<Objet> transformation_[i/]_objets_in = new ArrayList<>(); List<Objet> transformation_[i/]_objets_in = new ArrayList<>();
[for (c : Nom | t.objetsIn)] [for (c : Nom | t.objetsIn)]
@ -66,8 +66,8 @@ List<Transformation> jeu_transformations = new ArrayList<>();
[comment Explorateur /] [comment Explorateur /]
// "Explorateur" // "Explorateur"
List<Objet> explorateur_inventaire = new ArrayList<>();
List<Objet> explorateur_inventaire = new ArrayList<>();
[for (o : Nom | jeu.explorateur.objets)] [for (o : Nom | jeu.explorateur.objets)]
explorateur_inventaire.add(objet_[o.nom/]); explorateur_inventaire.add(objet_[o.nom/]);
[/for] [/for]
@ -89,9 +89,9 @@ Jeu.explorateur = new Explorateur(
List<Personne> jeu_personnes = new ArrayList<>(); List<Personne> jeu_personnes = new ArrayList<>();
[for (p : Personne | jeu.personnes)] [for (p : Personne | jeu.personnes)]
[print(p.visible, 'personne_visible' + p.nom.nom + '_' + i.toString())/] [print_condition(p.visible, 'personne_visible_' + p.nom.nom + '_' + i.toString())/]
[print(p.obligatoire, 'personne_obligatoire' + p.nom.nom + '_' + i.toString())/] [print_condition(p.obligatoire, 'personne_obligatoire_' + p.nom.nom + '_' + i.toString())/]
[print(p.interactions, 'personne_' + p.nom.nom + '_' + i.toString())/] [print_interactions(p.interactions, 'personne_' + p.nom.nom + '_' + i.toString())/]
Personne personne_[p.nom.nom/] = new Personne( Personne personne_[p.nom.nom/] = new Personne(
"[p.nom.nom/]", "[p.nom.nom/]",
@ -101,7 +101,6 @@ List<Personne> jeu_personnes = new ArrayList<>();
); );
jeu_personnes.add(personne_[p.nom.nom/]); jeu_personnes.add(personne_[p.nom.nom/]);
[/for] [/for]
[comment Lieux /] [comment Lieux /]
@ -109,10 +108,10 @@ List<Personne> jeu_personnes = new ArrayList<>();
List<Lieu> territoire_lieux = new ArrayList<>(); List<Lieu> territoire_lieux = new ArrayList<>();
[for (l : Lieu | jeu.territoire.lieux)] [for (l : Lieu | jeu.territoire.lieux)]
[print(l.deposable, 'lieu_deposable' + i.toString())/] [print_condition(l.deposable, 'lieu_deposable_' + i.toString())/]
[print(l.depart, 'lieu_depart' + i.toString())/] [print_condition(l.depart, 'lieu_depart_' + i.toString())/]
[print(l.fin, 'lieu_fin' + i.toString())/] [print_condition(l.fin, 'lieu_fin_' + i.toString())/]
[print(l.descriptions, 'lieu_' + l.nom.nom + '_' + i.toString())/] [print_descriptions(l.descriptions, 'lieu_' + l.nom.nom + '_' + i.toString())/]
List<Personne> lieu_[l.nom.nom/]_[i/]_personnes = new ArrayList<>(); List<Personne> lieu_[l.nom.nom/]_[i/]_personnes = new ArrayList<>();
[for (p : Nom | l.personnes)] [for (p : Nom | l.personnes)]
@ -129,7 +128,7 @@ List<Lieu> territoire_lieux = new ArrayList<>();
// TODO: utiliser un search dans la liste plutot que de déclarer les objets // TODO: utiliser un search dans la liste plutot que de déclarer les objets
Lieu lieu_[l.nom.nom/] = new Lieu( Lieu lieu_[l.nom.nom/] = new Lieu(
[l.nom.nom/], "[l.nom.nom/]",
lieu_deposable_[i/]_condition, lieu_deposable_[i/]_condition,
lieu_depart_[i/]_condition, lieu_depart_[i/]_condition,
lieu_fin_[i/]_condition, lieu_fin_[i/]_condition,
@ -148,28 +147,28 @@ List<Lieu> territoire_lieux = new ArrayList<>();
List<Chemin> territoire_chemins = new ArrayList<>(); List<Chemin> territoire_chemins = new ArrayList<>();
[for (ch : Chemin | jeu.territoire.chemins)] [for (ch : Chemin | jeu.territoire.chemins)]
[print(ch.ouvert, 'chemin_ouvert' + ch.nom.nom + '_' + i.toString())/] [print_condition(ch.ouvert, 'chemin_ouvert_' + ch.nom.nom + '_' + i.toString())/]
[print(ch.visible, 'chemin_visible' + ch.nom.nom + '_' + i.toString())/] [print_condition(ch.visible, 'chemin_visible_' + ch.nom.nom + '_' + i.toString())/]
[print(ch.obligatoire, 'chemin_obligatoire' + ch.nom.nom + '_' + i.toString())/] [print_condition(ch.obligatoire, 'chemin_obligatoire_' + ch.nom.nom + '_' + i.toString())/]
[print(ch.descriptions, 'chemin_' + ch.nom.nom + '_' + i.toString())/] [print_descriptions(ch.descriptions, 'chemin_' + ch.nom.nom + '_' + i.toString())/]
List<Connaissance> chemin_[ch.nom.nom/]_[i/]_connaissances = new ArrayList<>(); List<Connaissance> chemin_[ch.nom.nom/]_[i/]_connaissances = new ArrayList<>();
[for (c : Nom | ch.connaissances)] [for (c : Nom | ch.connaissances)]
lieu_[ch.nom.nom/]_[i/]_connaissances.add(connaissance_[c.nom/]); chemin_[ch.nom.nom/]_[i/]_connaissances.add(connaissance_[c.nom/]);
[/for] [/for]
List<Objet> chemin_[ch.nom.nom/]_[i/]_objet_recus = new ArrayList<>(); List<Objet> chemin_[ch.nom.nom/]_[i/]_objet_recus = new ArrayList<>();
[for (o : Nom | ch.objetsRecus)] [for (o : Nom | ch.objetsRecus)]
lieu_[ch.nom.nom/]_[i/]_objets_recus.add(objet_[o.nom/]); chemin_[ch.nom.nom/]_[i/]_objets_recus.add(objet_[o.nom/]);
[/for] [/for]
List<Objet> chemin_[ch.nom.nom/]_[i/]_objet_conso = new ArrayList<>(); List<Objet> chemin_[ch.nom.nom/]_[i/]_objet_conso = new ArrayList<>();
[for (o : Nom | ch.objetsConso)] [for (o : Nom | ch.objetsConso)]
lieu_[ch.nom.nom/]_[i/]_objets_conso.add(objet_[o.nom/]); chemin_[ch.nom.nom/]_[i/]_objets_conso.add(objet_[o.nom/]);
[/for] [/for]
Chemin chemins_[ch.nom.nom/] new Chemin( Chemin chemins_[ch.nom.nom/] new Chemin(
[ch.nom.nom/], "[ch.nom.nom/]",
lieu_[ch.lieuIn/], lieu_[ch.lieuIn.nom/],
lieu_[ch.lieuOut/], lieu_[ch.lieuOut.nom/],
chemin_ouvert_[ch.nom.nom/]_[i/]_condition, chemin_ouvert_[ch.nom.nom/]_[i/]_condition,
chemin_visible_[ch.nom.nom/]_[i/]_condition, chemin_visible_[ch.nom.nom/]_[i/]_condition,
chemin_obligatoire_[ch.nom.nom/]_[i/]_condition, chemin_obligatoire_[ch.nom.nom/]_[i/]_condition,
@ -182,11 +181,12 @@ List<Chemin> territoire_chemins = new ArrayList<>();
territoire_chemins.add(chemins_[ch.nom.nom/]); territoire_chemins.add(chemins_[ch.nom.nom/]);
[/for] [/for]
}
} }
[/file] [/file]
[/template] [/template]
[template public print(c : Condition, name: String) post (trim()) ] [template public print_condition(c : Condition, name: String) post (trim()) ]
List<ConditionEt> [name/]_conditions_ET = new ArrayList<>(); List<ConditionEt> [name/]_conditions_ET = new ArrayList<>();
[for (cET : ConditionEt | c.condition)] [for (cET : ConditionEt | c.condition)]
@ -194,23 +194,21 @@ List<ConditionEt> [name/]_conditions_ET = new ArrayList<>();
[for (cTEST : ConditionTest | cET.conditionTest)] [for (cTEST : ConditionTest | cET.conditionTest)]
[name/]_conditions_TEST_[i/].add( [name/]_conditions_TEST_[i/].add(
[if (cTEST.oclIsTypeOf(ConditionBoolean))] [if (cTEST.oclIsKindOf(ConditionBoolean))]
[let cBOOL : ConditionBoolean = cTEST.oclAsType(ConditionBoolean)] [let cBOOL : ConditionBoolean = cTEST.oclAsType(ConditionBoolean)]
new ConditionBoolean( new ConditionBoolean([cBOOL.valeur/])
[cBOOL.valeur/],
)
[/let] [/let]
[elseif (cTEST.oclIsTypeOf(ConditionConnaissance))] [elseif (cTEST.oclIsKindOf(ConditionConnaissance))]
[let cCONN : ConditionConnaissance = cTEST.oclAsType(ConditionConnaissance)] [let cCONN : ConditionConnaissance = cTEST.oclAsType(ConditionConnaissance)]
new ConditionConnaissance( new ConditionConnaissance(
connaissance_[cCONN.connaissance.nom/], connaissance_[cCONN.connaissance/],
[if (cCONN.connaissance.nom.startsWith('!'))]true[else]false[/if] [if (cCONN.connaissance.startsWith('!'))]true[else]false[/if]
) )
[/let] [/let]
[elseif (cTEST.oclIsTypeOf(ConditionObjet))] [elseif (cTEST.oclIsKindOf(ConditionObjet))]
[let cOBJET : ConditionObjet = cTEST.oclAsType(ConditionObjet)] [let cOBJET : ConditionObjet = cTEST.oclAsType(ConditionObjet)]
new ConditionObjet( new ConditionObjet(
objet_[cOBJET.objet.nom/], objet_[cOBJET.objet/],
"[cOBJET.comparateur/]", "[cOBJET.comparateur/]",
[cOBJET.nombre/] [cOBJET.nombre/]
) )
@ -218,17 +216,18 @@ List<ConditionEt> [name/]_conditions_ET = new ArrayList<>();
[/if] [/if]
); );
[name/]_conditions_ET.add([name/]_conditions_TEST_[i/]) [name/]_conditions_ET.add([name/]_conditions_TEST_[i/])
[/for] [/for]
[/for] [/for]
Condition [name/]_condition = new Condition([name/]_conditions_ET); Condition [name/]_condition = new Condition([name/]_conditions_ET);
[/template] [/template]
[template public print(ds : OrderedSet(Description), name: String) post (trim()) ] [template public print_descriptions(ds : OrderedSet(Description), name: String) post (trim()) ]
List<Description> [name/]_descriptions = new ArrayList<>(); List<Description> [name/]_descriptions = new ArrayList<>();
[for (d : Description | ds)] [for (d : Description | ds)]
[print(d.condition, name + '_description_condition_' + i.toString())/] [print_condition(d.condition, name + '_description_' + i.toString())/]
[name/]_descriptions.add( [name/]_descriptions.add(
new Description( new Description(
@ -239,13 +238,13 @@ List<Description> [name/]_descriptions = new ArrayList<>();
[/for] [/for]
[/template] [/template]
[template public print(as : OrderedSet(Action), name: String) post (trim()) ] [template public print_actions(as : OrderedSet(Action), name: String) post (trim()) ]
List<Action> [name/]_actions = new ArrayList<>(); List<Action> [name/]_actions = new ArrayList<>();
[for (a : Action | as)] [for (a : Action | as)]
[print(a.visible, name + '_action_visible_' + i.toString())/] [print_condition(a.visible, name + '_action_visible_' + i.toString())/]
[print(a.finInteraction, name + '_action_fin_' + i.toString())/] [print_condition(a.finInteraction, name + '_action_fin_' + i.toString())/]
[print(a.descriptions, name)/] [print_descriptions(a.descriptions, name)/]
List<Connaissance> [name/]_action_[i/]_connaissances = new ArrayList<>(); List<Connaissance> [name/]_action_[i/]_connaissances = new ArrayList<>();
[for (c : Nom | a.connaissances)] [for (c : Nom | a.connaissances)]
@ -273,12 +272,12 @@ List<Action> [name/]_actions = new ArrayList<>();
[/for] [/for]
[/template] [/template]
[template public print(is: OrderedSet(Interaction), name: String)] [template public print_interactions(is: OrderedSet(Interaction), name: String)]
List<Action> [name/]_interactions = new ArrayList<>(); List<Action> [name/]_interactions = new ArrayList<>();
[for (it : Interaction | is)] [for (it : Interaction | is)]
[print(it.visible, name + '_interaction_visible_' + i.toString())/] [print_condition(it.visible, name + '_interaction_visible_' + i.toString())/]
[print(it.actions, name + '_' + i.toString())/] [print_actions(it.actions, name + '_interaction_' + i.toString())/]
List<Connaissance> [name/]_interaction_[i/]_connaissances = new ArrayList<>(); List<Connaissance> [name/]_interaction_[i/]_connaissances = new ArrayList<>();
[for (c : Nom | it.connaissances)] [for (c : Nom | it.connaissances)]

View file

@ -13,15 +13,15 @@ public static void main(String['['/][']'/] args) {
List<Objet> jeu_objets = new ArrayList<>(); List<Objet> jeu_objets = new ArrayList<>();
[for (o : Objet | jeu.objets)] [for (o : Objet | jeu.objets)]
[print(o.descriptions, 'objet_' + o.nom.nom)/] [print_descriptions(o.descriptions, 'objet_' + o.nom.nom)/]
[print_condition(o.visible, 'objet_visible_' + o.nom.nom)/]
Objet objet_[o.nom.nom/] = new Objet( Objet objet_[o.nom.nom/] = new Objet(
"[o.nom.nom/]", "[o.nom.nom/]",
[o.taille/], [o.taille/],
vraie, objet_visible_[o.nom.nom/]_condition,
objet_[o.nom.nom/]_descriptions objet_[o.nom.nom/]_descriptions
); );
jeu_objets.add(objet_[o.nom.nom/]); jeu_objets.add(objet_[o.nom.nom/]);
[/for] [/for]
[comment Connaissances /] [comment Connaissances /]
@ -29,11 +29,11 @@ List<Objet> jeu_objets = new ArrayList<>();
List<Conaissance> jeu_connaissances = new ArrayList<>(); List<Conaissance> jeu_connaissances = new ArrayList<>();
[for (c : Connaissance | jeu.connaissances)] [for (c : Connaissance | jeu.connaissances)]
[print(c.descriptions, 'connaissance_' + c.nom.nom)/] [print_descriptions(c.descriptions, 'connaissance_' + c.nom.nom)/]
[print(c.visible, 'connaissance_' + c.nom.nom + '_visible')/] [print_condition(c.visible, 'connaissance_visible_' + c.nom.nom)/]
Connaissance connaissance_[c.nom.nom/] = new Connaissance( Connaissance connaissance_[c.nom.nom/] = new Connaissance(
"[c.nom.nom/]", "[c.nom.nom/]",
connaissance_[c.nom.nom/]_visible, connaissance_visible_[c.nom.nom/]_condition,
connaissance_[c.nom.nom/]_descriptions connaissance_[c.nom.nom/]_descriptions
); );
jeu_connaissances.add(connaissance_[c.nom.nom/]); jeu_connaissances.add(connaissance_[c.nom.nom/]);
@ -44,7 +44,7 @@ List<Conaissance> jeu_connaissances = new ArrayList<>();
List<Transformation> jeu_transformations = new ArrayList<>(); List<Transformation> jeu_transformations = new ArrayList<>();
[for (t : Transformation | jeu.transformations)] [for (t : Transformation | jeu.transformations)]
[print(t.condition, 'transformation_' + i.toString())/] [print_condition(t.condition, 'transformation_' + i.toString())/]
List<Objet> transformation_[i/]_objets_in = new ArrayList<>(); List<Objet> transformation_[i/]_objets_in = new ArrayList<>();
[for (c : Nom | t.objetsIn)] [for (c : Nom | t.objetsIn)]
@ -66,8 +66,8 @@ List<Transformation> jeu_transformations = new ArrayList<>();
[comment Explorateur /] [comment Explorateur /]
// "Explorateur" // "Explorateur"
List<Objet> explorateur_inventaire = new ArrayList<>();
List<Objet> explorateur_inventaire = new ArrayList<>();
[for (o : Nom | jeu.explorateur.objets)] [for (o : Nom | jeu.explorateur.objets)]
explorateur_inventaire.add(objet_[o.nom/]); explorateur_inventaire.add(objet_[o.nom/]);
[/for] [/for]
@ -89,9 +89,9 @@ Jeu.explorateur = new Explorateur(
List<Personne> jeu_personnes = new ArrayList<>(); List<Personne> jeu_personnes = new ArrayList<>();
[for (p : Personne | jeu.personnes)] [for (p : Personne | jeu.personnes)]
[print(p.visible, 'personne_visible' + p.nom.nom + '_' + i.toString())/] [print_condition(p.visible, 'personne_visible_' + p.nom.nom + '_' + i.toString())/]
[print(p.obligatoire, 'personne_obligatoire' + p.nom.nom + '_' + i.toString())/] [print_condition(p.obligatoire, 'personne_obligatoire_' + p.nom.nom + '_' + i.toString())/]
[print(p.interactions, 'personne_' + p.nom.nom + '_' + i.toString())/] [print_interactions(p.interactions, 'personne_' + p.nom.nom + '_' + i.toString())/]
Personne personne_[p.nom.nom/] = new Personne( Personne personne_[p.nom.nom/] = new Personne(
"[p.nom.nom/]", "[p.nom.nom/]",
@ -101,7 +101,6 @@ List<Personne> jeu_personnes = new ArrayList<>();
); );
jeu_personnes.add(personne_[p.nom.nom/]); jeu_personnes.add(personne_[p.nom.nom/]);
[/for] [/for]
[comment Lieux /] [comment Lieux /]
@ -109,10 +108,10 @@ List<Personne> jeu_personnes = new ArrayList<>();
List<Lieu> territoire_lieux = new ArrayList<>(); List<Lieu> territoire_lieux = new ArrayList<>();
[for (l : Lieu | jeu.territoire.lieux)] [for (l : Lieu | jeu.territoire.lieux)]
[print(l.deposable, 'lieu_deposable' + i.toString())/] [print_condition(l.deposable, 'lieu_deposable_' + i.toString())/]
[print(l.depart, 'lieu_depart' + i.toString())/] [print_condition(l.depart, 'lieu_depart_' + i.toString())/]
[print(l.fin, 'lieu_fin' + i.toString())/] [print_condition(l.fin, 'lieu_fin_' + i.toString())/]
[print(l.descriptions, 'lieu_' + l.nom.nom + '_' + i.toString())/] [print_descriptions(l.descriptions, 'lieu_' + l.nom.nom + '_' + i.toString())/]
List<Personne> lieu_[l.nom.nom/]_[i/]_personnes = new ArrayList<>(); List<Personne> lieu_[l.nom.nom/]_[i/]_personnes = new ArrayList<>();
[for (p : Nom | l.personnes)] [for (p : Nom | l.personnes)]
@ -129,7 +128,7 @@ List<Lieu> territoire_lieux = new ArrayList<>();
// TODO: utiliser un search dans la liste plutot que de déclarer les objets // TODO: utiliser un search dans la liste plutot que de déclarer les objets
Lieu lieu_[l.nom.nom/] = new Lieu( Lieu lieu_[l.nom.nom/] = new Lieu(
[l.nom.nom/], "[l.nom.nom/]",
lieu_deposable_[i/]_condition, lieu_deposable_[i/]_condition,
lieu_depart_[i/]_condition, lieu_depart_[i/]_condition,
lieu_fin_[i/]_condition, lieu_fin_[i/]_condition,
@ -148,28 +147,28 @@ List<Lieu> territoire_lieux = new ArrayList<>();
List<Chemin> territoire_chemins = new ArrayList<>(); List<Chemin> territoire_chemins = new ArrayList<>();
[for (ch : Chemin | jeu.territoire.chemins)] [for (ch : Chemin | jeu.territoire.chemins)]
[print(ch.ouvert, 'chemin_ouvert' + ch.nom.nom + '_' + i.toString())/] [print_condition(ch.ouvert, 'chemin_ouvert_' + ch.nom.nom + '_' + i.toString())/]
[print(ch.visible, 'chemin_visible' + ch.nom.nom + '_' + i.toString())/] [print_condition(ch.visible, 'chemin_visible_' + ch.nom.nom + '_' + i.toString())/]
[print(ch.obligatoire, 'chemin_obligatoire' + ch.nom.nom + '_' + i.toString())/] [print_condition(ch.obligatoire, 'chemin_obligatoire_' + ch.nom.nom + '_' + i.toString())/]
[print(ch.descriptions, 'chemin_' + ch.nom.nom + '_' + i.toString())/] [print_descriptions(ch.descriptions, 'chemin_' + ch.nom.nom + '_' + i.toString())/]
List<Connaissance> chemin_[ch.nom.nom/]_[i/]_connaissances = new ArrayList<>(); List<Connaissance> chemin_[ch.nom.nom/]_[i/]_connaissances = new ArrayList<>();
[for (c : Nom | ch.connaissances)] [for (c : Nom | ch.connaissances)]
lieu_[ch.nom.nom/]_[i/]_connaissances.add(connaissance_[c.nom/]); chemin_[ch.nom.nom/]_[i/]_connaissances.add(connaissance_[c.nom/]);
[/for] [/for]
List<Objet> chemin_[ch.nom.nom/]_[i/]_objet_recus = new ArrayList<>(); List<Objet> chemin_[ch.nom.nom/]_[i/]_objet_recus = new ArrayList<>();
[for (o : Nom | ch.objetsRecus)] [for (o : Nom | ch.objetsRecus)]
lieu_[ch.nom.nom/]_[i/]_objets_recus.add(objet_[o.nom/]); chemin_[ch.nom.nom/]_[i/]_objets_recus.add(objet_[o.nom/]);
[/for] [/for]
List<Objet> chemin_[ch.nom.nom/]_[i/]_objet_conso = new ArrayList<>(); List<Objet> chemin_[ch.nom.nom/]_[i/]_objet_conso = new ArrayList<>();
[for (o : Nom | ch.objetsConso)] [for (o : Nom | ch.objetsConso)]
lieu_[ch.nom.nom/]_[i/]_objets_conso.add(objet_[o.nom/]); chemin_[ch.nom.nom/]_[i/]_objets_conso.add(objet_[o.nom/]);
[/for] [/for]
Chemin chemins_[ch.nom.nom/] new Chemin( Chemin chemins_[ch.nom.nom/] new Chemin(
[ch.nom.nom/], "[ch.nom.nom/]",
lieu_[ch.lieuIn/], lieu_[ch.lieuIn.nom/],
lieu_[ch.lieuOut/], lieu_[ch.lieuOut.nom/],
chemin_ouvert_[ch.nom.nom/]_[i/]_condition, chemin_ouvert_[ch.nom.nom/]_[i/]_condition,
chemin_visible_[ch.nom.nom/]_[i/]_condition, chemin_visible_[ch.nom.nom/]_[i/]_condition,
chemin_obligatoire_[ch.nom.nom/]_[i/]_condition, chemin_obligatoire_[ch.nom.nom/]_[i/]_condition,
@ -182,11 +181,12 @@ List<Chemin> territoire_chemins = new ArrayList<>();
territoire_chemins.add(chemins_[ch.nom.nom/]); territoire_chemins.add(chemins_[ch.nom.nom/]);
[/for] [/for]
}
} }
[/file] [/file]
[/template] [/template]
[template public print(c : Condition, name: String) post (trim()) ] [template public print_condition(c : Condition, name: String) post (trim()) ]
List<ConditionEt> [name/]_conditions_ET = new ArrayList<>(); List<ConditionEt> [name/]_conditions_ET = new ArrayList<>();
[for (cET : ConditionEt | c.condition)] [for (cET : ConditionEt | c.condition)]
@ -194,23 +194,21 @@ List<ConditionEt> [name/]_conditions_ET = new ArrayList<>();
[for (cTEST : ConditionTest | cET.conditionTest)] [for (cTEST : ConditionTest | cET.conditionTest)]
[name/]_conditions_TEST_[i/].add( [name/]_conditions_TEST_[i/].add(
[if (cTEST.oclIsTypeOf(ConditionBoolean))] [if (cTEST.oclIsKindOf(ConditionBoolean))]
[let cBOOL : ConditionBoolean = cTEST.oclAsType(ConditionBoolean)] [let cBOOL : ConditionBoolean = cTEST.oclAsType(ConditionBoolean)]
new ConditionBoolean( new ConditionBoolean([cBOOL.valeur/])
[cBOOL.valeur/],
)
[/let] [/let]
[elseif (cTEST.oclIsTypeOf(ConditionConnaissance))] [elseif (cTEST.oclIsKindOf(ConditionConnaissance))]
[let cCONN : ConditionConnaissance = cTEST.oclAsType(ConditionConnaissance)] [let cCONN : ConditionConnaissance = cTEST.oclAsType(ConditionConnaissance)]
new ConditionConnaissance( new ConditionConnaissance(
connaissance_[cCONN.connaissance.nom/], connaissance_[cCONN.connaissance/],
[if (cCONN.connaissance.nom.startsWith('!'))]true[else]false[/if] [if (cCONN.connaissance.startsWith('!'))]true[else]false[/if]
) )
[/let] [/let]
[elseif (cTEST.oclIsTypeOf(ConditionObjet))] [elseif (cTEST.oclIsKindOf(ConditionObjet))]
[let cOBJET : ConditionObjet = cTEST.oclAsType(ConditionObjet)] [let cOBJET : ConditionObjet = cTEST.oclAsType(ConditionObjet)]
new ConditionObjet( new ConditionObjet(
objet_[cOBJET.objet.nom/], objet_[cOBJET.objet/],
"[cOBJET.comparateur/]", "[cOBJET.comparateur/]",
[cOBJET.nombre/] [cOBJET.nombre/]
) )
@ -218,17 +216,18 @@ List<ConditionEt> [name/]_conditions_ET = new ArrayList<>();
[/if] [/if]
); );
[name/]_conditions_ET.add([name/]_conditions_TEST_[i/]) [name/]_conditions_ET.add([name/]_conditions_TEST_[i/])
[/for] [/for]
[/for] [/for]
Condition [name/]_condition = new Condition([name/]_conditions_ET); Condition [name/]_condition = new Condition([name/]_conditions_ET);
[/template] [/template]
[template public print(ds : OrderedSet(Description), name: String) post (trim()) ] [template public print_descriptions(ds : OrderedSet(Description), name: String) post (trim()) ]
List<Description> [name/]_descriptions = new ArrayList<>(); List<Description> [name/]_descriptions = new ArrayList<>();
[for (d : Description | ds)] [for (d : Description | ds)]
[print(d.condition, name + '_description_condition_' + i.toString())/] [print_condition(d.condition, name + '_description_' + i.toString())/]
[name/]_descriptions.add( [name/]_descriptions.add(
new Description( new Description(
@ -239,13 +238,13 @@ List<Description> [name/]_descriptions = new ArrayList<>();
[/for] [/for]
[/template] [/template]
[template public print(as : OrderedSet(Action), name: String) post (trim()) ] [template public print_actions(as : OrderedSet(Action), name: String) post (trim()) ]
List<Action> [name/]_actions = new ArrayList<>(); List<Action> [name/]_actions = new ArrayList<>();
[for (a : Action | as)] [for (a : Action | as)]
[print(a.visible, name + '_action_visible_' + i.toString())/] [print_condition(a.visible, name + '_action_visible_' + i.toString())/]
[print(a.finInteraction, name + '_action_fin_' + i.toString())/] [print_condition(a.finInteraction, name + '_action_fin_' + i.toString())/]
[print(a.descriptions, name)/] [print_descriptions(a.descriptions, name)/]
List<Connaissance> [name/]_action_[i/]_connaissances = new ArrayList<>(); List<Connaissance> [name/]_action_[i/]_connaissances = new ArrayList<>();
[for (c : Nom | a.connaissances)] [for (c : Nom | a.connaissances)]
@ -273,12 +272,12 @@ List<Action> [name/]_actions = new ArrayList<>();
[/for] [/for]
[/template] [/template]
[template public print(is: OrderedSet(Interaction), name: String)] [template public print_interactions(is: OrderedSet(Interaction), name: String)]
List<Action> [name/]_interactions = new ArrayList<>(); List<Action> [name/]_interactions = new ArrayList<>();
[for (it : Interaction | is)] [for (it : Interaction | is)]
[print(it.visible, name + '_interaction_visible_' + i.toString())/] [print_condition(it.visible, name + '_interaction_visible_' + i.toString())/]
[print(it.actions, name + '_' + i.toString())/] [print_actions(it.actions, name + '_interaction_' + i.toString())/]
List<Connaissance> [name/]_interaction_[i/]_connaissances = new ArrayList<>(); List<Connaissance> [name/]_interaction_[i/]_connaissances = new ArrayList<>();
[for (c : Nom | it.connaissances)] [for (c : Nom | it.connaissances)]

View file

@ -32,8 +32,6 @@ public class GameParser extends AbstractContentAssistParser {
private static void init(ImmutableMap.Builder<AbstractElement, String> builder, GameGrammarAccess grammarAccess) { private static void init(ImmutableMap.Builder<AbstractElement, String> builder, GameGrammarAccess grammarAccess) {
builder.put(grammarAccess.getConditionTestAccess().getAlternatives(), "rule__ConditionTest__Alternatives"); builder.put(grammarAccess.getConditionTestAccess().getAlternatives(), "rule__ConditionTest__Alternatives");
builder.put(grammarAccess.getComparateurAccess().getAlternatives(), "rule__Comparateur__Alternatives");
builder.put(grammarAccess.getBooleanAccess().getAlternatives(), "rule__Boolean__Alternatives");
builder.put(grammarAccess.getJeuAccess().getGroup(), "rule__Jeu__Group__0"); builder.put(grammarAccess.getJeuAccess().getGroup(), "rule__Jeu__Group__0");
builder.put(grammarAccess.getJeuAccess().getGroup_12(), "rule__Jeu__Group_12__0"); builder.put(grammarAccess.getJeuAccess().getGroup_12(), "rule__Jeu__Group_12__0");
builder.put(grammarAccess.getJeuAccess().getGroup_12_1(), "rule__Jeu__Group_12_1__0"); builder.put(grammarAccess.getJeuAccess().getGroup_12_1(), "rule__Jeu__Group_12_1__0");
@ -62,13 +60,13 @@ public class GameParser extends AbstractContentAssistParser {
builder.put(grammarAccess.getLieuAccess().getGroup_39(), "rule__Lieu__Group_39__0"); builder.put(grammarAccess.getLieuAccess().getGroup_39(), "rule__Lieu__Group_39__0");
builder.put(grammarAccess.getLieuAccess().getGroup_39_1(), "rule__Lieu__Group_39_1__0"); builder.put(grammarAccess.getLieuAccess().getGroup_39_1(), "rule__Lieu__Group_39_1__0");
builder.put(grammarAccess.getCheminAccess().getGroup(), "rule__Chemin__Group__0"); builder.put(grammarAccess.getCheminAccess().getGroup(), "rule__Chemin__Group__0");
builder.put(grammarAccess.getCheminAccess().getGroup_24(), "rule__Chemin__Group_24__0"); builder.put(grammarAccess.getCheminAccess().getGroup_28(), "rule__Chemin__Group_28__0");
builder.put(grammarAccess.getCheminAccess().getGroup_24_1(), "rule__Chemin__Group_24_1__0"); builder.put(grammarAccess.getCheminAccess().getGroup_28_1(), "rule__Chemin__Group_28_1__0");
builder.put(grammarAccess.getCheminAccess().getGroup_30(), "rule__Chemin__Group_30__0"); builder.put(grammarAccess.getCheminAccess().getGroup_34(), "rule__Chemin__Group_34__0");
builder.put(grammarAccess.getCheminAccess().getGroup_30_1(), "rule__Chemin__Group_30_1__0"); builder.put(grammarAccess.getCheminAccess().getGroup_34_1(), "rule__Chemin__Group_34_1__0");
builder.put(grammarAccess.getCheminAccess().getGroup_36(), "rule__Chemin__Group_36__0"); builder.put(grammarAccess.getCheminAccess().getGroup_40(), "rule__Chemin__Group_40__0");
builder.put(grammarAccess.getCheminAccess().getGroup_36_1(), "rule__Chemin__Group_36_1__0"); builder.put(grammarAccess.getCheminAccess().getGroup_40_1(), "rule__Chemin__Group_40_1__0");
builder.put(grammarAccess.getCheminAccess().getGroup_43(), "rule__Chemin__Group_43__0"); builder.put(grammarAccess.getCheminAccess().getGroup_47(), "rule__Chemin__Group_47__0");
builder.put(grammarAccess.getObjetAccess().getGroup(), "rule__Objet__Group__0"); builder.put(grammarAccess.getObjetAccess().getGroup(), "rule__Objet__Group__0");
builder.put(grammarAccess.getObjetAccess().getGroup_17(), "rule__Objet__Group_17__0"); builder.put(grammarAccess.getObjetAccess().getGroup_17(), "rule__Objet__Group_17__0");
builder.put(grammarAccess.getTransformationAccess().getGroup(), "rule__Transformation__Group__0"); builder.put(grammarAccess.getTransformationAccess().getGroup(), "rule__Transformation__Group__0");
@ -102,7 +100,9 @@ public class GameParser extends AbstractContentAssistParser {
builder.put(grammarAccess.getConditionAccess().getGroup_1(), "rule__Condition__Group_1__0"); builder.put(grammarAccess.getConditionAccess().getGroup_1(), "rule__Condition__Group_1__0");
builder.put(grammarAccess.getConditionEtAccess().getGroup(), "rule__ConditionEt__Group__0"); builder.put(grammarAccess.getConditionEtAccess().getGroup(), "rule__ConditionEt__Group__0");
builder.put(grammarAccess.getConditionEtAccess().getGroup_1(), "rule__ConditionEt__Group_1__0"); builder.put(grammarAccess.getConditionEtAccess().getGroup_1(), "rule__ConditionEt__Group_1__0");
builder.put(grammarAccess.getConditionConnaissanceAccess().getGroup(), "rule__ConditionConnaissance__Group__0");
builder.put(grammarAccess.getConditionObjetAccess().getGroup(), "rule__ConditionObjet__Group__0"); builder.put(grammarAccess.getConditionObjetAccess().getGroup(), "rule__ConditionObjet__Group__0");
builder.put(grammarAccess.getNomAccess().getGroup(), "rule__Nom__Group__0");
builder.put(grammarAccess.getJeuAccess().getExplorateurAssignment_3(), "rule__Jeu__ExplorateurAssignment_3"); builder.put(grammarAccess.getJeuAccess().getExplorateurAssignment_3(), "rule__Jeu__ExplorateurAssignment_3");
builder.put(grammarAccess.getJeuAccess().getTerritoireAssignment_7(), "rule__Jeu__TerritoireAssignment_7"); builder.put(grammarAccess.getJeuAccess().getTerritoireAssignment_7(), "rule__Jeu__TerritoireAssignment_7");
builder.put(grammarAccess.getJeuAccess().getObjetsAssignment_12_0(), "rule__Jeu__ObjetsAssignment_12_0"); builder.put(grammarAccess.getJeuAccess().getObjetsAssignment_12_0(), "rule__Jeu__ObjetsAssignment_12_0");
@ -134,19 +134,20 @@ public class GameParser extends AbstractContentAssistParser {
builder.put(grammarAccess.getLieuAccess().getObjetsAssignment_33_1_1(), "rule__Lieu__ObjetsAssignment_33_1_1"); builder.put(grammarAccess.getLieuAccess().getObjetsAssignment_33_1_1(), "rule__Lieu__ObjetsAssignment_33_1_1");
builder.put(grammarAccess.getLieuAccess().getConnaissancesAssignment_39_0(), "rule__Lieu__ConnaissancesAssignment_39_0"); builder.put(grammarAccess.getLieuAccess().getConnaissancesAssignment_39_0(), "rule__Lieu__ConnaissancesAssignment_39_0");
builder.put(grammarAccess.getLieuAccess().getConnaissancesAssignment_39_1_1(), "rule__Lieu__ConnaissancesAssignment_39_1_1"); builder.put(grammarAccess.getLieuAccess().getConnaissancesAssignment_39_1_1(), "rule__Lieu__ConnaissancesAssignment_39_1_1");
builder.put(grammarAccess.getCheminAccess().getLieuInAssignment_3(), "rule__Chemin__LieuInAssignment_3"); builder.put(grammarAccess.getCheminAccess().getNomAssignment_3(), "rule__Chemin__NomAssignment_3");
builder.put(grammarAccess.getCheminAccess().getLieuOutAssignment_7(), "rule__Chemin__LieuOutAssignment_7"); builder.put(grammarAccess.getCheminAccess().getLieuInAssignment_7(), "rule__Chemin__LieuInAssignment_7");
builder.put(grammarAccess.getCheminAccess().getOuvertAssignment_11(), "rule__Chemin__OuvertAssignment_11"); builder.put(grammarAccess.getCheminAccess().getLieuOutAssignment_11(), "rule__Chemin__LieuOutAssignment_11");
builder.put(grammarAccess.getCheminAccess().getVisibleAssignment_15(), "rule__Chemin__VisibleAssignment_15"); builder.put(grammarAccess.getCheminAccess().getOuvertAssignment_15(), "rule__Chemin__OuvertAssignment_15");
builder.put(grammarAccess.getCheminAccess().getObligatoireAssignment_19(), "rule__Chemin__ObligatoireAssignment_19"); builder.put(grammarAccess.getCheminAccess().getVisibleAssignment_19(), "rule__Chemin__VisibleAssignment_19");
builder.put(grammarAccess.getCheminAccess().getConnaissancesAssignment_24_0(), "rule__Chemin__ConnaissancesAssignment_24_0"); builder.put(grammarAccess.getCheminAccess().getObligatoireAssignment_23(), "rule__Chemin__ObligatoireAssignment_23");
builder.put(grammarAccess.getCheminAccess().getConnaissancesAssignment_24_1_1(), "rule__Chemin__ConnaissancesAssignment_24_1_1"); builder.put(grammarAccess.getCheminAccess().getConnaissancesAssignment_28_0(), "rule__Chemin__ConnaissancesAssignment_28_0");
builder.put(grammarAccess.getCheminAccess().getObjetsRecusAssignment_30_0(), "rule__Chemin__ObjetsRecusAssignment_30_0"); builder.put(grammarAccess.getCheminAccess().getConnaissancesAssignment_28_1_1(), "rule__Chemin__ConnaissancesAssignment_28_1_1");
builder.put(grammarAccess.getCheminAccess().getObjetsRecusAssignment_30_1_1(), "rule__Chemin__ObjetsRecusAssignment_30_1_1"); builder.put(grammarAccess.getCheminAccess().getObjetsRecusAssignment_34_0(), "rule__Chemin__ObjetsRecusAssignment_34_0");
builder.put(grammarAccess.getCheminAccess().getObjetsConsoAssignment_36_0(), "rule__Chemin__ObjetsConsoAssignment_36_0"); builder.put(grammarAccess.getCheminAccess().getObjetsRecusAssignment_34_1_1(), "rule__Chemin__ObjetsRecusAssignment_34_1_1");
builder.put(grammarAccess.getCheminAccess().getObjetsConsoAssignment_36_1_1(), "rule__Chemin__ObjetsConsoAssignment_36_1_1"); builder.put(grammarAccess.getCheminAccess().getObjetsConsoAssignment_40_0(), "rule__Chemin__ObjetsConsoAssignment_40_0");
builder.put(grammarAccess.getCheminAccess().getDescriptionsAssignment_42(), "rule__Chemin__DescriptionsAssignment_42"); builder.put(grammarAccess.getCheminAccess().getObjetsConsoAssignment_40_1_1(), "rule__Chemin__ObjetsConsoAssignment_40_1_1");
builder.put(grammarAccess.getCheminAccess().getDescriptionsAssignment_43_1(), "rule__Chemin__DescriptionsAssignment_43_1"); builder.put(grammarAccess.getCheminAccess().getDescriptionsAssignment_46(), "rule__Chemin__DescriptionsAssignment_46");
builder.put(grammarAccess.getCheminAccess().getDescriptionsAssignment_47_1(), "rule__Chemin__DescriptionsAssignment_47_1");
builder.put(grammarAccess.getObjetAccess().getNomAssignment_3(), "rule__Objet__NomAssignment_3"); builder.put(grammarAccess.getObjetAccess().getNomAssignment_3(), "rule__Objet__NomAssignment_3");
builder.put(grammarAccess.getObjetAccess().getTailleAssignment_7(), "rule__Objet__TailleAssignment_7"); builder.put(grammarAccess.getObjetAccess().getTailleAssignment_7(), "rule__Objet__TailleAssignment_7");
builder.put(grammarAccess.getObjetAccess().getVisibleAssignment_11(), "rule__Objet__VisibleAssignment_11"); builder.put(grammarAccess.getObjetAccess().getVisibleAssignment_11(), "rule__Objet__VisibleAssignment_11");
@ -192,11 +193,12 @@ public class GameParser extends AbstractContentAssistParser {
builder.put(grammarAccess.getConditionEtAccess().getConditionTestAssignment_0(), "rule__ConditionEt__ConditionTestAssignment_0"); builder.put(grammarAccess.getConditionEtAccess().getConditionTestAssignment_0(), "rule__ConditionEt__ConditionTestAssignment_0");
builder.put(grammarAccess.getConditionEtAccess().getConditionTestAssignment_1_1(), "rule__ConditionEt__ConditionTestAssignment_1_1"); builder.put(grammarAccess.getConditionEtAccess().getConditionTestAssignment_1_1(), "rule__ConditionEt__ConditionTestAssignment_1_1");
builder.put(grammarAccess.getConditionBooleanAccess().getValeurAssignment(), "rule__ConditionBoolean__ValeurAssignment"); builder.put(grammarAccess.getConditionBooleanAccess().getValeurAssignment(), "rule__ConditionBoolean__ValeurAssignment");
builder.put(grammarAccess.getConditionConnaissanceAccess().getConnaissanceAssignment(), "rule__ConditionConnaissance__ConnaissanceAssignment"); builder.put(grammarAccess.getConditionConnaissanceAccess().getNegationAssignment_0(), "rule__ConditionConnaissance__NegationAssignment_0");
builder.put(grammarAccess.getConditionConnaissanceAccess().getConnaissanceAssignment_1(), "rule__ConditionConnaissance__ConnaissanceAssignment_1");
builder.put(grammarAccess.getConditionObjetAccess().getObjetAssignment_0(), "rule__ConditionObjet__ObjetAssignment_0"); builder.put(grammarAccess.getConditionObjetAccess().getObjetAssignment_0(), "rule__ConditionObjet__ObjetAssignment_0");
builder.put(grammarAccess.getConditionObjetAccess().getComparateurAssignment_1(), "rule__ConditionObjet__ComparateurAssignment_1"); builder.put(grammarAccess.getConditionObjetAccess().getComparateurAssignment_1(), "rule__ConditionObjet__ComparateurAssignment_1");
builder.put(grammarAccess.getConditionObjetAccess().getNombreAssignment_2(), "rule__ConditionObjet__NombreAssignment_2"); builder.put(grammarAccess.getConditionObjetAccess().getNombreAssignment_2(), "rule__ConditionObjet__NombreAssignment_2");
builder.put(grammarAccess.getNomAccess().getNomAssignment(), "rule__Nom__NomAssignment"); builder.put(grammarAccess.getNomAccess().getNomAssignment_1(), "rule__Nom__NomAssignment_1");
} }
} }

View file

@ -1,59 +1,52 @@
'!='=16 '!'=52
'"Chemins"'=35 '"Chemins"'=29
'"Connaissances"'=27 '"Connaissances"'=21
'"Explorateur"'=20 '"Explorateur"'=14
'"Lieux"'=34 '"Lieux"'=28
'"Objets"'=24 '"Objets"'=18
'"Personnes"'=28 '"Personnes"'=22
'"Territoire"'=23 '"Territoire"'=17
'"Transformations"'=29 '"Transformations"'=23
'"actions"'=53 '"actions"'=47
'"condition"'=49 '"condition"'=43
'"connaissances"'=32 '"connaissances"'=26
'"depart"'=38 '"depart"'=32
'"deposable"'=37 '"deposable"'=31
'"descriptions"'=41 '"descriptions"'=35
'"fin"'=39 '"fin"'=33
'"fin_interaction"'=54 '"fin_interaction"'=48
'"interactions"'=52 '"interactions"'=46
'"lieu_in"'=42 '"lieu_in"'=36
'"lieu_out"'=43 '"lieu_out"'=37
'"nom"'=36 '"nom"'=30
'"objets"'=33 '"objets"'=27
'"objets_conso"'=48 '"objets_conso"'=42
'"objets_in"'=50 '"objets_in"'=44
'"objets_out"'=51 '"objets_out"'=45
'"objets_recus"'=47 '"objets_recus"'=41
'"obligatoire"'=46 '"obligatoire"'=40
'"ouvert"'=44 '"ouvert"'=38
'"personnes"'=40 '"personnes"'=34
'"taille"'=31 '"taille"'=25
'"texte"'=55 '"texte"'=49
'"visible"'=45 '"visible"'=39
'&&'=57 '&&'=51
','=22 ','=16
':'=21 ':'=15
'<'=11 '['=19
'<='=14 ']'=20
'=='=13 '{'=13
'>'=12 '||'=50
'>='=15 '}'=24
'['=25 RULE_ANY_OTHER=12
']'=26 RULE_BOOLEAN=6
'false'=18 RULE_COMPARATEUR=8
'true'=17 RULE_ID=7
'{'=19
'||'=56
'}'=30
RULE_ANY_OTHER=10
RULE_ID=6
RULE_INT=4 RULE_INT=4
RULE_ML_COMMENT=7 RULE_ML_COMMENT=9
RULE_SL_COMMENT=8 RULE_SL_COMMENT=10
RULE_STRING=5 RULE_STRING=5
RULE_WS=9 RULE_WS=11
T__11=11
T__12=12
T__13=13 T__13=13
T__14=14 T__14=14
T__15=15 T__15=15
@ -94,8 +87,3 @@ T__49=49
T__50=50 T__50=50
T__51=51 T__51=51
T__52=52 T__52=52
T__53=53
T__54=54
T__55=55
T__56=56
T__57=57

View file

@ -74,6 +74,9 @@ public abstract class AbstractGameProposalProvider extends TerminalsProposalProv
public void completeLieu_Connaissances(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { public void completeLieu_Connaissances(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor); completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor);
} }
public void completeChemin_Nom(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor);
}
public void completeChemin_LieuIn(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { public void completeChemin_LieuIn(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor); completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor);
} }
@ -191,6 +194,9 @@ public abstract class AbstractGameProposalProvider extends TerminalsProposalProv
public void completeConditionBoolean_Valeur(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { public void completeConditionBoolean_Valeur(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor); completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor);
} }
public void completeConditionConnaissance_Negation(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
// subclasses may override
}
public void completeConditionConnaissance_Connaissance(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { public void completeConditionConnaissance_Connaissance(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor); completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor);
} }
@ -261,10 +267,10 @@ public abstract class AbstractGameProposalProvider extends TerminalsProposalProv
public void complete_ConditionObjet(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { public void complete_ConditionObjet(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
// subclasses may override // subclasses may override
} }
public void complete_Comparateur(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { public void complete_COMPARATEUR(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
// subclasses may override // subclasses may override
} }
public void complete_Boolean(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { public void complete_BOOLEAN(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {
// subclasses may override // subclasses may override
} }
public void complete_Nom(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { public void complete_Nom(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) {

View file

@ -46,6 +46,7 @@
eType="#//Nom" containment="true"/> eType="#//Nom" containment="true"/>
</eClassifiers> </eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="Chemin"> <eClassifiers xsi:type="ecore:EClass" name="Chemin">
<eStructuralFeatures xsi:type="ecore:EReference" name="nom" eType="#//Nom" containment="true"/>
<eStructuralFeatures xsi:type="ecore:EReference" name="lieuIn" eType="#//Nom" <eStructuralFeatures xsi:type="ecore:EReference" name="lieuIn" eType="#//Nom"
containment="true"/> containment="true"/>
<eStructuralFeatures xsi:type="ecore:EReference" name="lieuOut" eType="#//Nom" <eStructuralFeatures xsi:type="ecore:EReference" name="lieuOut" eType="#//Nom"
@ -141,11 +142,11 @@
<eStructuralFeatures xsi:type="ecore:EAttribute" name="valeur" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> <eStructuralFeatures xsi:type="ecore:EAttribute" name="valeur" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
</eClassifiers> </eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="ConditionConnaissance" eSuperTypes="#//ConditionTest"> <eClassifiers xsi:type="ecore:EClass" name="ConditionConnaissance" eSuperTypes="#//ConditionTest">
<eStructuralFeatures xsi:type="ecore:EReference" name="connaissance" eType="#//Nom" <eStructuralFeatures xsi:type="ecore:EAttribute" name="negation" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
containment="true"/> <eStructuralFeatures xsi:type="ecore:EAttribute" name="connaissance" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
</eClassifiers> </eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="ConditionObjet" eSuperTypes="#//ConditionTest"> <eClassifiers xsi:type="ecore:EClass" name="ConditionObjet" eSuperTypes="#//ConditionTest">
<eStructuralFeatures xsi:type="ecore:EReference" name="objet" eType="#//Nom" containment="true"/> <eStructuralFeatures xsi:type="ecore:EAttribute" name="objet" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
<eStructuralFeatures xsi:type="ecore:EAttribute" name="comparateur" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> <eStructuralFeatures xsi:type="ecore:EAttribute" name="comparateur" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
<eStructuralFeatures xsi:type="ecore:EAttribute" name="nombre" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EInt"/> <eStructuralFeatures xsi:type="ecore:EAttribute" name="nombre" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EInt"/>
</eClassifiers> </eClassifiers>

View file

@ -34,6 +34,7 @@
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Lieu/connaissances"/> <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Lieu/connaissances"/>
</genClasses> </genClasses>
<genClasses ecoreClass="Game.ecore#//Chemin"> <genClasses ecoreClass="Game.ecore#//Chemin">
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Chemin/nom"/>
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Chemin/lieuIn"/> <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Chemin/lieuIn"/>
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Chemin/lieuOut"/> <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Chemin/lieuOut"/>
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Chemin/ouvert"/> <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//Chemin/ouvert"/>
@ -96,10 +97,11 @@
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionBoolean/valeur"/> <genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionBoolean/valeur"/>
</genClasses> </genClasses>
<genClasses ecoreClass="Game.ecore#//ConditionConnaissance"> <genClasses ecoreClass="Game.ecore#//ConditionConnaissance">
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//ConditionConnaissance/connaissance"/> <genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionConnaissance/negation"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionConnaissance/connaissance"/>
</genClasses> </genClasses>
<genClasses ecoreClass="Game.ecore#//ConditionObjet"> <genClasses ecoreClass="Game.ecore#//ConditionObjet">
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference Game.ecore#//ConditionObjet/objet"/> <genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionObjet/objet"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionObjet/comparateur"/> <genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionObjet/comparateur"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionObjet/nombre"/> <genFeatures createChild="false" ecoreFeature="ecore:EAttribute Game.ecore#//ConditionObjet/nombre"/>
</genClasses> </genClasses>

View file

@ -16,6 +16,7 @@ import org.eclipse.emf.ecore.EObject;
* The following features are supported: * The following features are supported:
* </p> * </p>
* <ul> * <ul>
* <li>{@link fr.n7.game.xtext.game.Chemin#getNom <em>Nom</em>}</li>
* <li>{@link fr.n7.game.xtext.game.Chemin#getLieuIn <em>Lieu In</em>}</li> * <li>{@link fr.n7.game.xtext.game.Chemin#getLieuIn <em>Lieu In</em>}</li>
* <li>{@link fr.n7.game.xtext.game.Chemin#getLieuOut <em>Lieu Out</em>}</li> * <li>{@link fr.n7.game.xtext.game.Chemin#getLieuOut <em>Lieu Out</em>}</li>
* <li>{@link fr.n7.game.xtext.game.Chemin#getOuvert <em>Ouvert</em>}</li> * <li>{@link fr.n7.game.xtext.game.Chemin#getOuvert <em>Ouvert</em>}</li>
@ -33,6 +34,28 @@ import org.eclipse.emf.ecore.EObject;
*/ */
public interface Chemin extends EObject public interface Chemin extends EObject
{ {
/**
* Returns the value of the '<em><b>Nom</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the value of the '<em>Nom</em>' containment reference.
* @see #setNom(Nom)
* @see fr.n7.game.xtext.game.GamePackage#getChemin_Nom()
* @model containment="true"
* @generated
*/
Nom getNom();
/**
* Sets the value of the '{@link fr.n7.game.xtext.game.Chemin#getNom <em>Nom</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param value the new value of the '<em>Nom</em>' containment reference.
* @see #getNom()
* @generated
*/
void setNom(Nom value);
/** /**
* Returns the value of the '<em><b>Lieu In</b></em>' containment reference. * Returns the value of the '<em><b>Lieu In</b></em>' containment reference.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->

View file

@ -13,6 +13,7 @@ package fr.n7.game.xtext.game;
* The following features are supported: * The following features are supported:
* </p> * </p>
* <ul> * <ul>
* <li>{@link fr.n7.game.xtext.game.ConditionConnaissance#getNegation <em>Negation</em>}</li>
* <li>{@link fr.n7.game.xtext.game.ConditionConnaissance#getConnaissance <em>Connaissance</em>}</li> * <li>{@link fr.n7.game.xtext.game.ConditionConnaissance#getConnaissance <em>Connaissance</em>}</li>
* </ul> * </ul>
* *
@ -23,25 +24,47 @@ package fr.n7.game.xtext.game;
public interface ConditionConnaissance extends ConditionTest public interface ConditionConnaissance extends ConditionTest
{ {
/** /**
* Returns the value of the '<em><b>Connaissance</b></em>' containment reference. * Returns the value of the '<em><b>Negation</b></em>' attribute.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @return the value of the '<em>Connaissance</em>' containment reference. * @return the value of the '<em>Negation</em>' attribute.
* @see #setConnaissance(Nom) * @see #setNegation(String)
* @see fr.n7.game.xtext.game.GamePackage#getConditionConnaissance_Connaissance() * @see fr.n7.game.xtext.game.GamePackage#getConditionConnaissance_Negation()
* @model containment="true" * @model
* @generated * @generated
*/ */
Nom getConnaissance(); String getNegation();
/** /**
* Sets the value of the '{@link fr.n7.game.xtext.game.ConditionConnaissance#getConnaissance <em>Connaissance</em>}' containment reference. * Sets the value of the '{@link fr.n7.game.xtext.game.ConditionConnaissance#getNegation <em>Negation</em>}' attribute.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @param value the new value of the '<em>Connaissance</em>' containment reference. * @param value the new value of the '<em>Negation</em>' attribute.
* @see #getNegation()
* @generated
*/
void setNegation(String value);
/**
* Returns the value of the '<em><b>Connaissance</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the value of the '<em>Connaissance</em>' attribute.
* @see #setConnaissance(String)
* @see fr.n7.game.xtext.game.GamePackage#getConditionConnaissance_Connaissance()
* @model
* @generated
*/
String getConnaissance();
/**
* Sets the value of the '{@link fr.n7.game.xtext.game.ConditionConnaissance#getConnaissance <em>Connaissance</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param value the new value of the '<em>Connaissance</em>' attribute.
* @see #getConnaissance() * @see #getConnaissance()
* @generated * @generated
*/ */
void setConnaissance(Nom value); void setConnaissance(String value);
} // ConditionConnaissance } // ConditionConnaissance

View file

@ -25,26 +25,26 @@ package fr.n7.game.xtext.game;
public interface ConditionObjet extends ConditionTest public interface ConditionObjet extends ConditionTest
{ {
/** /**
* Returns the value of the '<em><b>Objet</b></em>' containment reference. * Returns the value of the '<em><b>Objet</b></em>' attribute.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @return the value of the '<em>Objet</em>' containment reference. * @return the value of the '<em>Objet</em>' attribute.
* @see #setObjet(Nom) * @see #setObjet(String)
* @see fr.n7.game.xtext.game.GamePackage#getConditionObjet_Objet() * @see fr.n7.game.xtext.game.GamePackage#getConditionObjet_Objet()
* @model containment="true" * @model
* @generated * @generated
*/ */
Nom getObjet(); String getObjet();
/** /**
* Sets the value of the '{@link fr.n7.game.xtext.game.ConditionObjet#getObjet <em>Objet</em>}' containment reference. * Sets the value of the '{@link fr.n7.game.xtext.game.ConditionObjet#getObjet <em>Objet</em>}' attribute.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @param value the new value of the '<em>Objet</em>' containment reference. * @param value the new value of the '<em>Objet</em>' attribute.
* @see #getObjet() * @see #getObjet()
* @generated * @generated
*/ */
void setObjet(Nom value); void setObjet(String value);
/** /**
* Returns the value of the '<em><b>Comparateur</b></em>' attribute. * Returns the value of the '<em><b>Comparateur</b></em>' attribute.

View file

@ -314,6 +314,15 @@ public interface GamePackage extends EPackage
*/ */
int CHEMIN = 4; int CHEMIN = 4;
/**
* The feature id for the '<em><b>Nom</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int CHEMIN__NOM = 0;
/** /**
* The feature id for the '<em><b>Lieu In</b></em>' containment reference. * The feature id for the '<em><b>Lieu In</b></em>' containment reference.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
@ -321,7 +330,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__LIEU_IN = 0; int CHEMIN__LIEU_IN = 1;
/** /**
* The feature id for the '<em><b>Lieu Out</b></em>' containment reference. * The feature id for the '<em><b>Lieu Out</b></em>' containment reference.
@ -330,7 +339,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__LIEU_OUT = 1; int CHEMIN__LIEU_OUT = 2;
/** /**
* The feature id for the '<em><b>Ouvert</b></em>' containment reference. * The feature id for the '<em><b>Ouvert</b></em>' containment reference.
@ -339,7 +348,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__OUVERT = 2; int CHEMIN__OUVERT = 3;
/** /**
* The feature id for the '<em><b>Visible</b></em>' containment reference. * The feature id for the '<em><b>Visible</b></em>' containment reference.
@ -348,7 +357,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__VISIBLE = 3; int CHEMIN__VISIBLE = 4;
/** /**
* The feature id for the '<em><b>Obligatoire</b></em>' containment reference. * The feature id for the '<em><b>Obligatoire</b></em>' containment reference.
@ -357,7 +366,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__OBLIGATOIRE = 4; int CHEMIN__OBLIGATOIRE = 5;
/** /**
* The feature id for the '<em><b>Connaissances</b></em>' containment reference list. * The feature id for the '<em><b>Connaissances</b></em>' containment reference list.
@ -366,7 +375,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__CONNAISSANCES = 5; int CHEMIN__CONNAISSANCES = 6;
/** /**
* The feature id for the '<em><b>Objets Recus</b></em>' containment reference list. * The feature id for the '<em><b>Objets Recus</b></em>' containment reference list.
@ -375,7 +384,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__OBJETS_RECUS = 6; int CHEMIN__OBJETS_RECUS = 7;
/** /**
* The feature id for the '<em><b>Objets Conso</b></em>' containment reference list. * The feature id for the '<em><b>Objets Conso</b></em>' containment reference list.
@ -384,7 +393,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__OBJETS_CONSO = 7; int CHEMIN__OBJETS_CONSO = 8;
/** /**
* The feature id for the '<em><b>Descriptions</b></em>' containment reference list. * The feature id for the '<em><b>Descriptions</b></em>' containment reference list.
@ -393,7 +402,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN__DESCRIPTIONS = 8; int CHEMIN__DESCRIPTIONS = 9;
/** /**
* The number of structural features of the '<em>Chemin</em>' class. * The number of structural features of the '<em>Chemin</em>' class.
@ -402,7 +411,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CHEMIN_FEATURE_COUNT = 9; int CHEMIN_FEATURE_COUNT = 10;
/** /**
* The meta object id for the '{@link fr.n7.game.xtext.game.impl.ObjetImpl <em>Objet</em>}' class. * The meta object id for the '{@link fr.n7.game.xtext.game.impl.ObjetImpl <em>Objet</em>}' class.
@ -894,13 +903,22 @@ public interface GamePackage extends EPackage
int CONDITION_CONNAISSANCE = 16; int CONDITION_CONNAISSANCE = 16;
/** /**
* The feature id for the '<em><b>Connaissance</b></em>' containment reference. * The feature id for the '<em><b>Negation</b></em>' attribute.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @generated * @generated
* @ordered * @ordered
*/ */
int CONDITION_CONNAISSANCE__CONNAISSANCE = CONDITION_TEST_FEATURE_COUNT + 0; int CONDITION_CONNAISSANCE__NEGATION = CONDITION_TEST_FEATURE_COUNT + 0;
/**
* The feature id for the '<em><b>Connaissance</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
* @ordered
*/
int CONDITION_CONNAISSANCE__CONNAISSANCE = CONDITION_TEST_FEATURE_COUNT + 1;
/** /**
* The number of structural features of the '<em>Condition Connaissance</em>' class. * The number of structural features of the '<em>Condition Connaissance</em>' class.
@ -909,7 +927,7 @@ public interface GamePackage extends EPackage
* @generated * @generated
* @ordered * @ordered
*/ */
int CONDITION_CONNAISSANCE_FEATURE_COUNT = CONDITION_TEST_FEATURE_COUNT + 1; int CONDITION_CONNAISSANCE_FEATURE_COUNT = CONDITION_TEST_FEATURE_COUNT + 2;
/** /**
* The meta object id for the '{@link fr.n7.game.xtext.game.impl.ConditionObjetImpl <em>Condition Objet</em>}' class. * The meta object id for the '{@link fr.n7.game.xtext.game.impl.ConditionObjetImpl <em>Condition Objet</em>}' class.
@ -922,7 +940,7 @@ public interface GamePackage extends EPackage
int CONDITION_OBJET = 17; int CONDITION_OBJET = 17;
/** /**
* The feature id for the '<em><b>Objet</b></em>' containment reference. * The feature id for the '<em><b>Objet</b></em>' attribute.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @generated * @generated
@ -1245,6 +1263,17 @@ public interface GamePackage extends EPackage
*/ */
EClass getChemin(); EClass getChemin();
/**
* Returns the meta object for the containment reference '{@link fr.n7.game.xtext.game.Chemin#getNom <em>Nom</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference '<em>Nom</em>'.
* @see fr.n7.game.xtext.game.Chemin#getNom()
* @see #getChemin()
* @generated
*/
EReference getChemin_Nom();
/** /**
* Returns the meta object for the containment reference '{@link fr.n7.game.xtext.game.Chemin#getLieuIn <em>Lieu In</em>}'. * Returns the meta object for the containment reference '{@link fr.n7.game.xtext.game.Chemin#getLieuIn <em>Lieu In</em>}'.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
@ -1795,15 +1824,26 @@ public interface GamePackage extends EPackage
EClass getConditionConnaissance(); EClass getConditionConnaissance();
/** /**
* Returns the meta object for the containment reference '{@link fr.n7.game.xtext.game.ConditionConnaissance#getConnaissance <em>Connaissance</em>}'. * Returns the meta object for the attribute '{@link fr.n7.game.xtext.game.ConditionConnaissance#getNegation <em>Negation</em>}'.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @return the meta object for the containment reference '<em>Connaissance</em>'. * @return the meta object for the attribute '<em>Negation</em>'.
* @see fr.n7.game.xtext.game.ConditionConnaissance#getNegation()
* @see #getConditionConnaissance()
* @generated
*/
EAttribute getConditionConnaissance_Negation();
/**
* Returns the meta object for the attribute '{@link fr.n7.game.xtext.game.ConditionConnaissance#getConnaissance <em>Connaissance</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Connaissance</em>'.
* @see fr.n7.game.xtext.game.ConditionConnaissance#getConnaissance() * @see fr.n7.game.xtext.game.ConditionConnaissance#getConnaissance()
* @see #getConditionConnaissance() * @see #getConditionConnaissance()
* @generated * @generated
*/ */
EReference getConditionConnaissance_Connaissance(); EAttribute getConditionConnaissance_Connaissance();
/** /**
* Returns the meta object for class '{@link fr.n7.game.xtext.game.ConditionObjet <em>Condition Objet</em>}'. * Returns the meta object for class '{@link fr.n7.game.xtext.game.ConditionObjet <em>Condition Objet</em>}'.
@ -1816,15 +1856,15 @@ public interface GamePackage extends EPackage
EClass getConditionObjet(); EClass getConditionObjet();
/** /**
* Returns the meta object for the containment reference '{@link fr.n7.game.xtext.game.ConditionObjet#getObjet <em>Objet</em>}'. * Returns the meta object for the attribute '{@link fr.n7.game.xtext.game.ConditionObjet#getObjet <em>Objet</em>}'.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @return the meta object for the containment reference '<em>Objet</em>'. * @return the meta object for the attribute '<em>Objet</em>'.
* @see fr.n7.game.xtext.game.ConditionObjet#getObjet() * @see fr.n7.game.xtext.game.ConditionObjet#getObjet()
* @see #getConditionObjet() * @see #getConditionObjet()
* @generated * @generated
*/ */
EReference getConditionObjet_Objet(); EAttribute getConditionObjet_Objet();
/** /**
* Returns the meta object for the attribute '{@link fr.n7.game.xtext.game.ConditionObjet#getComparateur <em>Comparateur</em>}'. * Returns the meta object for the attribute '{@link fr.n7.game.xtext.game.ConditionObjet#getComparateur <em>Comparateur</em>}'.
@ -2094,6 +2134,14 @@ public interface GamePackage extends EPackage
*/ */
EClass CHEMIN = eINSTANCE.getChemin(); EClass CHEMIN = eINSTANCE.getChemin();
/**
* The meta object literal for the '<em><b>Nom</b></em>' containment reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EReference CHEMIN__NOM = eINSTANCE.getChemin_Nom();
/** /**
* The meta object literal for the '<em><b>Lieu In</b></em>' containment reference feature. * The meta object literal for the '<em><b>Lieu In</b></em>' containment reference feature.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
@ -2527,12 +2575,20 @@ public interface GamePackage extends EPackage
EClass CONDITION_CONNAISSANCE = eINSTANCE.getConditionConnaissance(); EClass CONDITION_CONNAISSANCE = eINSTANCE.getConditionConnaissance();
/** /**
* The meta object literal for the '<em><b>Connaissance</b></em>' containment reference feature. * The meta object literal for the '<em><b>Negation</b></em>' attribute feature.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @generated * @generated
*/ */
EReference CONDITION_CONNAISSANCE__CONNAISSANCE = eINSTANCE.getConditionConnaissance_Connaissance(); EAttribute CONDITION_CONNAISSANCE__NEGATION = eINSTANCE.getConditionConnaissance_Negation();
/**
* The meta object literal for the '<em><b>Connaissance</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
EAttribute CONDITION_CONNAISSANCE__CONNAISSANCE = eINSTANCE.getConditionConnaissance_Connaissance();
/** /**
* The meta object literal for the '{@link fr.n7.game.xtext.game.impl.ConditionObjetImpl <em>Condition Objet</em>}' class. * The meta object literal for the '{@link fr.n7.game.xtext.game.impl.ConditionObjetImpl <em>Condition Objet</em>}' class.
@ -2545,12 +2601,12 @@ public interface GamePackage extends EPackage
EClass CONDITION_OBJET = eINSTANCE.getConditionObjet(); EClass CONDITION_OBJET = eINSTANCE.getConditionObjet();
/** /**
* The meta object literal for the '<em><b>Objet</b></em>' containment reference feature. * The meta object literal for the '<em><b>Objet</b></em>' attribute feature.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @generated * @generated
*/ */
EReference CONDITION_OBJET__OBJET = eINSTANCE.getConditionObjet_Objet(); EAttribute CONDITION_OBJET__OBJET = eINSTANCE.getConditionObjet_Objet();
/** /**
* The meta object literal for the '<em><b>Comparateur</b></em>' attribute feature. * The meta object literal for the '<em><b>Comparateur</b></em>' attribute feature.

View file

@ -33,6 +33,7 @@ import org.eclipse.emf.ecore.util.InternalEList;
* The following features are implemented: * The following features are implemented:
* </p> * </p>
* <ul> * <ul>
* <li>{@link fr.n7.game.xtext.game.impl.CheminImpl#getNom <em>Nom</em>}</li>
* <li>{@link fr.n7.game.xtext.game.impl.CheminImpl#getLieuIn <em>Lieu In</em>}</li> * <li>{@link fr.n7.game.xtext.game.impl.CheminImpl#getLieuIn <em>Lieu In</em>}</li>
* <li>{@link fr.n7.game.xtext.game.impl.CheminImpl#getLieuOut <em>Lieu Out</em>}</li> * <li>{@link fr.n7.game.xtext.game.impl.CheminImpl#getLieuOut <em>Lieu Out</em>}</li>
* <li>{@link fr.n7.game.xtext.game.impl.CheminImpl#getOuvert <em>Ouvert</em>}</li> * <li>{@link fr.n7.game.xtext.game.impl.CheminImpl#getOuvert <em>Ouvert</em>}</li>
@ -48,6 +49,16 @@ import org.eclipse.emf.ecore.util.InternalEList;
*/ */
public class CheminImpl extends MinimalEObjectImpl.Container implements Chemin public class CheminImpl extends MinimalEObjectImpl.Container implements Chemin
{ {
/**
* The cached value of the '{@link #getNom() <em>Nom</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getNom()
* @generated
* @ordered
*/
protected Nom nom;
/** /**
* The cached value of the '{@link #getLieuIn() <em>Lieu In</em>}' containment reference. * The cached value of the '{@link #getLieuIn() <em>Lieu In</em>}' containment reference.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
@ -159,6 +170,56 @@ public class CheminImpl extends MinimalEObjectImpl.Container implements Chemin
return GamePackage.Literals.CHEMIN; return GamePackage.Literals.CHEMIN;
} }
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public Nom getNom()
{
return nom;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public NotificationChain basicSetNom(Nom newNom, NotificationChain msgs)
{
Nom oldNom = nom;
nom = newNom;
if (eNotificationRequired())
{
ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, GamePackage.CHEMIN__NOM, oldNom, newNom);
if (msgs == null) msgs = notification; else msgs.add(notification);
}
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void setNom(Nom newNom)
{
if (newNom != nom)
{
NotificationChain msgs = null;
if (nom != null)
msgs = ((InternalEObject)nom).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - GamePackage.CHEMIN__NOM, null, msgs);
if (newNom != null)
msgs = ((InternalEObject)newNom).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - GamePackage.CHEMIN__NOM, null, msgs);
msgs = basicSetNom(newNom, msgs);
if (msgs != null) msgs.dispatch();
}
else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, GamePackage.CHEMIN__NOM, newNom, newNom));
}
/** /**
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
@ -479,6 +540,8 @@ public class CheminImpl extends MinimalEObjectImpl.Container implements Chemin
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CHEMIN__NOM:
return basicSetNom(null, msgs);
case GamePackage.CHEMIN__LIEU_IN: case GamePackage.CHEMIN__LIEU_IN:
return basicSetLieuIn(null, msgs); return basicSetLieuIn(null, msgs);
case GamePackage.CHEMIN__LIEU_OUT: case GamePackage.CHEMIN__LIEU_OUT:
@ -511,6 +574,8 @@ public class CheminImpl extends MinimalEObjectImpl.Container implements Chemin
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CHEMIN__NOM:
return getNom();
case GamePackage.CHEMIN__LIEU_IN: case GamePackage.CHEMIN__LIEU_IN:
return getLieuIn(); return getLieuIn();
case GamePackage.CHEMIN__LIEU_OUT: case GamePackage.CHEMIN__LIEU_OUT:
@ -544,6 +609,9 @@ public class CheminImpl extends MinimalEObjectImpl.Container implements Chemin
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CHEMIN__NOM:
setNom((Nom)newValue);
return;
case GamePackage.CHEMIN__LIEU_IN: case GamePackage.CHEMIN__LIEU_IN:
setLieuIn((Nom)newValue); setLieuIn((Nom)newValue);
return; return;
@ -589,6 +657,9 @@ public class CheminImpl extends MinimalEObjectImpl.Container implements Chemin
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CHEMIN__NOM:
setNom((Nom)null);
return;
case GamePackage.CHEMIN__LIEU_IN: case GamePackage.CHEMIN__LIEU_IN:
setLieuIn((Nom)null); setLieuIn((Nom)null);
return; return;
@ -630,6 +701,8 @@ public class CheminImpl extends MinimalEObjectImpl.Container implements Chemin
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CHEMIN__NOM:
return nom != null;
case GamePackage.CHEMIN__LIEU_IN: case GamePackage.CHEMIN__LIEU_IN:
return lieuIn != null; return lieuIn != null;
case GamePackage.CHEMIN__LIEU_OUT: case GamePackage.CHEMIN__LIEU_OUT:

View file

@ -5,13 +5,10 @@ package fr.n7.game.xtext.game.impl;
import fr.n7.game.xtext.game.ConditionConnaissance; import fr.n7.game.xtext.game.ConditionConnaissance;
import fr.n7.game.xtext.game.GamePackage; import fr.n7.game.xtext.game.GamePackage;
import fr.n7.game.xtext.game.Nom;
import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.InternalEObject;
import org.eclipse.emf.ecore.impl.ENotificationImpl; import org.eclipse.emf.ecore.impl.ENotificationImpl;
@ -23,6 +20,7 @@ import org.eclipse.emf.ecore.impl.ENotificationImpl;
* The following features are implemented: * The following features are implemented:
* </p> * </p>
* <ul> * <ul>
* <li>{@link fr.n7.game.xtext.game.impl.ConditionConnaissanceImpl#getNegation <em>Negation</em>}</li>
* <li>{@link fr.n7.game.xtext.game.impl.ConditionConnaissanceImpl#getConnaissance <em>Connaissance</em>}</li> * <li>{@link fr.n7.game.xtext.game.impl.ConditionConnaissanceImpl#getConnaissance <em>Connaissance</em>}</li>
* </ul> * </ul>
* *
@ -31,14 +29,44 @@ import org.eclipse.emf.ecore.impl.ENotificationImpl;
public class ConditionConnaissanceImpl extends ConditionTestImpl implements ConditionConnaissance public class ConditionConnaissanceImpl extends ConditionTestImpl implements ConditionConnaissance
{ {
/** /**
* The cached value of the '{@link #getConnaissance() <em>Connaissance</em>}' containment reference. * The default value of the '{@link #getNegation() <em>Negation</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getNegation()
* @generated
* @ordered
*/
protected static final String NEGATION_EDEFAULT = null;
/**
* The cached value of the '{@link #getNegation() <em>Negation</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getNegation()
* @generated
* @ordered
*/
protected String negation = NEGATION_EDEFAULT;
/**
* The default value of the '{@link #getConnaissance() <em>Connaissance</em>}' attribute.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @see #getConnaissance() * @see #getConnaissance()
* @generated * @generated
* @ordered * @ordered
*/ */
protected Nom connaissance; protected static final String CONNAISSANCE_EDEFAULT = null;
/**
* The cached value of the '{@link #getConnaissance() <em>Connaissance</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getConnaissance()
* @generated
* @ordered
*/
protected String connaissance = CONNAISSANCE_EDEFAULT;
/** /**
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
@ -67,7 +95,32 @@ public class ConditionConnaissanceImpl extends ConditionTestImpl implements Cond
* @generated * @generated
*/ */
@Override @Override
public Nom getConnaissance() public String getNegation()
{
return negation;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void setNegation(String newNegation)
{
String oldNegation = negation;
negation = newNegation;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_CONNAISSANCE__NEGATION, oldNegation, negation));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public String getConnaissance()
{ {
return connaissance; return connaissance;
} }
@ -77,54 +130,13 @@ public class ConditionConnaissanceImpl extends ConditionTestImpl implements Cond
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @generated * @generated
*/ */
public NotificationChain basicSetConnaissance(Nom newConnaissance, NotificationChain msgs) @Override
public void setConnaissance(String newConnaissance)
{ {
Nom oldConnaissance = connaissance; String oldConnaissance = connaissance;
connaissance = newConnaissance; connaissance = newConnaissance;
if (eNotificationRequired()) if (eNotificationRequired())
{ eNotify(new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE, oldConnaissance, connaissance));
ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE, oldConnaissance, newConnaissance);
if (msgs == null) msgs = notification; else msgs.add(notification);
}
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void setConnaissance(Nom newConnaissance)
{
if (newConnaissance != connaissance)
{
NotificationChain msgs = null;
if (connaissance != null)
msgs = ((InternalEObject)connaissance).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE, null, msgs);
if (newConnaissance != null)
msgs = ((InternalEObject)newConnaissance).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE, null, msgs);
msgs = basicSetConnaissance(newConnaissance, msgs);
if (msgs != null) msgs.dispatch();
}
else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE, newConnaissance, newConnaissance));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs)
{
switch (featureID)
{
case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE:
return basicSetConnaissance(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
} }
/** /**
@ -137,6 +149,8 @@ public class ConditionConnaissanceImpl extends ConditionTestImpl implements Cond
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CONDITION_CONNAISSANCE__NEGATION:
return getNegation();
case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE: case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE:
return getConnaissance(); return getConnaissance();
} }
@ -153,8 +167,11 @@ public class ConditionConnaissanceImpl extends ConditionTestImpl implements Cond
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CONDITION_CONNAISSANCE__NEGATION:
setNegation((String)newValue);
return;
case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE: case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE:
setConnaissance((Nom)newValue); setConnaissance((String)newValue);
return; return;
} }
super.eSet(featureID, newValue); super.eSet(featureID, newValue);
@ -170,8 +187,11 @@ public class ConditionConnaissanceImpl extends ConditionTestImpl implements Cond
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CONDITION_CONNAISSANCE__NEGATION:
setNegation(NEGATION_EDEFAULT);
return;
case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE: case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE:
setConnaissance((Nom)null); setConnaissance(CONNAISSANCE_EDEFAULT);
return; return;
} }
super.eUnset(featureID); super.eUnset(featureID);
@ -187,10 +207,31 @@ public class ConditionConnaissanceImpl extends ConditionTestImpl implements Cond
{ {
switch (featureID) switch (featureID)
{ {
case GamePackage.CONDITION_CONNAISSANCE__NEGATION:
return NEGATION_EDEFAULT == null ? negation != null : !NEGATION_EDEFAULT.equals(negation);
case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE: case GamePackage.CONDITION_CONNAISSANCE__CONNAISSANCE:
return connaissance != null; return CONNAISSANCE_EDEFAULT == null ? connaissance != null : !CONNAISSANCE_EDEFAULT.equals(connaissance);
} }
return super.eIsSet(featureID); return super.eIsSet(featureID);
} }
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public String toString()
{
if (eIsProxy()) return super.toString();
StringBuilder result = new StringBuilder(super.toString());
result.append(" (negation: ");
result.append(negation);
result.append(", connaissance: ");
result.append(connaissance);
result.append(')');
return result.toString();
}
} //ConditionConnaissanceImpl } //ConditionConnaissanceImpl

View file

@ -5,13 +5,10 @@ package fr.n7.game.xtext.game.impl;
import fr.n7.game.xtext.game.ConditionObjet; import fr.n7.game.xtext.game.ConditionObjet;
import fr.n7.game.xtext.game.GamePackage; import fr.n7.game.xtext.game.GamePackage;
import fr.n7.game.xtext.game.Nom;
import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.InternalEObject;
import org.eclipse.emf.ecore.impl.ENotificationImpl; import org.eclipse.emf.ecore.impl.ENotificationImpl;
@ -33,14 +30,24 @@ import org.eclipse.emf.ecore.impl.ENotificationImpl;
public class ConditionObjetImpl extends ConditionTestImpl implements ConditionObjet public class ConditionObjetImpl extends ConditionTestImpl implements ConditionObjet
{ {
/** /**
* The cached value of the '{@link #getObjet() <em>Objet</em>}' containment reference. * The default value of the '{@link #getObjet() <em>Objet</em>}' attribute.
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @see #getObjet() * @see #getObjet()
* @generated * @generated
* @ordered * @ordered
*/ */
protected Nom objet; protected static final String OBJET_EDEFAULT = null;
/**
* The cached value of the '{@link #getObjet() <em>Objet</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getObjet()
* @generated
* @ordered
*/
protected String objet = OBJET_EDEFAULT;
/** /**
* The default value of the '{@link #getComparateur() <em>Comparateur</em>}' attribute. * The default value of the '{@link #getComparateur() <em>Comparateur</em>}' attribute.
@ -109,7 +116,7 @@ public class ConditionObjetImpl extends ConditionTestImpl implements ConditionOb
* @generated * @generated
*/ */
@Override @Override
public Nom getObjet() public String getObjet()
{ {
return objet; return objet;
} }
@ -119,38 +126,13 @@ public class ConditionObjetImpl extends ConditionTestImpl implements ConditionOb
* <!-- end-user-doc --> * <!-- end-user-doc -->
* @generated * @generated
*/ */
public NotificationChain basicSetObjet(Nom newObjet, NotificationChain msgs) @Override
public void setObjet(String newObjet)
{ {
Nom oldObjet = objet; String oldObjet = objet;
objet = newObjet; objet = newObjet;
if (eNotificationRequired()) if (eNotificationRequired())
{ eNotify(new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_OBJET__OBJET, oldObjet, objet));
ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_OBJET__OBJET, oldObjet, newObjet);
if (msgs == null) msgs = notification; else msgs.add(notification);
}
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void setObjet(Nom newObjet)
{
if (newObjet != objet)
{
NotificationChain msgs = null;
if (objet != null)
msgs = ((InternalEObject)objet).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - GamePackage.CONDITION_OBJET__OBJET, null, msgs);
if (newObjet != null)
msgs = ((InternalEObject)newObjet).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - GamePackage.CONDITION_OBJET__OBJET, null, msgs);
msgs = basicSetObjet(newObjet, msgs);
if (msgs != null) msgs.dispatch();
}
else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_OBJET__OBJET, newObjet, newObjet));
} }
/** /**
@ -203,22 +185,6 @@ public class ConditionObjetImpl extends ConditionTestImpl implements ConditionOb
eNotify(new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_OBJET__NOMBRE, oldNombre, nombre)); eNotify(new ENotificationImpl(this, Notification.SET, GamePackage.CONDITION_OBJET__NOMBRE, oldNombre, nombre));
} }
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs)
{
switch (featureID)
{
case GamePackage.CONDITION_OBJET__OBJET:
return basicSetObjet(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
/** /**
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
@ -250,7 +216,7 @@ public class ConditionObjetImpl extends ConditionTestImpl implements ConditionOb
switch (featureID) switch (featureID)
{ {
case GamePackage.CONDITION_OBJET__OBJET: case GamePackage.CONDITION_OBJET__OBJET:
setObjet((Nom)newValue); setObjet((String)newValue);
return; return;
case GamePackage.CONDITION_OBJET__COMPARATEUR: case GamePackage.CONDITION_OBJET__COMPARATEUR:
setComparateur((String)newValue); setComparateur((String)newValue);
@ -273,7 +239,7 @@ public class ConditionObjetImpl extends ConditionTestImpl implements ConditionOb
switch (featureID) switch (featureID)
{ {
case GamePackage.CONDITION_OBJET__OBJET: case GamePackage.CONDITION_OBJET__OBJET:
setObjet((Nom)null); setObjet(OBJET_EDEFAULT);
return; return;
case GamePackage.CONDITION_OBJET__COMPARATEUR: case GamePackage.CONDITION_OBJET__COMPARATEUR:
setComparateur(COMPARATEUR_EDEFAULT); setComparateur(COMPARATEUR_EDEFAULT);
@ -296,7 +262,7 @@ public class ConditionObjetImpl extends ConditionTestImpl implements ConditionOb
switch (featureID) switch (featureID)
{ {
case GamePackage.CONDITION_OBJET__OBJET: case GamePackage.CONDITION_OBJET__OBJET:
return objet != null; return OBJET_EDEFAULT == null ? objet != null : !OBJET_EDEFAULT.equals(objet);
case GamePackage.CONDITION_OBJET__COMPARATEUR: case GamePackage.CONDITION_OBJET__COMPARATEUR:
return COMPARATEUR_EDEFAULT == null ? comparateur != null : !COMPARATEUR_EDEFAULT.equals(comparateur); return COMPARATEUR_EDEFAULT == null ? comparateur != null : !COMPARATEUR_EDEFAULT.equals(comparateur);
case GamePackage.CONDITION_OBJET__NOMBRE: case GamePackage.CONDITION_OBJET__NOMBRE:
@ -316,7 +282,9 @@ public class ConditionObjetImpl extends ConditionTestImpl implements ConditionOb
if (eIsProxy()) return super.toString(); if (eIsProxy()) return super.toString();
StringBuilder result = new StringBuilder(super.toString()); StringBuilder result = new StringBuilder(super.toString());
result.append(" (comparateur: "); result.append(" (objet: ");
result.append(objet);
result.append(", comparateur: ");
result.append(comparateur); result.append(comparateur);
result.append(", nombre: "); result.append(", nombre: ");
result.append(nombre); result.append(nombre);

View file

@ -506,7 +506,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_LieuIn() public EReference getChemin_Nom()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(0); return (EReference)cheminEClass.getEStructuralFeatures().get(0);
} }
@ -517,7 +517,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_LieuOut() public EReference getChemin_LieuIn()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(1); return (EReference)cheminEClass.getEStructuralFeatures().get(1);
} }
@ -528,7 +528,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_Ouvert() public EReference getChemin_LieuOut()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(2); return (EReference)cheminEClass.getEStructuralFeatures().get(2);
} }
@ -539,7 +539,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_Visible() public EReference getChemin_Ouvert()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(3); return (EReference)cheminEClass.getEStructuralFeatures().get(3);
} }
@ -550,7 +550,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_Obligatoire() public EReference getChemin_Visible()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(4); return (EReference)cheminEClass.getEStructuralFeatures().get(4);
} }
@ -561,7 +561,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_Connaissances() public EReference getChemin_Obligatoire()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(5); return (EReference)cheminEClass.getEStructuralFeatures().get(5);
} }
@ -572,7 +572,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_ObjetsRecus() public EReference getChemin_Connaissances()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(6); return (EReference)cheminEClass.getEStructuralFeatures().get(6);
} }
@ -583,7 +583,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_ObjetsConso() public EReference getChemin_ObjetsRecus()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(7); return (EReference)cheminEClass.getEStructuralFeatures().get(7);
} }
@ -594,11 +594,22 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getChemin_Descriptions() public EReference getChemin_ObjetsConso()
{ {
return (EReference)cheminEClass.getEStructuralFeatures().get(8); return (EReference)cheminEClass.getEStructuralFeatures().get(8);
} }
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public EReference getChemin_Descriptions()
{
return (EReference)cheminEClass.getEStructuralFeatures().get(9);
}
/** /**
* <!-- begin-user-doc --> * <!-- begin-user-doc -->
* <!-- end-user-doc --> * <!-- end-user-doc -->
@ -1067,9 +1078,20 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getConditionConnaissance_Connaissance() public EAttribute getConditionConnaissance_Negation()
{ {
return (EReference)conditionConnaissanceEClass.getEStructuralFeatures().get(0); return (EAttribute)conditionConnaissanceEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public EAttribute getConditionConnaissance_Connaissance()
{
return (EAttribute)conditionConnaissanceEClass.getEStructuralFeatures().get(1);
} }
/** /**
@ -1089,9 +1111,9 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
* @generated * @generated
*/ */
@Override @Override
public EReference getConditionObjet_Objet() public EAttribute getConditionObjet_Objet()
{ {
return (EReference)conditionObjetEClass.getEStructuralFeatures().get(0); return (EAttribute)conditionObjetEClass.getEStructuralFeatures().get(0);
} }
/** /**
@ -1197,6 +1219,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
createEReference(lieuEClass, LIEU__CONNAISSANCES); createEReference(lieuEClass, LIEU__CONNAISSANCES);
cheminEClass = createEClass(CHEMIN); cheminEClass = createEClass(CHEMIN);
createEReference(cheminEClass, CHEMIN__NOM);
createEReference(cheminEClass, CHEMIN__LIEU_IN); createEReference(cheminEClass, CHEMIN__LIEU_IN);
createEReference(cheminEClass, CHEMIN__LIEU_OUT); createEReference(cheminEClass, CHEMIN__LIEU_OUT);
createEReference(cheminEClass, CHEMIN__OUVERT); createEReference(cheminEClass, CHEMIN__OUVERT);
@ -1260,10 +1283,11 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
createEAttribute(conditionBooleanEClass, CONDITION_BOOLEAN__VALEUR); createEAttribute(conditionBooleanEClass, CONDITION_BOOLEAN__VALEUR);
conditionConnaissanceEClass = createEClass(CONDITION_CONNAISSANCE); conditionConnaissanceEClass = createEClass(CONDITION_CONNAISSANCE);
createEReference(conditionConnaissanceEClass, CONDITION_CONNAISSANCE__CONNAISSANCE); createEAttribute(conditionConnaissanceEClass, CONDITION_CONNAISSANCE__NEGATION);
createEAttribute(conditionConnaissanceEClass, CONDITION_CONNAISSANCE__CONNAISSANCE);
conditionObjetEClass = createEClass(CONDITION_OBJET); conditionObjetEClass = createEClass(CONDITION_OBJET);
createEReference(conditionObjetEClass, CONDITION_OBJET__OBJET); createEAttribute(conditionObjetEClass, CONDITION_OBJET__OBJET);
createEAttribute(conditionObjetEClass, CONDITION_OBJET__COMPARATEUR); createEAttribute(conditionObjetEClass, CONDITION_OBJET__COMPARATEUR);
createEAttribute(conditionObjetEClass, CONDITION_OBJET__NOMBRE); createEAttribute(conditionObjetEClass, CONDITION_OBJET__NOMBRE);
@ -1333,6 +1357,7 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
initEReference(getLieu_Connaissances(), this.getNom(), null, "connaissances", null, 0, -1, Lieu.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getLieu_Connaissances(), this.getNom(), null, "connaissances", null, 0, -1, Lieu.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(cheminEClass, Chemin.class, "Chemin", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEClass(cheminEClass, Chemin.class, "Chemin", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getChemin_Nom(), this.getNom(), null, "nom", null, 0, 1, Chemin.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getChemin_LieuIn(), this.getNom(), null, "lieuIn", null, 0, 1, Chemin.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getChemin_LieuIn(), this.getNom(), null, "lieuIn", null, 0, 1, Chemin.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getChemin_LieuOut(), this.getNom(), null, "lieuOut", null, 0, 1, Chemin.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getChemin_LieuOut(), this.getNom(), null, "lieuOut", null, 0, 1, Chemin.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getChemin_Ouvert(), this.getCondition(), null, "ouvert", null, 0, 1, Chemin.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getChemin_Ouvert(), this.getCondition(), null, "ouvert", null, 0, 1, Chemin.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
@ -1396,10 +1421,11 @@ public class GamePackageImpl extends EPackageImpl implements GamePackage
initEAttribute(getConditionBoolean_Valeur(), ecorePackage.getEString(), "valeur", null, 0, 1, ConditionBoolean.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getConditionBoolean_Valeur(), ecorePackage.getEString(), "valeur", null, 0, 1, ConditionBoolean.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(conditionConnaissanceEClass, ConditionConnaissance.class, "ConditionConnaissance", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEClass(conditionConnaissanceEClass, ConditionConnaissance.class, "ConditionConnaissance", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getConditionConnaissance_Connaissance(), this.getNom(), null, "connaissance", null, 0, 1, ConditionConnaissance.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getConditionConnaissance_Negation(), ecorePackage.getEString(), "negation", null, 0, 1, ConditionConnaissance.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getConditionConnaissance_Connaissance(), ecorePackage.getEString(), "connaissance", null, 0, 1, ConditionConnaissance.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(conditionObjetEClass, ConditionObjet.class, "ConditionObjet", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEClass(conditionObjetEClass, ConditionObjet.class, "ConditionObjet", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getConditionObjet_Objet(), this.getNom(), null, "objet", null, 0, 1, ConditionObjet.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getConditionObjet_Objet(), ecorePackage.getEString(), "objet", null, 0, 1, ConditionObjet.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getConditionObjet_Comparateur(), ecorePackage.getEString(), "comparateur", null, 0, 1, ConditionObjet.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getConditionObjet_Comparateur(), ecorePackage.getEString(), "comparateur", null, 0, 1, ConditionObjet.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getConditionObjet_Nombre(), ecorePackage.getEInt(), "nombre", null, 0, 1, ConditionObjet.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getConditionObjet_Nombre(), ecorePackage.getEInt(), "nombre", null, 0, 1, ConditionObjet.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);

View file

@ -1185,9 +1185,9 @@ ruleChemin returns [EObject current=null]
{ {
newLeafNode(otherlv_0, grammarAccess.getCheminAccess().getLeftCurlyBracketKeyword_0()); newLeafNode(otherlv_0, grammarAccess.getCheminAccess().getLeftCurlyBracketKeyword_0());
} }
otherlv_1='"lieu_in"' otherlv_1='"nom"'
{ {
newLeafNode(otherlv_1, grammarAccess.getCheminAccess().getLieu_inKeyword_1()); newLeafNode(otherlv_1, grammarAccess.getCheminAccess().getNomKeyword_1());
} }
otherlv_2=':' otherlv_2=':'
{ {
@ -1196,17 +1196,17 @@ ruleChemin returns [EObject current=null]
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getLieuInNomParserRuleCall_3_0()); newCompositeNode(grammarAccess.getCheminAccess().getNomNomParserRuleCall_3_0());
} }
lv_lieuIn_3_0=ruleNom lv_nom_3_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
} }
set( set(
$current, $current,
"lieuIn", "nom",
lv_lieuIn_3_0, lv_nom_3_0,
"fr.n7.game.xtext.Game.Nom"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
@ -1216,9 +1216,9 @@ ruleChemin returns [EObject current=null]
{ {
newLeafNode(otherlv_4, grammarAccess.getCheminAccess().getCommaKeyword_4()); newLeafNode(otherlv_4, grammarAccess.getCheminAccess().getCommaKeyword_4());
} }
otherlv_5='"lieu_out"' otherlv_5='"lieu_in"'
{ {
newLeafNode(otherlv_5, grammarAccess.getCheminAccess().getLieu_outKeyword_5()); newLeafNode(otherlv_5, grammarAccess.getCheminAccess().getLieu_inKeyword_5());
} }
otherlv_6=':' otherlv_6=':'
{ {
@ -1227,17 +1227,17 @@ ruleChemin returns [EObject current=null]
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getLieuOutNomParserRuleCall_7_0()); newCompositeNode(grammarAccess.getCheminAccess().getLieuInNomParserRuleCall_7_0());
} }
lv_lieuOut_7_0=ruleNom lv_lieuIn_7_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
} }
set( set(
$current, $current,
"lieuOut", "lieuIn",
lv_lieuOut_7_0, lv_lieuIn_7_0,
"fr.n7.game.xtext.Game.Nom"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
@ -1247,9 +1247,9 @@ ruleChemin returns [EObject current=null]
{ {
newLeafNode(otherlv_8, grammarAccess.getCheminAccess().getCommaKeyword_8()); newLeafNode(otherlv_8, grammarAccess.getCheminAccess().getCommaKeyword_8());
} }
otherlv_9='"ouvert"' otherlv_9='"lieu_out"'
{ {
newLeafNode(otherlv_9, grammarAccess.getCheminAccess().getOuvertKeyword_9()); newLeafNode(otherlv_9, grammarAccess.getCheminAccess().getLieu_outKeyword_9());
} }
otherlv_10=':' otherlv_10=':'
{ {
@ -1258,18 +1258,18 @@ ruleChemin returns [EObject current=null]
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getOuvertConditionParserRuleCall_11_0()); newCompositeNode(grammarAccess.getCheminAccess().getLieuOutNomParserRuleCall_11_0());
} }
lv_ouvert_11_0=ruleCondition lv_lieuOut_11_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
} }
set( set(
$current, $current,
"ouvert", "lieuOut",
lv_ouvert_11_0, lv_lieuOut_11_0,
"fr.n7.game.xtext.Game.Condition"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
) )
@ -1278,9 +1278,9 @@ ruleChemin returns [EObject current=null]
{ {
newLeafNode(otherlv_12, grammarAccess.getCheminAccess().getCommaKeyword_12()); newLeafNode(otherlv_12, grammarAccess.getCheminAccess().getCommaKeyword_12());
} }
otherlv_13='"visible"' otherlv_13='"ouvert"'
{ {
newLeafNode(otherlv_13, grammarAccess.getCheminAccess().getVisibleKeyword_13()); newLeafNode(otherlv_13, grammarAccess.getCheminAccess().getOuvertKeyword_13());
} }
otherlv_14=':' otherlv_14=':'
{ {
@ -1289,17 +1289,17 @@ ruleChemin returns [EObject current=null]
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getVisibleConditionParserRuleCall_15_0()); newCompositeNode(grammarAccess.getCheminAccess().getOuvertConditionParserRuleCall_15_0());
} }
lv_visible_15_0=ruleCondition lv_ouvert_15_0=ruleCondition
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
} }
set( set(
$current, $current,
"visible", "ouvert",
lv_visible_15_0, lv_ouvert_15_0,
"fr.n7.game.xtext.Game.Condition"); "fr.n7.game.xtext.Game.Condition");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
@ -1309,9 +1309,9 @@ ruleChemin returns [EObject current=null]
{ {
newLeafNode(otherlv_16, grammarAccess.getCheminAccess().getCommaKeyword_16()); newLeafNode(otherlv_16, grammarAccess.getCheminAccess().getCommaKeyword_16());
} }
otherlv_17='"obligatoire"' otherlv_17='"visible"'
{ {
newLeafNode(otherlv_17, grammarAccess.getCheminAccess().getObligatoireKeyword_17()); newLeafNode(otherlv_17, grammarAccess.getCheminAccess().getVisibleKeyword_17());
} }
otherlv_18=':' otherlv_18=':'
{ {
@ -1320,17 +1320,17 @@ ruleChemin returns [EObject current=null]
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getObligatoireConditionParserRuleCall_19_0()); newCompositeNode(grammarAccess.getCheminAccess().getVisibleConditionParserRuleCall_19_0());
} }
lv_obligatoire_19_0=ruleCondition lv_visible_19_0=ruleCondition
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
} }
set( set(
$current, $current,
"obligatoire", "visible",
lv_obligatoire_19_0, lv_visible_19_0,
"fr.n7.game.xtext.Game.Condition"); "fr.n7.game.xtext.Game.Condition");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
@ -1340,25 +1340,56 @@ ruleChemin returns [EObject current=null]
{ {
newLeafNode(otherlv_20, grammarAccess.getCheminAccess().getCommaKeyword_20()); newLeafNode(otherlv_20, grammarAccess.getCheminAccess().getCommaKeyword_20());
} }
otherlv_21='"connaissances"' otherlv_21='"obligatoire"'
{ {
newLeafNode(otherlv_21, grammarAccess.getCheminAccess().getConnaissancesKeyword_21()); newLeafNode(otherlv_21, grammarAccess.getCheminAccess().getObligatoireKeyword_21());
} }
otherlv_22=':' otherlv_22=':'
{ {
newLeafNode(otherlv_22, grammarAccess.getCheminAccess().getColonKeyword_22()); newLeafNode(otherlv_22, grammarAccess.getCheminAccess().getColonKeyword_22());
} }
otherlv_23='[' (
(
{ {
newLeafNode(otherlv_23, grammarAccess.getCheminAccess().getLeftSquareBracketKeyword_23()); newCompositeNode(grammarAccess.getCheminAccess().getObligatoireConditionParserRuleCall_23_0());
}
lv_obligatoire_23_0=ruleCondition
{
if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule());
}
set(
$current,
"obligatoire",
lv_obligatoire_23_0,
"fr.n7.game.xtext.Game.Condition");
afterParserOrEnumRuleCall();
}
)
)
otherlv_24=','
{
newLeafNode(otherlv_24, grammarAccess.getCheminAccess().getCommaKeyword_24());
}
otherlv_25='"connaissances"'
{
newLeafNode(otherlv_25, grammarAccess.getCheminAccess().getConnaissancesKeyword_25());
}
otherlv_26=':'
{
newLeafNode(otherlv_26, grammarAccess.getCheminAccess().getColonKeyword_26());
}
otherlv_27='['
{
newLeafNode(otherlv_27, grammarAccess.getCheminAccess().getLeftSquareBracketKeyword_27());
} }
( (
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getConnaissancesNomParserRuleCall_24_0_0()); newCompositeNode(grammarAccess.getCheminAccess().getConnaissancesNomParserRuleCall_28_0_0());
} }
lv_connaissances_24_0=ruleNom lv_connaissances_28_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
@ -1366,23 +1397,23 @@ ruleChemin returns [EObject current=null]
add( add(
$current, $current,
"connaissances", "connaissances",
lv_connaissances_24_0, lv_connaissances_28_0,
"fr.n7.game.xtext.Game.Nom"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
) )
) )
( (
otherlv_25=',' otherlv_29=','
{ {
newLeafNode(otherlv_25, grammarAccess.getCheminAccess().getCommaKeyword_24_1_0()); newLeafNode(otherlv_29, grammarAccess.getCheminAccess().getCommaKeyword_28_1_0());
} }
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getConnaissancesNomParserRuleCall_24_1_1_0()); newCompositeNode(grammarAccess.getCheminAccess().getConnaissancesNomParserRuleCall_28_1_1_0());
} }
lv_connaissances_26_0=ruleNom lv_connaissances_30_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
@ -1390,7 +1421,7 @@ ruleChemin returns [EObject current=null]
add( add(
$current, $current,
"connaissances", "connaissances",
lv_connaissances_26_0, lv_connaissances_30_0,
"fr.n7.game.xtext.Game.Nom"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
@ -1398,33 +1429,33 @@ ruleChemin returns [EObject current=null]
) )
)* )*
)? )?
otherlv_27=']' otherlv_31=']'
{ {
newLeafNode(otherlv_27, grammarAccess.getCheminAccess().getRightSquareBracketKeyword_25()); newLeafNode(otherlv_31, grammarAccess.getCheminAccess().getRightSquareBracketKeyword_29());
} }
otherlv_28=',' otherlv_32=','
{ {
newLeafNode(otherlv_28, grammarAccess.getCheminAccess().getCommaKeyword_26()); newLeafNode(otherlv_32, grammarAccess.getCheminAccess().getCommaKeyword_30());
} }
otherlv_29='"objets_recus"' otherlv_33='"objets_recus"'
{ {
newLeafNode(otherlv_29, grammarAccess.getCheminAccess().getObjets_recusKeyword_27()); newLeafNode(otherlv_33, grammarAccess.getCheminAccess().getObjets_recusKeyword_31());
} }
otherlv_30=':' otherlv_34=':'
{ {
newLeafNode(otherlv_30, grammarAccess.getCheminAccess().getColonKeyword_28()); newLeafNode(otherlv_34, grammarAccess.getCheminAccess().getColonKeyword_32());
} }
otherlv_31='[' otherlv_35='['
{ {
newLeafNode(otherlv_31, grammarAccess.getCheminAccess().getLeftSquareBracketKeyword_29()); newLeafNode(otherlv_35, grammarAccess.getCheminAccess().getLeftSquareBracketKeyword_33());
} }
( (
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getObjetsRecusNomParserRuleCall_30_0_0()); newCompositeNode(grammarAccess.getCheminAccess().getObjetsRecusNomParserRuleCall_34_0_0());
} }
lv_objetsRecus_32_0=ruleNom lv_objetsRecus_36_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
@ -1432,23 +1463,23 @@ ruleChemin returns [EObject current=null]
add( add(
$current, $current,
"objetsRecus", "objetsRecus",
lv_objetsRecus_32_0, lv_objetsRecus_36_0,
"fr.n7.game.xtext.Game.Nom"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
) )
) )
( (
otherlv_33=',' otherlv_37=','
{ {
newLeafNode(otherlv_33, grammarAccess.getCheminAccess().getCommaKeyword_30_1_0()); newLeafNode(otherlv_37, grammarAccess.getCheminAccess().getCommaKeyword_34_1_0());
} }
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getObjetsRecusNomParserRuleCall_30_1_1_0()); newCompositeNode(grammarAccess.getCheminAccess().getObjetsRecusNomParserRuleCall_34_1_1_0());
} }
lv_objetsRecus_34_0=ruleNom lv_objetsRecus_38_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
@ -1456,7 +1487,7 @@ ruleChemin returns [EObject current=null]
add( add(
$current, $current,
"objetsRecus", "objetsRecus",
lv_objetsRecus_34_0, lv_objetsRecus_38_0,
"fr.n7.game.xtext.Game.Nom"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
@ -1464,33 +1495,33 @@ ruleChemin returns [EObject current=null]
) )
)* )*
)? )?
otherlv_35=']' otherlv_39=']'
{ {
newLeafNode(otherlv_35, grammarAccess.getCheminAccess().getRightSquareBracketKeyword_31()); newLeafNode(otherlv_39, grammarAccess.getCheminAccess().getRightSquareBracketKeyword_35());
} }
otherlv_36=',' otherlv_40=','
{ {
newLeafNode(otherlv_36, grammarAccess.getCheminAccess().getCommaKeyword_32()); newLeafNode(otherlv_40, grammarAccess.getCheminAccess().getCommaKeyword_36());
} }
otherlv_37='"objets_conso"' otherlv_41='"objets_conso"'
{ {
newLeafNode(otherlv_37, grammarAccess.getCheminAccess().getObjets_consoKeyword_33()); newLeafNode(otherlv_41, grammarAccess.getCheminAccess().getObjets_consoKeyword_37());
} }
otherlv_38=':' otherlv_42=':'
{ {
newLeafNode(otherlv_38, grammarAccess.getCheminAccess().getColonKeyword_34()); newLeafNode(otherlv_42, grammarAccess.getCheminAccess().getColonKeyword_38());
} }
otherlv_39='[' otherlv_43='['
{ {
newLeafNode(otherlv_39, grammarAccess.getCheminAccess().getLeftSquareBracketKeyword_35()); newLeafNode(otherlv_43, grammarAccess.getCheminAccess().getLeftSquareBracketKeyword_39());
} }
( (
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getObjetsConsoNomParserRuleCall_36_0_0()); newCompositeNode(grammarAccess.getCheminAccess().getObjetsConsoNomParserRuleCall_40_0_0());
} }
lv_objetsConso_40_0=ruleNom lv_objetsConso_44_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
@ -1498,23 +1529,23 @@ ruleChemin returns [EObject current=null]
add( add(
$current, $current,
"objetsConso", "objetsConso",
lv_objetsConso_40_0, lv_objetsConso_44_0,
"fr.n7.game.xtext.Game.Nom"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
) )
) )
( (
otherlv_41=',' otherlv_45=','
{ {
newLeafNode(otherlv_41, grammarAccess.getCheminAccess().getCommaKeyword_36_1_0()); newLeafNode(otherlv_45, grammarAccess.getCheminAccess().getCommaKeyword_40_1_0());
} }
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getObjetsConsoNomParserRuleCall_36_1_1_0()); newCompositeNode(grammarAccess.getCheminAccess().getObjetsConsoNomParserRuleCall_40_1_1_0());
} }
lv_objetsConso_42_0=ruleNom lv_objetsConso_46_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
@ -1522,7 +1553,7 @@ ruleChemin returns [EObject current=null]
add( add(
$current, $current,
"objetsConso", "objetsConso",
lv_objetsConso_42_0, lv_objetsConso_46_0,
"fr.n7.game.xtext.Game.Nom"); "fr.n7.game.xtext.Game.Nom");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
@ -1530,32 +1561,32 @@ ruleChemin returns [EObject current=null]
) )
)* )*
)? )?
otherlv_43=']' otherlv_47=']'
{ {
newLeafNode(otherlv_43, grammarAccess.getCheminAccess().getRightSquareBracketKeyword_37()); newLeafNode(otherlv_47, grammarAccess.getCheminAccess().getRightSquareBracketKeyword_41());
} }
otherlv_44=',' otherlv_48=','
{ {
newLeafNode(otherlv_44, grammarAccess.getCheminAccess().getCommaKeyword_38()); newLeafNode(otherlv_48, grammarAccess.getCheminAccess().getCommaKeyword_42());
} }
otherlv_45='"descriptions"' otherlv_49='"descriptions"'
{ {
newLeafNode(otherlv_45, grammarAccess.getCheminAccess().getDescriptionsKeyword_39()); newLeafNode(otherlv_49, grammarAccess.getCheminAccess().getDescriptionsKeyword_43());
} }
otherlv_46=':' otherlv_50=':'
{ {
newLeafNode(otherlv_46, grammarAccess.getCheminAccess().getColonKeyword_40()); newLeafNode(otherlv_50, grammarAccess.getCheminAccess().getColonKeyword_44());
} }
otherlv_47='[' otherlv_51='['
{ {
newLeafNode(otherlv_47, grammarAccess.getCheminAccess().getLeftSquareBracketKeyword_41()); newLeafNode(otherlv_51, grammarAccess.getCheminAccess().getLeftSquareBracketKeyword_45());
} }
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getDescriptionsDescriptionParserRuleCall_42_0()); newCompositeNode(grammarAccess.getCheminAccess().getDescriptionsDescriptionParserRuleCall_46_0());
} }
lv_descriptions_48_0=ruleDescription lv_descriptions_52_0=ruleDescription
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
@ -1563,23 +1594,23 @@ ruleChemin returns [EObject current=null]
add( add(
$current, $current,
"descriptions", "descriptions",
lv_descriptions_48_0, lv_descriptions_52_0,
"fr.n7.game.xtext.Game.Description"); "fr.n7.game.xtext.Game.Description");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
) )
) )
( (
otherlv_49=',' otherlv_53=','
{ {
newLeafNode(otherlv_49, grammarAccess.getCheminAccess().getCommaKeyword_43_0()); newLeafNode(otherlv_53, grammarAccess.getCheminAccess().getCommaKeyword_47_0());
} }
( (
( (
{ {
newCompositeNode(grammarAccess.getCheminAccess().getDescriptionsDescriptionParserRuleCall_43_1_0()); newCompositeNode(grammarAccess.getCheminAccess().getDescriptionsDescriptionParserRuleCall_47_1_0());
} }
lv_descriptions_50_0=ruleDescription lv_descriptions_54_0=ruleDescription
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getCheminRule()); $current = createModelElementForParent(grammarAccess.getCheminRule());
@ -1587,20 +1618,20 @@ ruleChemin returns [EObject current=null]
add( add(
$current, $current,
"descriptions", "descriptions",
lv_descriptions_50_0, lv_descriptions_54_0,
"fr.n7.game.xtext.Game.Description"); "fr.n7.game.xtext.Game.Description");
afterParserOrEnumRuleCall(); afterParserOrEnumRuleCall();
} }
) )
) )
)* )*
otherlv_51=']' otherlv_55=']'
{ {
newLeafNode(otherlv_51, grammarAccess.getCheminAccess().getRightSquareBracketKeyword_44()); newLeafNode(otherlv_55, grammarAccess.getCheminAccess().getRightSquareBracketKeyword_48());
} }
otherlv_52='}' otherlv_56='}'
{ {
newLeafNode(otherlv_52, grammarAccess.getCheminAccess().getRightCurlyBracketKeyword_45()); newLeafNode(otherlv_56, grammarAccess.getCheminAccess().getRightCurlyBracketKeyword_49());
} }
) )
; ;
@ -3240,20 +3271,19 @@ ruleConditionBoolean returns [EObject current=null]
}: }:
( (
( (
lv_valeur_0_0=RULE_BOOLEAN
{ {
newCompositeNode(grammarAccess.getConditionBooleanAccess().getValeurBooleanParserRuleCall_0()); newLeafNode(lv_valeur_0_0, grammarAccess.getConditionBooleanAccess().getValeurBOOLEANTerminalRuleCall_0());
} }
lv_valeur_0_0=ruleBoolean
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getConditionBooleanRule()); $current = createModelElement(grammarAccess.getConditionBooleanRule());
} }
set( setWithLastConsumed(
$current, $current,
"valeur", "valeur",
lv_valeur_0_0, lv_valeur_0_0,
"fr.n7.game.xtext.Game.Boolean"); "fr.n7.game.xtext.Game.BOOLEAN");
afterParserOrEnumRuleCall();
} }
) )
) )
@ -3276,23 +3306,38 @@ ruleConditionConnaissance returns [EObject current=null]
}: }:
( (
( (
(
lv_negation_0_0='!'
{ {
newCompositeNode(grammarAccess.getConditionConnaissanceAccess().getConnaissanceNomParserRuleCall_0()); newLeafNode(lv_negation_0_0, grammarAccess.getConditionConnaissanceAccess().getNegationExclamationMarkKeyword_0_0());
} }
lv_connaissance_0_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getConditionConnaissanceRule()); $current = createModelElement(grammarAccess.getConditionConnaissanceRule());
} }
set( setWithLastConsumed($current, "negation", lv_negation_0_0, "!");
}
)
)?
(
(
lv_connaissance_1_0=RULE_ID
{
newLeafNode(lv_connaissance_1_0, grammarAccess.getConditionConnaissanceAccess().getConnaissanceIDTerminalRuleCall_1_0());
}
{
if ($current==null) {
$current = createModelElement(grammarAccess.getConditionConnaissanceRule());
}
setWithLastConsumed(
$current, $current,
"connaissance", "connaissance",
lv_connaissance_0_0, lv_connaissance_1_0,
"fr.n7.game.xtext.Game.Nom"); "org.eclipse.xtext.common.Terminals.ID");
afterParserOrEnumRuleCall();
} }
) )
) )
)
; ;
// Entry rule entryRuleConditionObjet // Entry rule entryRuleConditionObjet
@ -3313,39 +3358,37 @@ ruleConditionObjet returns [EObject current=null]
( (
( (
( (
lv_objet_0_0=RULE_ID
{ {
newCompositeNode(grammarAccess.getConditionObjetAccess().getObjetNomParserRuleCall_0_0()); newLeafNode(lv_objet_0_0, grammarAccess.getConditionObjetAccess().getObjetIDTerminalRuleCall_0_0());
} }
lv_objet_0_0=ruleNom
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getConditionObjetRule()); $current = createModelElement(grammarAccess.getConditionObjetRule());
} }
set( setWithLastConsumed(
$current, $current,
"objet", "objet",
lv_objet_0_0, lv_objet_0_0,
"fr.n7.game.xtext.Game.Nom"); "org.eclipse.xtext.common.Terminals.ID");
afterParserOrEnumRuleCall();
} }
) )
) )
( (
( (
lv_comparateur_1_0=RULE_COMPARATEUR
{ {
newCompositeNode(grammarAccess.getConditionObjetAccess().getComparateurComparateurParserRuleCall_1_0()); newLeafNode(lv_comparateur_1_0, grammarAccess.getConditionObjetAccess().getComparateurCOMPARATEURTerminalRuleCall_1_0());
} }
lv_comparateur_1_0=ruleComparateur
{ {
if ($current==null) { if ($current==null) {
$current = createModelElementForParent(grammarAccess.getConditionObjetRule()); $current = createModelElement(grammarAccess.getConditionObjetRule());
} }
set( setWithLastConsumed(
$current, $current,
"comparateur", "comparateur",
lv_comparateur_1_0, lv_comparateur_1_0,
"fr.n7.game.xtext.Game.Comparateur"); "fr.n7.game.xtext.Game.COMPARATEUR");
afterParserOrEnumRuleCall();
} }
) )
) )
@ -3370,90 +3413,6 @@ ruleConditionObjet returns [EObject current=null]
) )
; ;
// Entry rule entryRuleComparateur
entryRuleComparateur returns [String current=null]:
{ newCompositeNode(grammarAccess.getComparateurRule()); }
iv_ruleComparateur=ruleComparateur
{ $current=$iv_ruleComparateur.current.getText(); }
EOF;
// Rule Comparateur
ruleComparateur returns [AntlrDatatypeRuleToken current=new AntlrDatatypeRuleToken()]
@init {
enterRule();
}
@after {
leaveRule();
}:
(
kw='<'
{
$current.merge(kw);
newLeafNode(kw, grammarAccess.getComparateurAccess().getLessThanSignKeyword_0());
}
|
kw='>'
{
$current.merge(kw);
newLeafNode(kw, grammarAccess.getComparateurAccess().getGreaterThanSignKeyword_1());
}
|
kw='=='
{
$current.merge(kw);
newLeafNode(kw, grammarAccess.getComparateurAccess().getEqualsSignEqualsSignKeyword_2());
}
|
kw='<='
{
$current.merge(kw);
newLeafNode(kw, grammarAccess.getComparateurAccess().getLessThanSignEqualsSignKeyword_3());
}
|
kw='>='
{
$current.merge(kw);
newLeafNode(kw, grammarAccess.getComparateurAccess().getGreaterThanSignEqualsSignKeyword_4());
}
|
kw='!='
{
$current.merge(kw);
newLeafNode(kw, grammarAccess.getComparateurAccess().getExclamationMarkEqualsSignKeyword_5());
}
)
;
// Entry rule entryRuleBoolean
entryRuleBoolean returns [String current=null]:
{ newCompositeNode(grammarAccess.getBooleanRule()); }
iv_ruleBoolean=ruleBoolean
{ $current=$iv_ruleBoolean.current.getText(); }
EOF;
// Rule Boolean
ruleBoolean returns [AntlrDatatypeRuleToken current=new AntlrDatatypeRuleToken()]
@init {
enterRule();
}
@after {
leaveRule();
}:
(
kw='true'
{
$current.merge(kw);
newLeafNode(kw, grammarAccess.getBooleanAccess().getTrueKeyword_0());
}
|
kw='false'
{
$current.merge(kw);
newLeafNode(kw, grammarAccess.getBooleanAccess().getFalseKeyword_1());
}
)
;
// Entry rule entryRuleNom // Entry rule entryRuleNom
entryRuleNom returns [EObject current=null]: entryRuleNom returns [EObject current=null]:
{ newCompositeNode(grammarAccess.getNomRule()); } { newCompositeNode(grammarAccess.getNomRule()); }
@ -3471,9 +3430,17 @@ ruleNom returns [EObject current=null]
}: }:
( (
( (
lv_nom_0_0=RULE_STRING
{ {
newLeafNode(lv_nom_0_0, grammarAccess.getNomAccess().getNomSTRINGTerminalRuleCall_0()); $current = forceCreateModelElement(
grammarAccess.getNomAccess().getNomAction_0(),
$current);
}
)
(
(
lv_nom_1_0=RULE_STRING
{
newLeafNode(lv_nom_1_0, grammarAccess.getNomAccess().getNomSTRINGTerminalRuleCall_1_0());
} }
{ {
if ($current==null) { if ($current==null) {
@ -3482,13 +3449,18 @@ ruleNom returns [EObject current=null]
setWithLastConsumed( setWithLastConsumed(
$current, $current,
"nom", "nom",
lv_nom_0_0, lv_nom_1_0,
"org.eclipse.xtext.common.Terminals.STRING"); "org.eclipse.xtext.common.Terminals.STRING");
} }
) )
) )
)
; ;
RULE_COMPARATEUR : ('<'|'>'|'=='|'<='|'>='|'!=');
RULE_BOOLEAN : ('true'|'false');
RULE_ID : '^'? ('a'..'z'|'A'..'Z'|'_') ('a'..'z'|'A'..'Z'|'_'|'0'..'9')*; RULE_ID : '^'? ('a'..'z'|'A'..'Z'|'_') ('a'..'z'|'A'..'Z'|'_'|'0'..'9')*;
RULE_INT : ('0'..'9')+; RULE_INT : ('0'..'9')+;

View file

@ -1,59 +1,52 @@
'!='=55 '!'=52
'"Chemins"'=27 '"Chemins"'=29
'"Connaissances"'=19 '"Connaissances"'=21
'"Explorateur"'=12 '"Explorateur"'=14
'"Lieux"'=26 '"Lieux"'=28
'"Objets"'=16 '"Objets"'=18
'"Personnes"'=20 '"Personnes"'=22
'"Territoire"'=15 '"Territoire"'=17
'"Transformations"'=21 '"Transformations"'=23
'"actions"'=45 '"actions"'=47
'"condition"'=41 '"condition"'=43
'"connaissances"'=24 '"connaissances"'=26
'"depart"'=30 '"depart"'=32
'"deposable"'=29 '"deposable"'=31
'"descriptions"'=33 '"descriptions"'=35
'"fin"'=31 '"fin"'=33
'"fin_interaction"'=46 '"fin_interaction"'=48
'"interactions"'=44 '"interactions"'=46
'"lieu_in"'=34 '"lieu_in"'=36
'"lieu_out"'=35 '"lieu_out"'=37
'"nom"'=28 '"nom"'=30
'"objets"'=25 '"objets"'=27
'"objets_conso"'=40 '"objets_conso"'=42
'"objets_in"'=42 '"objets_in"'=44
'"objets_out"'=43 '"objets_out"'=45
'"objets_recus"'=39 '"objets_recus"'=41
'"obligatoire"'=38 '"obligatoire"'=40
'"ouvert"'=36 '"ouvert"'=38
'"personnes"'=32 '"personnes"'=34
'"taille"'=23 '"taille"'=25
'"texte"'=47 '"texte"'=49
'"visible"'=37 '"visible"'=39
'&&'=49 '&&'=51
','=14 ','=16
':'=13 ':'=15
'<'=50 '['=19
'<='=53 ']'=20
'=='=52 '{'=13
'>'=51 '||'=50
'>='=54 '}'=24
'['=17 RULE_ANY_OTHER=12
']'=18 RULE_BOOLEAN=6
'false'=57 RULE_COMPARATEUR=8
'true'=56 RULE_ID=7
'{'=11
'||'=48
'}'=22
RULE_ANY_OTHER=10
RULE_ID=6
RULE_INT=4 RULE_INT=4
RULE_ML_COMMENT=7 RULE_ML_COMMENT=9
RULE_SL_COMMENT=8 RULE_SL_COMMENT=10
RULE_STRING=5 RULE_STRING=5
RULE_WS=9 RULE_WS=11
T__11=11
T__12=12
T__13=13 T__13=13
T__14=14 T__14=14
T__15=15 T__15=15
@ -94,8 +87,3 @@ T__49=49
T__50=50 T__50=50
T__51=51 T__51=51
T__52=52 T__52=52
T__53=53
T__54=54
T__55=55
T__56=56
T__57=57

View file

@ -133,6 +133,7 @@ public class GameSemanticSequencer extends AbstractDelegatingSemanticSequencer {
* *
* Constraint: * Constraint:
* ( * (
* nom=Nom
* lieuIn=Nom * lieuIn=Nom
* lieuOut=Nom * lieuOut=Nom
* ouvert=Condition * ouvert=Condition
@ -156,7 +157,7 @@ public class GameSemanticSequencer extends AbstractDelegatingSemanticSequencer {
* ConditionBoolean returns ConditionBoolean * ConditionBoolean returns ConditionBoolean
* *
* Constraint: * Constraint:
* valeur=Boolean * valeur=BOOLEAN
*/ */
protected void sequence_ConditionBoolean(ISerializationContext context, ConditionBoolean semanticObject) { protected void sequence_ConditionBoolean(ISerializationContext context, ConditionBoolean semanticObject) {
if (errorAcceptor != null) { if (errorAcceptor != null) {
@ -164,7 +165,7 @@ public class GameSemanticSequencer extends AbstractDelegatingSemanticSequencer {
errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, GamePackage.Literals.CONDITION_BOOLEAN__VALEUR)); errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, GamePackage.Literals.CONDITION_BOOLEAN__VALEUR));
} }
SequenceFeeder feeder = createSequencerFeeder(context, semanticObject); SequenceFeeder feeder = createSequencerFeeder(context, semanticObject);
feeder.accept(grammarAccess.getConditionBooleanAccess().getValeurBooleanParserRuleCall_0(), semanticObject.getValeur()); feeder.accept(grammarAccess.getConditionBooleanAccess().getValeurBOOLEANTerminalRuleCall_0(), semanticObject.getValeur());
feeder.finish(); feeder.finish();
} }
@ -175,16 +176,10 @@ public class GameSemanticSequencer extends AbstractDelegatingSemanticSequencer {
* ConditionConnaissance returns ConditionConnaissance * ConditionConnaissance returns ConditionConnaissance
* *
* Constraint: * Constraint:
* connaissance=Nom * (negation='!'? connaissance=ID)
*/ */
protected void sequence_ConditionConnaissance(ISerializationContext context, ConditionConnaissance semanticObject) { protected void sequence_ConditionConnaissance(ISerializationContext context, ConditionConnaissance semanticObject) {
if (errorAcceptor != null) { genericSequencer.createSequence(context, semanticObject);
if (transientValues.isValueTransient(semanticObject, GamePackage.Literals.CONDITION_CONNAISSANCE__CONNAISSANCE) == ValueTransient.YES)
errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, GamePackage.Literals.CONDITION_CONNAISSANCE__CONNAISSANCE));
}
SequenceFeeder feeder = createSequencerFeeder(context, semanticObject);
feeder.accept(grammarAccess.getConditionConnaissanceAccess().getConnaissanceNomParserRuleCall_0(), semanticObject.getConnaissance());
feeder.finish();
} }
@ -206,7 +201,7 @@ public class GameSemanticSequencer extends AbstractDelegatingSemanticSequencer {
* ConditionObjet returns ConditionObjet * ConditionObjet returns ConditionObjet
* *
* Constraint: * Constraint:
* (objet=Nom comparateur=Comparateur nombre=INT) * (objet=ID comparateur=COMPARATEUR nombre=INT)
*/ */
protected void sequence_ConditionObjet(ISerializationContext context, ConditionObjet semanticObject) { protected void sequence_ConditionObjet(ISerializationContext context, ConditionObjet semanticObject) {
if (errorAcceptor != null) { if (errorAcceptor != null) {
@ -218,8 +213,8 @@ public class GameSemanticSequencer extends AbstractDelegatingSemanticSequencer {
errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, GamePackage.Literals.CONDITION_OBJET__NOMBRE)); errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, GamePackage.Literals.CONDITION_OBJET__NOMBRE));
} }
SequenceFeeder feeder = createSequencerFeeder(context, semanticObject); SequenceFeeder feeder = createSequencerFeeder(context, semanticObject);
feeder.accept(grammarAccess.getConditionObjetAccess().getObjetNomParserRuleCall_0_0(), semanticObject.getObjet()); feeder.accept(grammarAccess.getConditionObjetAccess().getObjetIDTerminalRuleCall_0_0(), semanticObject.getObjet());
feeder.accept(grammarAccess.getConditionObjetAccess().getComparateurComparateurParserRuleCall_1_0(), semanticObject.getComparateur()); feeder.accept(grammarAccess.getConditionObjetAccess().getComparateurCOMPARATEURTerminalRuleCall_1_0(), semanticObject.getComparateur());
feeder.accept(grammarAccess.getConditionObjetAccess().getNombreINTTerminalRuleCall_2_0(), semanticObject.getNombre()); feeder.accept(grammarAccess.getConditionObjetAccess().getNombreINTTerminalRuleCall_2_0(), semanticObject.getNombre());
feeder.finish(); feeder.finish();
} }
@ -355,7 +350,7 @@ public class GameSemanticSequencer extends AbstractDelegatingSemanticSequencer {
errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, GamePackage.Literals.NOM__NOM)); errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, GamePackage.Literals.NOM__NOM));
} }
SequenceFeeder feeder = createSequencerFeeder(context, semanticObject); SequenceFeeder feeder = createSequencerFeeder(context, semanticObject);
feeder.accept(grammarAccess.getNomAccess().getNomSTRINGTerminalRuleCall_0(), semanticObject.getNom()); feeder.accept(grammarAccess.getNomAccess().getNomSTRINGTerminalRuleCall_1_0(), semanticObject.getNom());
feeder.finish(); feeder.finish();
} }

View file

@ -835,81 +835,87 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.Chemin"); private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.Chemin");
private final Group cGroup = (Group)rule.eContents().get(1); private final Group cGroup = (Group)rule.eContents().get(1);
private final Keyword cLeftCurlyBracketKeyword_0 = (Keyword)cGroup.eContents().get(0); private final Keyword cLeftCurlyBracketKeyword_0 = (Keyword)cGroup.eContents().get(0);
private final Keyword cLieu_inKeyword_1 = (Keyword)cGroup.eContents().get(1); private final Keyword cNomKeyword_1 = (Keyword)cGroup.eContents().get(1);
private final Keyword cColonKeyword_2 = (Keyword)cGroup.eContents().get(2); private final Keyword cColonKeyword_2 = (Keyword)cGroup.eContents().get(2);
private final Assignment cLieuInAssignment_3 = (Assignment)cGroup.eContents().get(3); private final Assignment cNomAssignment_3 = (Assignment)cGroup.eContents().get(3);
private final RuleCall cLieuInNomParserRuleCall_3_0 = (RuleCall)cLieuInAssignment_3.eContents().get(0); private final RuleCall cNomNomParserRuleCall_3_0 = (RuleCall)cNomAssignment_3.eContents().get(0);
private final Keyword cCommaKeyword_4 = (Keyword)cGroup.eContents().get(4); private final Keyword cCommaKeyword_4 = (Keyword)cGroup.eContents().get(4);
private final Keyword cLieu_outKeyword_5 = (Keyword)cGroup.eContents().get(5); private final Keyword cLieu_inKeyword_5 = (Keyword)cGroup.eContents().get(5);
private final Keyword cColonKeyword_6 = (Keyword)cGroup.eContents().get(6); private final Keyword cColonKeyword_6 = (Keyword)cGroup.eContents().get(6);
private final Assignment cLieuOutAssignment_7 = (Assignment)cGroup.eContents().get(7); private final Assignment cLieuInAssignment_7 = (Assignment)cGroup.eContents().get(7);
private final RuleCall cLieuOutNomParserRuleCall_7_0 = (RuleCall)cLieuOutAssignment_7.eContents().get(0); private final RuleCall cLieuInNomParserRuleCall_7_0 = (RuleCall)cLieuInAssignment_7.eContents().get(0);
private final Keyword cCommaKeyword_8 = (Keyword)cGroup.eContents().get(8); private final Keyword cCommaKeyword_8 = (Keyword)cGroup.eContents().get(8);
private final Keyword cOuvertKeyword_9 = (Keyword)cGroup.eContents().get(9); private final Keyword cLieu_outKeyword_9 = (Keyword)cGroup.eContents().get(9);
private final Keyword cColonKeyword_10 = (Keyword)cGroup.eContents().get(10); private final Keyword cColonKeyword_10 = (Keyword)cGroup.eContents().get(10);
private final Assignment cOuvertAssignment_11 = (Assignment)cGroup.eContents().get(11); private final Assignment cLieuOutAssignment_11 = (Assignment)cGroup.eContents().get(11);
private final RuleCall cOuvertConditionParserRuleCall_11_0 = (RuleCall)cOuvertAssignment_11.eContents().get(0); private final RuleCall cLieuOutNomParserRuleCall_11_0 = (RuleCall)cLieuOutAssignment_11.eContents().get(0);
private final Keyword cCommaKeyword_12 = (Keyword)cGroup.eContents().get(12); private final Keyword cCommaKeyword_12 = (Keyword)cGroup.eContents().get(12);
private final Keyword cVisibleKeyword_13 = (Keyword)cGroup.eContents().get(13); private final Keyword cOuvertKeyword_13 = (Keyword)cGroup.eContents().get(13);
private final Keyword cColonKeyword_14 = (Keyword)cGroup.eContents().get(14); private final Keyword cColonKeyword_14 = (Keyword)cGroup.eContents().get(14);
private final Assignment cVisibleAssignment_15 = (Assignment)cGroup.eContents().get(15); private final Assignment cOuvertAssignment_15 = (Assignment)cGroup.eContents().get(15);
private final RuleCall cVisibleConditionParserRuleCall_15_0 = (RuleCall)cVisibleAssignment_15.eContents().get(0); private final RuleCall cOuvertConditionParserRuleCall_15_0 = (RuleCall)cOuvertAssignment_15.eContents().get(0);
private final Keyword cCommaKeyword_16 = (Keyword)cGroup.eContents().get(16); private final Keyword cCommaKeyword_16 = (Keyword)cGroup.eContents().get(16);
private final Keyword cObligatoireKeyword_17 = (Keyword)cGroup.eContents().get(17); private final Keyword cVisibleKeyword_17 = (Keyword)cGroup.eContents().get(17);
private final Keyword cColonKeyword_18 = (Keyword)cGroup.eContents().get(18); private final Keyword cColonKeyword_18 = (Keyword)cGroup.eContents().get(18);
private final Assignment cObligatoireAssignment_19 = (Assignment)cGroup.eContents().get(19); private final Assignment cVisibleAssignment_19 = (Assignment)cGroup.eContents().get(19);
private final RuleCall cObligatoireConditionParserRuleCall_19_0 = (RuleCall)cObligatoireAssignment_19.eContents().get(0); private final RuleCall cVisibleConditionParserRuleCall_19_0 = (RuleCall)cVisibleAssignment_19.eContents().get(0);
private final Keyword cCommaKeyword_20 = (Keyword)cGroup.eContents().get(20); private final Keyword cCommaKeyword_20 = (Keyword)cGroup.eContents().get(20);
private final Keyword cConnaissancesKeyword_21 = (Keyword)cGroup.eContents().get(21); private final Keyword cObligatoireKeyword_21 = (Keyword)cGroup.eContents().get(21);
private final Keyword cColonKeyword_22 = (Keyword)cGroup.eContents().get(22); private final Keyword cColonKeyword_22 = (Keyword)cGroup.eContents().get(22);
private final Keyword cLeftSquareBracketKeyword_23 = (Keyword)cGroup.eContents().get(23); private final Assignment cObligatoireAssignment_23 = (Assignment)cGroup.eContents().get(23);
private final Group cGroup_24 = (Group)cGroup.eContents().get(24); private final RuleCall cObligatoireConditionParserRuleCall_23_0 = (RuleCall)cObligatoireAssignment_23.eContents().get(0);
private final Assignment cConnaissancesAssignment_24_0 = (Assignment)cGroup_24.eContents().get(0); private final Keyword cCommaKeyword_24 = (Keyword)cGroup.eContents().get(24);
private final RuleCall cConnaissancesNomParserRuleCall_24_0_0 = (RuleCall)cConnaissancesAssignment_24_0.eContents().get(0); private final Keyword cConnaissancesKeyword_25 = (Keyword)cGroup.eContents().get(25);
private final Group cGroup_24_1 = (Group)cGroup_24.eContents().get(1); private final Keyword cColonKeyword_26 = (Keyword)cGroup.eContents().get(26);
private final Keyword cCommaKeyword_24_1_0 = (Keyword)cGroup_24_1.eContents().get(0); private final Keyword cLeftSquareBracketKeyword_27 = (Keyword)cGroup.eContents().get(27);
private final Assignment cConnaissancesAssignment_24_1_1 = (Assignment)cGroup_24_1.eContents().get(1); private final Group cGroup_28 = (Group)cGroup.eContents().get(28);
private final RuleCall cConnaissancesNomParserRuleCall_24_1_1_0 = (RuleCall)cConnaissancesAssignment_24_1_1.eContents().get(0); private final Assignment cConnaissancesAssignment_28_0 = (Assignment)cGroup_28.eContents().get(0);
private final Keyword cRightSquareBracketKeyword_25 = (Keyword)cGroup.eContents().get(25); private final RuleCall cConnaissancesNomParserRuleCall_28_0_0 = (RuleCall)cConnaissancesAssignment_28_0.eContents().get(0);
private final Keyword cCommaKeyword_26 = (Keyword)cGroup.eContents().get(26); private final Group cGroup_28_1 = (Group)cGroup_28.eContents().get(1);
private final Keyword cObjets_recusKeyword_27 = (Keyword)cGroup.eContents().get(27); private final Keyword cCommaKeyword_28_1_0 = (Keyword)cGroup_28_1.eContents().get(0);
private final Keyword cColonKeyword_28 = (Keyword)cGroup.eContents().get(28); private final Assignment cConnaissancesAssignment_28_1_1 = (Assignment)cGroup_28_1.eContents().get(1);
private final Keyword cLeftSquareBracketKeyword_29 = (Keyword)cGroup.eContents().get(29); private final RuleCall cConnaissancesNomParserRuleCall_28_1_1_0 = (RuleCall)cConnaissancesAssignment_28_1_1.eContents().get(0);
private final Group cGroup_30 = (Group)cGroup.eContents().get(30); private final Keyword cRightSquareBracketKeyword_29 = (Keyword)cGroup.eContents().get(29);
private final Assignment cObjetsRecusAssignment_30_0 = (Assignment)cGroup_30.eContents().get(0); private final Keyword cCommaKeyword_30 = (Keyword)cGroup.eContents().get(30);
private final RuleCall cObjetsRecusNomParserRuleCall_30_0_0 = (RuleCall)cObjetsRecusAssignment_30_0.eContents().get(0); private final Keyword cObjets_recusKeyword_31 = (Keyword)cGroup.eContents().get(31);
private final Group cGroup_30_1 = (Group)cGroup_30.eContents().get(1); private final Keyword cColonKeyword_32 = (Keyword)cGroup.eContents().get(32);
private final Keyword cCommaKeyword_30_1_0 = (Keyword)cGroup_30_1.eContents().get(0); private final Keyword cLeftSquareBracketKeyword_33 = (Keyword)cGroup.eContents().get(33);
private final Assignment cObjetsRecusAssignment_30_1_1 = (Assignment)cGroup_30_1.eContents().get(1); private final Group cGroup_34 = (Group)cGroup.eContents().get(34);
private final RuleCall cObjetsRecusNomParserRuleCall_30_1_1_0 = (RuleCall)cObjetsRecusAssignment_30_1_1.eContents().get(0); private final Assignment cObjetsRecusAssignment_34_0 = (Assignment)cGroup_34.eContents().get(0);
private final Keyword cRightSquareBracketKeyword_31 = (Keyword)cGroup.eContents().get(31); private final RuleCall cObjetsRecusNomParserRuleCall_34_0_0 = (RuleCall)cObjetsRecusAssignment_34_0.eContents().get(0);
private final Keyword cCommaKeyword_32 = (Keyword)cGroup.eContents().get(32); private final Group cGroup_34_1 = (Group)cGroup_34.eContents().get(1);
private final Keyword cObjets_consoKeyword_33 = (Keyword)cGroup.eContents().get(33); private final Keyword cCommaKeyword_34_1_0 = (Keyword)cGroup_34_1.eContents().get(0);
private final Keyword cColonKeyword_34 = (Keyword)cGroup.eContents().get(34); private final Assignment cObjetsRecusAssignment_34_1_1 = (Assignment)cGroup_34_1.eContents().get(1);
private final Keyword cLeftSquareBracketKeyword_35 = (Keyword)cGroup.eContents().get(35); private final RuleCall cObjetsRecusNomParserRuleCall_34_1_1_0 = (RuleCall)cObjetsRecusAssignment_34_1_1.eContents().get(0);
private final Group cGroup_36 = (Group)cGroup.eContents().get(36); private final Keyword cRightSquareBracketKeyword_35 = (Keyword)cGroup.eContents().get(35);
private final Assignment cObjetsConsoAssignment_36_0 = (Assignment)cGroup_36.eContents().get(0); private final Keyword cCommaKeyword_36 = (Keyword)cGroup.eContents().get(36);
private final RuleCall cObjetsConsoNomParserRuleCall_36_0_0 = (RuleCall)cObjetsConsoAssignment_36_0.eContents().get(0); private final Keyword cObjets_consoKeyword_37 = (Keyword)cGroup.eContents().get(37);
private final Group cGroup_36_1 = (Group)cGroup_36.eContents().get(1); private final Keyword cColonKeyword_38 = (Keyword)cGroup.eContents().get(38);
private final Keyword cCommaKeyword_36_1_0 = (Keyword)cGroup_36_1.eContents().get(0); private final Keyword cLeftSquareBracketKeyword_39 = (Keyword)cGroup.eContents().get(39);
private final Assignment cObjetsConsoAssignment_36_1_1 = (Assignment)cGroup_36_1.eContents().get(1); private final Group cGroup_40 = (Group)cGroup.eContents().get(40);
private final RuleCall cObjetsConsoNomParserRuleCall_36_1_1_0 = (RuleCall)cObjetsConsoAssignment_36_1_1.eContents().get(0); private final Assignment cObjetsConsoAssignment_40_0 = (Assignment)cGroup_40.eContents().get(0);
private final Keyword cRightSquareBracketKeyword_37 = (Keyword)cGroup.eContents().get(37); private final RuleCall cObjetsConsoNomParserRuleCall_40_0_0 = (RuleCall)cObjetsConsoAssignment_40_0.eContents().get(0);
private final Keyword cCommaKeyword_38 = (Keyword)cGroup.eContents().get(38); private final Group cGroup_40_1 = (Group)cGroup_40.eContents().get(1);
private final Keyword cDescriptionsKeyword_39 = (Keyword)cGroup.eContents().get(39); private final Keyword cCommaKeyword_40_1_0 = (Keyword)cGroup_40_1.eContents().get(0);
private final Keyword cColonKeyword_40 = (Keyword)cGroup.eContents().get(40); private final Assignment cObjetsConsoAssignment_40_1_1 = (Assignment)cGroup_40_1.eContents().get(1);
private final Keyword cLeftSquareBracketKeyword_41 = (Keyword)cGroup.eContents().get(41); private final RuleCall cObjetsConsoNomParserRuleCall_40_1_1_0 = (RuleCall)cObjetsConsoAssignment_40_1_1.eContents().get(0);
private final Assignment cDescriptionsAssignment_42 = (Assignment)cGroup.eContents().get(42); private final Keyword cRightSquareBracketKeyword_41 = (Keyword)cGroup.eContents().get(41);
private final RuleCall cDescriptionsDescriptionParserRuleCall_42_0 = (RuleCall)cDescriptionsAssignment_42.eContents().get(0); private final Keyword cCommaKeyword_42 = (Keyword)cGroup.eContents().get(42);
private final Group cGroup_43 = (Group)cGroup.eContents().get(43); private final Keyword cDescriptionsKeyword_43 = (Keyword)cGroup.eContents().get(43);
private final Keyword cCommaKeyword_43_0 = (Keyword)cGroup_43.eContents().get(0); private final Keyword cColonKeyword_44 = (Keyword)cGroup.eContents().get(44);
private final Assignment cDescriptionsAssignment_43_1 = (Assignment)cGroup_43.eContents().get(1); private final Keyword cLeftSquareBracketKeyword_45 = (Keyword)cGroup.eContents().get(45);
private final RuleCall cDescriptionsDescriptionParserRuleCall_43_1_0 = (RuleCall)cDescriptionsAssignment_43_1.eContents().get(0); private final Assignment cDescriptionsAssignment_46 = (Assignment)cGroup.eContents().get(46);
private final Keyword cRightSquareBracketKeyword_44 = (Keyword)cGroup.eContents().get(44); private final RuleCall cDescriptionsDescriptionParserRuleCall_46_0 = (RuleCall)cDescriptionsAssignment_46.eContents().get(0);
private final Keyword cRightCurlyBracketKeyword_45 = (Keyword)cGroup.eContents().get(45); private final Group cGroup_47 = (Group)cGroup.eContents().get(47);
private final Keyword cCommaKeyword_47_0 = (Keyword)cGroup_47.eContents().get(0);
private final Assignment cDescriptionsAssignment_47_1 = (Assignment)cGroup_47.eContents().get(1);
private final RuleCall cDescriptionsDescriptionParserRuleCall_47_1_0 = (RuleCall)cDescriptionsAssignment_47_1.eContents().get(0);
private final Keyword cRightSquareBracketKeyword_48 = (Keyword)cGroup.eContents().get(48);
private final Keyword cRightCurlyBracketKeyword_49 = (Keyword)cGroup.eContents().get(49);
//Chemin: //Chemin:
// '{' // '{'
// '"nom"' ':' nom=Nom ','
// '"lieu_in"' ':' lieuIn=Nom ',' // '"lieu_in"' ':' lieuIn=Nom ','
// '"lieu_out"' ':' lieuOut=Nom ',' // '"lieu_out"' ':' lieuOut=Nom ','
// '"ouvert"' ':' ouvert=Condition ',' // '"ouvert"' ':' ouvert=Condition ','
@ -922,231 +928,247 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
// '}'; // '}';
@Override public ParserRule getRule() { return rule; } @Override public ParserRule getRule() { return rule; }
//'{' '"lieu_in"' ':' lieuIn=Nom ',' '"lieu_out"' ':' lieuOut=Nom ',' '"ouvert"' ':' ouvert=Condition ',' '"visible"' ':' //'{' '"nom"' ':' nom=Nom ',' '"lieu_in"' ':' lieuIn=Nom ',' '"lieu_out"' ':' lieuOut=Nom ',' '"ouvert"' ':'
//visible=Condition ',' '"obligatoire"' ':' obligatoire=Condition ',' '"connaissances"' ':' '[' (connaissances+=Nom (',' //ouvert=Condition ',' '"visible"' ':' visible=Condition ',' '"obligatoire"' ':' obligatoire=Condition ','
//connaissances+=Nom)*)? ']' ',' '"objets_recus"' ':' '[' (objetsRecus+=Nom (',' objetsRecus+=Nom)*)? ']' ',' //'"connaissances"' ':' '[' (connaissances+=Nom (',' connaissances+=Nom)*)? ']' ',' '"objets_recus"' ':' '['
//'"objets_conso"' ':' '[' (objetsConso+=Nom (',' objetsConso+=Nom)*)? ']' ',' '"descriptions"' ':' '[' //(objetsRecus+=Nom (',' objetsRecus+=Nom)*)? ']' ',' '"objets_conso"' ':' '[' (objetsConso+=Nom (','
//descriptions+=Description (',' descriptions+=Description)* ']' '}' //objetsConso+=Nom)*)? ']' ',' '"descriptions"' ':' '[' descriptions+=Description (',' descriptions+=Description)* ']'
//'}'
public Group getGroup() { return cGroup; } public Group getGroup() { return cGroup; }
//'{' //'{'
public Keyword getLeftCurlyBracketKeyword_0() { return cLeftCurlyBracketKeyword_0; } public Keyword getLeftCurlyBracketKeyword_0() { return cLeftCurlyBracketKeyword_0; }
//'"lieu_in"' //'"nom"'
public Keyword getLieu_inKeyword_1() { return cLieu_inKeyword_1; } public Keyword getNomKeyword_1() { return cNomKeyword_1; }
//':' //':'
public Keyword getColonKeyword_2() { return cColonKeyword_2; } public Keyword getColonKeyword_2() { return cColonKeyword_2; }
//lieuIn=Nom //nom=Nom
public Assignment getLieuInAssignment_3() { return cLieuInAssignment_3; } public Assignment getNomAssignment_3() { return cNomAssignment_3; }
//Nom //Nom
public RuleCall getLieuInNomParserRuleCall_3_0() { return cLieuInNomParserRuleCall_3_0; } public RuleCall getNomNomParserRuleCall_3_0() { return cNomNomParserRuleCall_3_0; }
//',' //','
public Keyword getCommaKeyword_4() { return cCommaKeyword_4; } public Keyword getCommaKeyword_4() { return cCommaKeyword_4; }
//'"lieu_out"' //'"lieu_in"'
public Keyword getLieu_outKeyword_5() { return cLieu_outKeyword_5; } public Keyword getLieu_inKeyword_5() { return cLieu_inKeyword_5; }
//':' //':'
public Keyword getColonKeyword_6() { return cColonKeyword_6; } public Keyword getColonKeyword_6() { return cColonKeyword_6; }
//lieuOut=Nom //lieuIn=Nom
public Assignment getLieuOutAssignment_7() { return cLieuOutAssignment_7; } public Assignment getLieuInAssignment_7() { return cLieuInAssignment_7; }
//Nom //Nom
public RuleCall getLieuOutNomParserRuleCall_7_0() { return cLieuOutNomParserRuleCall_7_0; } public RuleCall getLieuInNomParserRuleCall_7_0() { return cLieuInNomParserRuleCall_7_0; }
//',' //','
public Keyword getCommaKeyword_8() { return cCommaKeyword_8; } public Keyword getCommaKeyword_8() { return cCommaKeyword_8; }
//'"ouvert"' //'"lieu_out"'
public Keyword getOuvertKeyword_9() { return cOuvertKeyword_9; } public Keyword getLieu_outKeyword_9() { return cLieu_outKeyword_9; }
//':' //':'
public Keyword getColonKeyword_10() { return cColonKeyword_10; } public Keyword getColonKeyword_10() { return cColonKeyword_10; }
//ouvert=Condition //lieuOut=Nom
public Assignment getOuvertAssignment_11() { return cOuvertAssignment_11; } public Assignment getLieuOutAssignment_11() { return cLieuOutAssignment_11; }
//Condition //Nom
public RuleCall getOuvertConditionParserRuleCall_11_0() { return cOuvertConditionParserRuleCall_11_0; } public RuleCall getLieuOutNomParserRuleCall_11_0() { return cLieuOutNomParserRuleCall_11_0; }
//',' //','
public Keyword getCommaKeyword_12() { return cCommaKeyword_12; } public Keyword getCommaKeyword_12() { return cCommaKeyword_12; }
//'"visible"' //'"ouvert"'
public Keyword getVisibleKeyword_13() { return cVisibleKeyword_13; } public Keyword getOuvertKeyword_13() { return cOuvertKeyword_13; }
//':' //':'
public Keyword getColonKeyword_14() { return cColonKeyword_14; } public Keyword getColonKeyword_14() { return cColonKeyword_14; }
//visible=Condition //ouvert=Condition
public Assignment getVisibleAssignment_15() { return cVisibleAssignment_15; } public Assignment getOuvertAssignment_15() { return cOuvertAssignment_15; }
//Condition //Condition
public RuleCall getVisibleConditionParserRuleCall_15_0() { return cVisibleConditionParserRuleCall_15_0; } public RuleCall getOuvertConditionParserRuleCall_15_0() { return cOuvertConditionParserRuleCall_15_0; }
//',' //','
public Keyword getCommaKeyword_16() { return cCommaKeyword_16; } public Keyword getCommaKeyword_16() { return cCommaKeyword_16; }
//'"obligatoire"' //'"visible"'
public Keyword getObligatoireKeyword_17() { return cObligatoireKeyword_17; } public Keyword getVisibleKeyword_17() { return cVisibleKeyword_17; }
//':' //':'
public Keyword getColonKeyword_18() { return cColonKeyword_18; } public Keyword getColonKeyword_18() { return cColonKeyword_18; }
//obligatoire=Condition //visible=Condition
public Assignment getObligatoireAssignment_19() { return cObligatoireAssignment_19; } public Assignment getVisibleAssignment_19() { return cVisibleAssignment_19; }
//Condition //Condition
public RuleCall getObligatoireConditionParserRuleCall_19_0() { return cObligatoireConditionParserRuleCall_19_0; } public RuleCall getVisibleConditionParserRuleCall_19_0() { return cVisibleConditionParserRuleCall_19_0; }
//',' //','
public Keyword getCommaKeyword_20() { return cCommaKeyword_20; } public Keyword getCommaKeyword_20() { return cCommaKeyword_20; }
//'"connaissances"' //'"obligatoire"'
public Keyword getConnaissancesKeyword_21() { return cConnaissancesKeyword_21; } public Keyword getObligatoireKeyword_21() { return cObligatoireKeyword_21; }
//':' //':'
public Keyword getColonKeyword_22() { return cColonKeyword_22; } public Keyword getColonKeyword_22() { return cColonKeyword_22; }
//obligatoire=Condition
public Assignment getObligatoireAssignment_23() { return cObligatoireAssignment_23; }
//Condition
public RuleCall getObligatoireConditionParserRuleCall_23_0() { return cObligatoireConditionParserRuleCall_23_0; }
//','
public Keyword getCommaKeyword_24() { return cCommaKeyword_24; }
//'"connaissances"'
public Keyword getConnaissancesKeyword_25() { return cConnaissancesKeyword_25; }
//':'
public Keyword getColonKeyword_26() { return cColonKeyword_26; }
//'[' //'['
public Keyword getLeftSquareBracketKeyword_23() { return cLeftSquareBracketKeyword_23; } public Keyword getLeftSquareBracketKeyword_27() { return cLeftSquareBracketKeyword_27; }
//(connaissances+=Nom (',' connaissances+=Nom)*)? //(connaissances+=Nom (',' connaissances+=Nom)*)?
public Group getGroup_24() { return cGroup_24; } public Group getGroup_28() { return cGroup_28; }
//connaissances+=Nom //connaissances+=Nom
public Assignment getConnaissancesAssignment_24_0() { return cConnaissancesAssignment_24_0; } public Assignment getConnaissancesAssignment_28_0() { return cConnaissancesAssignment_28_0; }
//Nom //Nom
public RuleCall getConnaissancesNomParserRuleCall_24_0_0() { return cConnaissancesNomParserRuleCall_24_0_0; } public RuleCall getConnaissancesNomParserRuleCall_28_0_0() { return cConnaissancesNomParserRuleCall_28_0_0; }
//(',' connaissances+=Nom)* //(',' connaissances+=Nom)*
public Group getGroup_24_1() { return cGroup_24_1; } public Group getGroup_28_1() { return cGroup_28_1; }
//',' //','
public Keyword getCommaKeyword_24_1_0() { return cCommaKeyword_24_1_0; } public Keyword getCommaKeyword_28_1_0() { return cCommaKeyword_28_1_0; }
//connaissances+=Nom //connaissances+=Nom
public Assignment getConnaissancesAssignment_24_1_1() { return cConnaissancesAssignment_24_1_1; } public Assignment getConnaissancesAssignment_28_1_1() { return cConnaissancesAssignment_28_1_1; }
//Nom //Nom
public RuleCall getConnaissancesNomParserRuleCall_24_1_1_0() { return cConnaissancesNomParserRuleCall_24_1_1_0; } public RuleCall getConnaissancesNomParserRuleCall_28_1_1_0() { return cConnaissancesNomParserRuleCall_28_1_1_0; }
//']' //']'
public Keyword getRightSquareBracketKeyword_25() { return cRightSquareBracketKeyword_25; } public Keyword getRightSquareBracketKeyword_29() { return cRightSquareBracketKeyword_29; }
//',' //','
public Keyword getCommaKeyword_26() { return cCommaKeyword_26; } public Keyword getCommaKeyword_30() { return cCommaKeyword_30; }
//'"objets_recus"' //'"objets_recus"'
public Keyword getObjets_recusKeyword_27() { return cObjets_recusKeyword_27; } public Keyword getObjets_recusKeyword_31() { return cObjets_recusKeyword_31; }
//':' //':'
public Keyword getColonKeyword_28() { return cColonKeyword_28; } public Keyword getColonKeyword_32() { return cColonKeyword_32; }
//'[' //'['
public Keyword getLeftSquareBracketKeyword_29() { return cLeftSquareBracketKeyword_29; } public Keyword getLeftSquareBracketKeyword_33() { return cLeftSquareBracketKeyword_33; }
//(objetsRecus+=Nom (',' objetsRecus+=Nom)*)? //(objetsRecus+=Nom (',' objetsRecus+=Nom)*)?
public Group getGroup_30() { return cGroup_30; } public Group getGroup_34() { return cGroup_34; }
//objetsRecus+=Nom //objetsRecus+=Nom
public Assignment getObjetsRecusAssignment_30_0() { return cObjetsRecusAssignment_30_0; } public Assignment getObjetsRecusAssignment_34_0() { return cObjetsRecusAssignment_34_0; }
//Nom //Nom
public RuleCall getObjetsRecusNomParserRuleCall_30_0_0() { return cObjetsRecusNomParserRuleCall_30_0_0; } public RuleCall getObjetsRecusNomParserRuleCall_34_0_0() { return cObjetsRecusNomParserRuleCall_34_0_0; }
//(',' objetsRecus+=Nom)* //(',' objetsRecus+=Nom)*
public Group getGroup_30_1() { return cGroup_30_1; } public Group getGroup_34_1() { return cGroup_34_1; }
//',' //','
public Keyword getCommaKeyword_30_1_0() { return cCommaKeyword_30_1_0; } public Keyword getCommaKeyword_34_1_0() { return cCommaKeyword_34_1_0; }
//objetsRecus+=Nom //objetsRecus+=Nom
public Assignment getObjetsRecusAssignment_30_1_1() { return cObjetsRecusAssignment_30_1_1; } public Assignment getObjetsRecusAssignment_34_1_1() { return cObjetsRecusAssignment_34_1_1; }
//Nom //Nom
public RuleCall getObjetsRecusNomParserRuleCall_30_1_1_0() { return cObjetsRecusNomParserRuleCall_30_1_1_0; } public RuleCall getObjetsRecusNomParserRuleCall_34_1_1_0() { return cObjetsRecusNomParserRuleCall_34_1_1_0; }
//']' //']'
public Keyword getRightSquareBracketKeyword_31() { return cRightSquareBracketKeyword_31; } public Keyword getRightSquareBracketKeyword_35() { return cRightSquareBracketKeyword_35; }
//',' //','
public Keyword getCommaKeyword_32() { return cCommaKeyword_32; } public Keyword getCommaKeyword_36() { return cCommaKeyword_36; }
//'"objets_conso"' //'"objets_conso"'
public Keyword getObjets_consoKeyword_33() { return cObjets_consoKeyword_33; } public Keyword getObjets_consoKeyword_37() { return cObjets_consoKeyword_37; }
//':' //':'
public Keyword getColonKeyword_34() { return cColonKeyword_34; } public Keyword getColonKeyword_38() { return cColonKeyword_38; }
//'[' //'['
public Keyword getLeftSquareBracketKeyword_35() { return cLeftSquareBracketKeyword_35; } public Keyword getLeftSquareBracketKeyword_39() { return cLeftSquareBracketKeyword_39; }
//(objetsConso+=Nom (',' objetsConso+=Nom)*)? //(objetsConso+=Nom (',' objetsConso+=Nom)*)?
public Group getGroup_36() { return cGroup_36; } public Group getGroup_40() { return cGroup_40; }
//objetsConso+=Nom //objetsConso+=Nom
public Assignment getObjetsConsoAssignment_36_0() { return cObjetsConsoAssignment_36_0; } public Assignment getObjetsConsoAssignment_40_0() { return cObjetsConsoAssignment_40_0; }
//Nom //Nom
public RuleCall getObjetsConsoNomParserRuleCall_36_0_0() { return cObjetsConsoNomParserRuleCall_36_0_0; } public RuleCall getObjetsConsoNomParserRuleCall_40_0_0() { return cObjetsConsoNomParserRuleCall_40_0_0; }
//(',' objetsConso+=Nom)* //(',' objetsConso+=Nom)*
public Group getGroup_36_1() { return cGroup_36_1; } public Group getGroup_40_1() { return cGroup_40_1; }
//',' //','
public Keyword getCommaKeyword_36_1_0() { return cCommaKeyword_36_1_0; } public Keyword getCommaKeyword_40_1_0() { return cCommaKeyword_40_1_0; }
//objetsConso+=Nom //objetsConso+=Nom
public Assignment getObjetsConsoAssignment_36_1_1() { return cObjetsConsoAssignment_36_1_1; } public Assignment getObjetsConsoAssignment_40_1_1() { return cObjetsConsoAssignment_40_1_1; }
//Nom //Nom
public RuleCall getObjetsConsoNomParserRuleCall_36_1_1_0() { return cObjetsConsoNomParserRuleCall_36_1_1_0; } public RuleCall getObjetsConsoNomParserRuleCall_40_1_1_0() { return cObjetsConsoNomParserRuleCall_40_1_1_0; }
//']' //']'
public Keyword getRightSquareBracketKeyword_37() { return cRightSquareBracketKeyword_37; } public Keyword getRightSquareBracketKeyword_41() { return cRightSquareBracketKeyword_41; }
//',' //','
public Keyword getCommaKeyword_38() { return cCommaKeyword_38; } public Keyword getCommaKeyword_42() { return cCommaKeyword_42; }
//'"descriptions"' //'"descriptions"'
public Keyword getDescriptionsKeyword_39() { return cDescriptionsKeyword_39; } public Keyword getDescriptionsKeyword_43() { return cDescriptionsKeyword_43; }
//':' //':'
public Keyword getColonKeyword_40() { return cColonKeyword_40; } public Keyword getColonKeyword_44() { return cColonKeyword_44; }
//'[' //'['
public Keyword getLeftSquareBracketKeyword_41() { return cLeftSquareBracketKeyword_41; } public Keyword getLeftSquareBracketKeyword_45() { return cLeftSquareBracketKeyword_45; }
//descriptions+=Description //descriptions+=Description
public Assignment getDescriptionsAssignment_42() { return cDescriptionsAssignment_42; } public Assignment getDescriptionsAssignment_46() { return cDescriptionsAssignment_46; }
//Description //Description
public RuleCall getDescriptionsDescriptionParserRuleCall_42_0() { return cDescriptionsDescriptionParserRuleCall_42_0; } public RuleCall getDescriptionsDescriptionParserRuleCall_46_0() { return cDescriptionsDescriptionParserRuleCall_46_0; }
//(',' descriptions+=Description)* //(',' descriptions+=Description)*
public Group getGroup_43() { return cGroup_43; } public Group getGroup_47() { return cGroup_47; }
//',' //','
public Keyword getCommaKeyword_43_0() { return cCommaKeyword_43_0; } public Keyword getCommaKeyword_47_0() { return cCommaKeyword_47_0; }
//descriptions+=Description //descriptions+=Description
public Assignment getDescriptionsAssignment_43_1() { return cDescriptionsAssignment_43_1; } public Assignment getDescriptionsAssignment_47_1() { return cDescriptionsAssignment_47_1; }
//Description //Description
public RuleCall getDescriptionsDescriptionParserRuleCall_43_1_0() { return cDescriptionsDescriptionParserRuleCall_43_1_0; } public RuleCall getDescriptionsDescriptionParserRuleCall_47_1_0() { return cDescriptionsDescriptionParserRuleCall_47_1_0; }
//']' //']'
public Keyword getRightSquareBracketKeyword_44() { return cRightSquareBracketKeyword_44; } public Keyword getRightSquareBracketKeyword_48() { return cRightSquareBracketKeyword_48; }
//'}' //'}'
public Keyword getRightCurlyBracketKeyword_45() { return cRightCurlyBracketKeyword_45; } public Keyword getRightCurlyBracketKeyword_49() { return cRightCurlyBracketKeyword_49; }
} }
public class ObjetElements extends AbstractParserRuleElementFinder { public class ObjetElements extends AbstractParserRuleElementFinder {
private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.Objet"); private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.Objet");
@ -2284,61 +2306,73 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
public class ConditionBooleanElements extends AbstractParserRuleElementFinder { public class ConditionBooleanElements extends AbstractParserRuleElementFinder {
private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.ConditionBoolean"); private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.ConditionBoolean");
private final Assignment cValeurAssignment = (Assignment)rule.eContents().get(1); private final Assignment cValeurAssignment = (Assignment)rule.eContents().get(1);
private final RuleCall cValeurBooleanParserRuleCall_0 = (RuleCall)cValeurAssignment.eContents().get(0); private final RuleCall cValeurBOOLEANTerminalRuleCall_0 = (RuleCall)cValeurAssignment.eContents().get(0);
//ConditionBoolean: //ConditionBoolean:
// valeur=Boolean; // valeur=BOOLEAN;
@Override public ParserRule getRule() { return rule; } @Override public ParserRule getRule() { return rule; }
//valeur=Boolean //valeur=BOOLEAN
public Assignment getValeurAssignment() { return cValeurAssignment; } public Assignment getValeurAssignment() { return cValeurAssignment; }
//Boolean //BOOLEAN
public RuleCall getValeurBooleanParserRuleCall_0() { return cValeurBooleanParserRuleCall_0; } public RuleCall getValeurBOOLEANTerminalRuleCall_0() { return cValeurBOOLEANTerminalRuleCall_0; }
} }
public class ConditionConnaissanceElements extends AbstractParserRuleElementFinder { public class ConditionConnaissanceElements extends AbstractParserRuleElementFinder {
private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.ConditionConnaissance"); private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.ConditionConnaissance");
private final Assignment cConnaissanceAssignment = (Assignment)rule.eContents().get(1); private final Group cGroup = (Group)rule.eContents().get(1);
private final RuleCall cConnaissanceNomParserRuleCall_0 = (RuleCall)cConnaissanceAssignment.eContents().get(0); private final Assignment cNegationAssignment_0 = (Assignment)cGroup.eContents().get(0);
private final Keyword cNegationExclamationMarkKeyword_0_0 = (Keyword)cNegationAssignment_0.eContents().get(0);
private final Assignment cConnaissanceAssignment_1 = (Assignment)cGroup.eContents().get(1);
private final RuleCall cConnaissanceIDTerminalRuleCall_1_0 = (RuleCall)cConnaissanceAssignment_1.eContents().get(0);
//ConditionConnaissance: //ConditionConnaissance:
// connaissance=Nom; // negation='!'? connaissance=ID;
@Override public ParserRule getRule() { return rule; } @Override public ParserRule getRule() { return rule; }
//connaissance=Nom //negation='!'? connaissance=ID
public Assignment getConnaissanceAssignment() { return cConnaissanceAssignment; } public Group getGroup() { return cGroup; }
//Nom //negation='!'?
public RuleCall getConnaissanceNomParserRuleCall_0() { return cConnaissanceNomParserRuleCall_0; } public Assignment getNegationAssignment_0() { return cNegationAssignment_0; }
//'!'
public Keyword getNegationExclamationMarkKeyword_0_0() { return cNegationExclamationMarkKeyword_0_0; }
//connaissance=ID
public Assignment getConnaissanceAssignment_1() { return cConnaissanceAssignment_1; }
//ID
public RuleCall getConnaissanceIDTerminalRuleCall_1_0() { return cConnaissanceIDTerminalRuleCall_1_0; }
} }
public class ConditionObjetElements extends AbstractParserRuleElementFinder { public class ConditionObjetElements extends AbstractParserRuleElementFinder {
private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.ConditionObjet"); private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.ConditionObjet");
private final Group cGroup = (Group)rule.eContents().get(1); private final Group cGroup = (Group)rule.eContents().get(1);
private final Assignment cObjetAssignment_0 = (Assignment)cGroup.eContents().get(0); private final Assignment cObjetAssignment_0 = (Assignment)cGroup.eContents().get(0);
private final RuleCall cObjetNomParserRuleCall_0_0 = (RuleCall)cObjetAssignment_0.eContents().get(0); private final RuleCall cObjetIDTerminalRuleCall_0_0 = (RuleCall)cObjetAssignment_0.eContents().get(0);
private final Assignment cComparateurAssignment_1 = (Assignment)cGroup.eContents().get(1); private final Assignment cComparateurAssignment_1 = (Assignment)cGroup.eContents().get(1);
private final RuleCall cComparateurComparateurParserRuleCall_1_0 = (RuleCall)cComparateurAssignment_1.eContents().get(0); private final RuleCall cComparateurCOMPARATEURTerminalRuleCall_1_0 = (RuleCall)cComparateurAssignment_1.eContents().get(0);
private final Assignment cNombreAssignment_2 = (Assignment)cGroup.eContents().get(2); private final Assignment cNombreAssignment_2 = (Assignment)cGroup.eContents().get(2);
private final RuleCall cNombreINTTerminalRuleCall_2_0 = (RuleCall)cNombreAssignment_2.eContents().get(0); private final RuleCall cNombreINTTerminalRuleCall_2_0 = (RuleCall)cNombreAssignment_2.eContents().get(0);
//ConditionObjet: //ConditionObjet:
// objet=Nom comparateur=Comparateur nombre=INT; // objet=ID comparateur=COMPARATEUR nombre=INT;
@Override public ParserRule getRule() { return rule; } @Override public ParserRule getRule() { return rule; }
//objet=Nom comparateur=Comparateur nombre=INT //objet=ID comparateur=COMPARATEUR nombre=INT
public Group getGroup() { return cGroup; } public Group getGroup() { return cGroup; }
//objet=Nom //objet=ID
public Assignment getObjetAssignment_0() { return cObjetAssignment_0; } public Assignment getObjetAssignment_0() { return cObjetAssignment_0; }
//Nom //ID
public RuleCall getObjetNomParserRuleCall_0_0() { return cObjetNomParserRuleCall_0_0; } public RuleCall getObjetIDTerminalRuleCall_0_0() { return cObjetIDTerminalRuleCall_0_0; }
//comparateur=Comparateur //comparateur=COMPARATEUR
public Assignment getComparateurAssignment_1() { return cComparateurAssignment_1; } public Assignment getComparateurAssignment_1() { return cComparateurAssignment_1; }
//Comparateur //COMPARATEUR
public RuleCall getComparateurComparateurParserRuleCall_1_0() { return cComparateurComparateurParserRuleCall_1_0; } public RuleCall getComparateurCOMPARATEURTerminalRuleCall_1_0() { return cComparateurCOMPARATEURTerminalRuleCall_1_0; }
//nombre=INT //nombre=INT
public Assignment getNombreAssignment_2() { return cNombreAssignment_2; } public Assignment getNombreAssignment_2() { return cNombreAssignment_2; }
@ -2346,74 +2380,28 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
//INT //INT
public RuleCall getNombreINTTerminalRuleCall_2_0() { return cNombreINTTerminalRuleCall_2_0; } public RuleCall getNombreINTTerminalRuleCall_2_0() { return cNombreINTTerminalRuleCall_2_0; }
} }
public class ComparateurElements extends AbstractParserRuleElementFinder {
private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.Comparateur");
private final Alternatives cAlternatives = (Alternatives)rule.eContents().get(1);
private final Keyword cLessThanSignKeyword_0 = (Keyword)cAlternatives.eContents().get(0);
private final Keyword cGreaterThanSignKeyword_1 = (Keyword)cAlternatives.eContents().get(1);
private final Keyword cEqualsSignEqualsSignKeyword_2 = (Keyword)cAlternatives.eContents().get(2);
private final Keyword cLessThanSignEqualsSignKeyword_3 = (Keyword)cAlternatives.eContents().get(3);
private final Keyword cGreaterThanSignEqualsSignKeyword_4 = (Keyword)cAlternatives.eContents().get(4);
private final Keyword cExclamationMarkEqualsSignKeyword_5 = (Keyword)cAlternatives.eContents().get(5);
//Comparateur:
// '<' | '>' | '==' | '<=' | '>=' | '!=';
@Override public ParserRule getRule() { return rule; }
//'<' | '>' | '==' | '<=' | '>=' | '!='
public Alternatives getAlternatives() { return cAlternatives; }
//'<'
public Keyword getLessThanSignKeyword_0() { return cLessThanSignKeyword_0; }
//'>'
public Keyword getGreaterThanSignKeyword_1() { return cGreaterThanSignKeyword_1; }
//'=='
public Keyword getEqualsSignEqualsSignKeyword_2() { return cEqualsSignEqualsSignKeyword_2; }
//'<='
public Keyword getLessThanSignEqualsSignKeyword_3() { return cLessThanSignEqualsSignKeyword_3; }
//'>='
public Keyword getGreaterThanSignEqualsSignKeyword_4() { return cGreaterThanSignEqualsSignKeyword_4; }
//'!='
public Keyword getExclamationMarkEqualsSignKeyword_5() { return cExclamationMarkEqualsSignKeyword_5; }
}
public class BooleanElements extends AbstractParserRuleElementFinder {
private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.Boolean");
private final Alternatives cAlternatives = (Alternatives)rule.eContents().get(1);
private final Keyword cTrueKeyword_0 = (Keyword)cAlternatives.eContents().get(0);
private final Keyword cFalseKeyword_1 = (Keyword)cAlternatives.eContents().get(1);
//Boolean:
// 'true' | 'false';
@Override public ParserRule getRule() { return rule; }
//'true' | 'false'
public Alternatives getAlternatives() { return cAlternatives; }
//'true'
public Keyword getTrueKeyword_0() { return cTrueKeyword_0; }
//'false'
public Keyword getFalseKeyword_1() { return cFalseKeyword_1; }
}
public class NomElements extends AbstractParserRuleElementFinder { public class NomElements extends AbstractParserRuleElementFinder {
private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.Nom"); private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.Nom");
private final Assignment cNomAssignment = (Assignment)rule.eContents().get(1); private final Group cGroup = (Group)rule.eContents().get(1);
private final RuleCall cNomSTRINGTerminalRuleCall_0 = (RuleCall)cNomAssignment.eContents().get(0); private final Action cNomAction_0 = (Action)cGroup.eContents().get(0);
private final Assignment cNomAssignment_1 = (Assignment)cGroup.eContents().get(1);
private final RuleCall cNomSTRINGTerminalRuleCall_1_0 = (RuleCall)cNomAssignment_1.eContents().get(0);
//Nom: //Nom:
// nom=STRING; // {Nom} nom=STRING;
@Override public ParserRule getRule() { return rule; } @Override public ParserRule getRule() { return rule; }
//{Nom} nom=STRING
public Group getGroup() { return cGroup; }
//{Nom}
public Action getNomAction_0() { return cNomAction_0; }
//nom=STRING //nom=STRING
public Assignment getNomAssignment() { return cNomAssignment; } public Assignment getNomAssignment_1() { return cNomAssignment_1; }
//STRING //STRING
public RuleCall getNomSTRINGTerminalRuleCall_0() { return cNomSTRINGTerminalRuleCall_0; } public RuleCall getNomSTRINGTerminalRuleCall_1_0() { return cNomSTRINGTerminalRuleCall_1_0; }
} }
@ -2435,8 +2423,8 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
private final ConditionBooleanElements pConditionBoolean; private final ConditionBooleanElements pConditionBoolean;
private final ConditionConnaissanceElements pConditionConnaissance; private final ConditionConnaissanceElements pConditionConnaissance;
private final ConditionObjetElements pConditionObjet; private final ConditionObjetElements pConditionObjet;
private final ComparateurElements pComparateur; private final TerminalRule tCOMPARATEUR;
private final BooleanElements pBoolean; private final TerminalRule tBOOLEAN;
private final NomElements pNom; private final NomElements pNom;
private final Grammar grammar; private final Grammar grammar;
@ -2466,8 +2454,8 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
this.pConditionBoolean = new ConditionBooleanElements(); this.pConditionBoolean = new ConditionBooleanElements();
this.pConditionConnaissance = new ConditionConnaissanceElements(); this.pConditionConnaissance = new ConditionConnaissanceElements();
this.pConditionObjet = new ConditionObjetElements(); this.pConditionObjet = new ConditionObjetElements();
this.pComparateur = new ComparateurElements(); this.tCOMPARATEUR = (TerminalRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.COMPARATEUR");
this.pBoolean = new BooleanElements(); this.tBOOLEAN = (TerminalRule) GrammarUtil.findRuleForName(getGrammar(), "fr.n7.game.xtext.Game.BOOLEAN");
this.pNom = new NomElements(); this.pNom = new NomElements();
} }
@ -2564,6 +2552,7 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
//Chemin: //Chemin:
// '{' // '{'
// '"nom"' ':' nom=Nom ','
// '"lieu_in"' ':' lieuIn=Nom ',' // '"lieu_in"' ':' lieuIn=Nom ','
// '"lieu_out"' ':' lieuOut=Nom ',' // '"lieu_out"' ':' lieuOut=Nom ','
// '"ouvert"' ':' ouvert=Condition ',' // '"ouvert"' ':' ouvert=Condition ','
@ -2717,7 +2706,7 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
} }
//ConditionBoolean: //ConditionBoolean:
// valeur=Boolean; // valeur=BOOLEAN;
public ConditionBooleanElements getConditionBooleanAccess() { public ConditionBooleanElements getConditionBooleanAccess() {
return pConditionBoolean; return pConditionBoolean;
} }
@ -2727,7 +2716,7 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
} }
//ConditionConnaissance: //ConditionConnaissance:
// connaissance=Nom; // negation='!'? connaissance=ID;
public ConditionConnaissanceElements getConditionConnaissanceAccess() { public ConditionConnaissanceElements getConditionConnaissanceAccess() {
return pConditionConnaissance; return pConditionConnaissance;
} }
@ -2737,7 +2726,7 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
} }
//ConditionObjet: //ConditionObjet:
// objet=Nom comparateur=Comparateur nombre=INT; // objet=ID comparateur=COMPARATEUR nombre=INT;
public ConditionObjetElements getConditionObjetAccess() { public ConditionObjetElements getConditionObjetAccess() {
return pConditionObjet; return pConditionObjet;
} }
@ -2746,28 +2735,20 @@ public class GameGrammarAccess extends AbstractElementFinder.AbstractGrammarElem
return getConditionObjetAccess().getRule(); return getConditionObjetAccess().getRule();
} }
//Comparateur: //terminal COMPARATEUR:
// '<' | '>' | '==' | '<=' | '>=' | '!='; // '<' | '>' | '==' | '<=' | '>=' | '!=';
public ComparateurElements getComparateurAccess() { public TerminalRule getCOMPARATEURRule() {
return pComparateur; return tCOMPARATEUR;
} }
public ParserRule getComparateurRule() { //terminal BOOLEAN:
return getComparateurAccess().getRule();
}
//Boolean:
// 'true' | 'false'; // 'true' | 'false';
public BooleanElements getBooleanAccess() { public TerminalRule getBOOLEANRule() {
return pBoolean; return tBOOLEAN;
}
public ParserRule getBooleanRule() {
return getBooleanAccess().getRule();
} }
//Nom: //Nom:
// nom=STRING; // {Nom} nom=STRING;
public NomElements getNomAccess() { public NomElements getNomAccess() {
return pNom; return pNom;
} }

View file

@ -133,25 +133,26 @@ ConditionTest:
; ;
ConditionBoolean: ConditionBoolean:
valeur=Boolean valeur=BOOLEAN
; ;
ConditionConnaissance: ConditionConnaissance:
connaissance=Nom (negation='!')? connaissance=ID
; ;
ConditionObjet: ConditionObjet:
objet=Nom comparateur=Comparateur nombre=INT objet=ID comparateur=COMPARATEUR nombre=INT
; ;
Comparateur: terminal COMPARATEUR:
'<' | '>' | '==' | '<=' | '>=' | '!=' '<' | '>' | '==' | '<=' | '>=' | '!='
; ;
Boolean: terminal BOOLEAN:
'true' | 'false' 'true' | 'false'
; ;
Nom: Nom:
{Nom}
nom=STRING nom=STRING
; ;