Author: agiraudet Date: 2013-05-03 17:03:19 +0200 (Fri, 03 May 2013) New Revision: 607 Url: http://nuiton.org/projects/sandbox/repository/revisions/607 Log: ajout de la syntaxe pure yaml : uml5.yaml Added: testEugeneUML-YAML/testsnakeyaml/uml5.yaml Modified: testEugeneUML-YAML/testeugene/pom.xml testEugeneUML-YAML/testeugene/testpollen/pom.xml testEugeneUML-YAML/testeugene/testpollen/src/main/xmi/pollen.zargo testEugeneUML-YAML/testsnakeyaml/src/main/java/testsnakeyaml.java Modified: testEugeneUML-YAML/testeugene/pom.xml =================================================================== --- testEugeneUML-YAML/testeugene/pom.xml 2013-05-02 13:45:04 UTC (rev 606) +++ testEugeneUML-YAML/testeugene/pom.xml 2013-05-03 15:03:19 UTC (rev 607) @@ -20,12 +20,6 @@ <dependencies> <dependency> <groupId>org.nuiton.eugene</groupId> - <artifactId>eugene</artifactId> - <version>2.6.2</version> - </dependency> - - <dependency> - <groupId>org.nuiton.eugene</groupId> <artifactId>eugene-maven-plugin</artifactId> <version>2.6.2</version> </dependency> Modified: testEugeneUML-YAML/testeugene/testpollen/pom.xml =================================================================== --- testEugeneUML-YAML/testeugene/testpollen/pom.xml 2013-05-02 13:45:04 UTC (rev 606) +++ testEugeneUML-YAML/testeugene/testpollen/pom.xml 2013-05-03 15:03:19 UTC (rev 607) @@ -21,7 +21,7 @@ <plugin> <groupId>org.nuiton.eugene</groupId> <artifactId>eugene-maven-plugin</artifactId> - <version>2.6.2-SNAPSHOT</version> + <version>2.6.2</version> <executions> <execution> <phase>generate-sources</phase> Modified: testEugeneUML-YAML/testeugene/testpollen/src/main/xmi/pollen.zargo =================================================================== (Binary files differ) Modified: testEugeneUML-YAML/testsnakeyaml/src/main/java/testsnakeyaml.java =================================================================== --- testEugeneUML-YAML/testsnakeyaml/src/main/java/testsnakeyaml.java 2013-05-02 13:45:04 UTC (rev 606) +++ testEugeneUML-YAML/testsnakeyaml/src/main/java/testsnakeyaml.java 2013-05-03 15:03:19 UTC (rev 607) @@ -127,9 +127,11 @@ } public static void main (String[] args) throws IOException { - //new testsnakeyaml("uml4.yaml").afficher(); - //System.out.println(new testsnakeyaml("uml4.yaml").toString()); + // trouver nom pour l'extension + String diagram = "uml5.yaml"; + //new testsnakeyaml(diagram).afficher(); + System.out.println(new testsnakeyaml(diagram).toString()); // afficher arbre des objets // pattern composit - new testsnakeyaml("uml4.yaml").afficherClass(); + //new testsnakeyaml(diagram).afficherClass(); } } Added: testEugeneUML-YAML/testsnakeyaml/uml5.yaml =================================================================== --- testEugeneUML-YAML/testsnakeyaml/uml5.yaml (rev 0) +++ testEugeneUML-YAML/testsnakeyaml/uml5.yaml 2013-05-03 15:03:19 UTC (rev 607) @@ -0,0 +1,320 @@ +%YAML 1.1 +--- +# syntaxe uml/yaml version 5 - pure YAML + +# http://yaml.org/ +# syntaxe semblable à l'ObjectModel XML +# améliorations possibles : - gestion de l'heritage multiple et de plusieurs parametres de retour pour les operations + +# liens utiles +# http://maven-site.nuiton.org/eugene/objectmodel/ObjectModel.png +# http://maven-site.nuiton.org/eugene/xsd/v1/objectmodel.xsd + +# model +- name: String 1 +- version: String 0..1 +# package: ? + # * +- imports: + String: String + Date: java.util.Date + # * +- comments: + - String + - comment + # * +- tagValues: + String: String + key: value + +# * +- class: + # * + - stereotype: + - String + - stereotype + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 1 + - abstract: boolean 0..1 + - final: boolean 0..1 + # * + # besoin d'appliquer comments et tagValues aux superClasses ? + - superClasses: + - String + - superclass + # * + # besoin d'appliquer comments et tagValues aux superInterfaces ? + - superinterfaces: + - String + - superinterface + # * + - attribute: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 0..1 + - visibility: String 0..1 + - type: String 0..1 + - static: boolean 0..1 + - final: boolean 0..1 + - associationType: String 0..1 + - minMultiplicity: Integer 0..1 + - maxMultiplicity: Integer 0..1 + - navigable: boolean 0..1 + - ordering: String 0..1 + - label: String 0..1 + # operation + # - comments - tagValues + - operation: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 1 + - visibility: String 0..1 + - abstract: boolean 0..1 + - static: boolean 0..1 + - final: boolean 0..1 + # syntaxe des parametres ne permettant pas d'appliquer de tagValues/comments aux parametres + # optionnel + #- parameters: + # parameter1: type + # parameter2: type + # optionnel + #- returnParameter: + # - returnparameter1 + # - returnparameter2 + # * + - parameter: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - type: String 1 + - name: String 0..1 + - returnParameter: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - type: String 1 + +# interfaces +# * +- interface: + # * + - stereotype: + - String + - stereotype + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 1 + - abstract: boolean 0..1 + - final: boolean 0..1 + # * + # besoin d'appliquer comments et tagValues aux superClasses ? + - superClasses: + - String + - superclass + # * + # besoin d'appliquer comments et tagValues aux superInterfaces ? + - superinterfaces: + - String + - superinterface + # * + - attribute: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 0..1 + - visibility: String 0..1 + - type: String 0..1 + - static: boolean 0..1 + - final: boolean 0..1 + - associationType: String 0..1 + - minMultiplicity: Integer 0..1 + - maxMultiplicity: Integer 0..1 + - navigable: boolean 0..1 + - ordering: String 0..1 + - label: String 0..1 + # operation + # - comments - tagValues + - operation: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 1 + - visibility: String 0..1 + - abstract: boolean 0..1 + - static: boolean 0..1 + - final: boolean 0..1 + # syntaxe des parametres ne permettant pas d'appliquer de tagValues/comments aux parametres + # optionnel + #- parameters: + # parameter1: type + # parameter2: type + # optionnel + #- returnParameter: + # - returnparameter1 + # - returnparameter2 + # * + - parameter: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - type: String 1 + - name: String 0..1 + - returnParameter: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - type: String 1 + +# classifiers +# * +- classifier: + # * + - stereotype: + - String + - stereotype + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 1 + - abstract: boolean 0..1 + - final: boolean 0..1 + # * + # besoin d'appliquer comments et tagValues aux superClasses ? + - superClasses: + - String + - superclass + # * + # besoin d'appliquer comments et tagValues aux superInterfaces ? + - superinterfaces: + - String + - superinterface + # * + - attribute: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 0..1 + - visibility: String 0..1 + - type: String 0..1 + - static: boolean 0..1 + - final: boolean 0..1 + - associationType: String 0..1 + - minMultiplicity: Integer 0..1 + - maxMultiplicity: Integer 0..1 + - navigable: boolean 0..1 + - ordering: String 0..1 + - label: String 0..1 + # operation + # - comments - tagValues + - operation: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - name: String 1 + - visibility: String 0..1 + - abstract: boolean 0..1 + - static: boolean 0..1 + - final: boolean 0..1 + # syntaxe des parametres ne permettant pas d'appliquer de tagValues/comments aux parametres + # optionnel + #- parameters: + # parameter1: type + # parameter2: type + # optionnel + #- returnParameter: + # - returnparameter1 + # - returnparameter2 + # * + - parameter: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - type: String 1 + - name: String 0..1 + - returnParameter: + # * + - comments: + - String + - comment + # * + - tagValues: + String: String + key: value + - type: String 1 + +# enumerations