Author: tchemit Date: 2010-04-12 20:16:47 +0200 (Mon, 12 Apr 2010) New Revision: 860 Log: - Evolution #495: Use maven-license-plugin 2.1 - Evolution #496: Use junit 4.8.1 - update headers - big clean in code : - remove redundant initializer - remove public accessor on interfaces - remove redudant super constructor call - remove redudant this call - fix some javadoc - reformat some code Modified: trunk/ant-eugene-task/pom.xml trunk/ant-eugene-task/src/main/java/org/nuiton/eugene/GeneratorTask.java trunk/ant-eugene-task/src/site/fr/rst/index.rst trunk/ant-eugene-task/src/site/resources/build.xml trunk/ant-eugene-task/src/site/rst/index.rst trunk/ant-eugene-task/src/site/site_en.xml trunk/ant-eugene-task/src/site/site_fr.xml trunk/ant-eugene-task/src/test/java/org/nuiton/eugene/BasicObjectModelGenerator.java trunk/ant-eugene-task/src/test/java/org/nuiton/eugene/GeneratorTaskTest.java trunk/eugene/pom.xml trunk/eugene/src/main/java/org/nuiton/eugene/AbstractGenerator.java trunk/eugene/src/main/java/org/nuiton/eugene/AbstractMetaTransformer.java trunk/eugene/src/main/java/org/nuiton/eugene/GeneratorException.java trunk/eugene/src/main/java/org/nuiton/eugene/GeneratorUtil.java trunk/eugene/src/main/java/org/nuiton/eugene/ImportsManager.java trunk/eugene/src/main/java/org/nuiton/eugene/ModelReader.java trunk/eugene/src/main/java/org/nuiton/eugene/MonitorWriter.java trunk/eugene/src/main/java/org/nuiton/eugene/PackageValidator.java trunk/eugene/src/main/java/org/nuiton/eugene/Template.java trunk/eugene/src/main/java/org/nuiton/eugene/Transformer.java trunk/eugene/src/main/java/org/nuiton/eugene/java/AnnotationsManager.java trunk/eugene/src/main/java/org/nuiton/eugene/java/AnnotationsManagerExtension.java trunk/eugene/src/main/java/org/nuiton/eugene/java/ConstantsManager.java trunk/eugene/src/main/java/org/nuiton/eugene/java/ConstantsManagerExtension.java trunk/eugene/src/main/java/org/nuiton/eugene/java/ImportsManager.java trunk/eugene/src/main/java/org/nuiton/eugene/java/ImportsManagerExtension.java trunk/eugene/src/main/java/org/nuiton/eugene/java/JavaBuilder.java trunk/eugene/src/main/java/org/nuiton/eugene/java/JavaGenerator.java trunk/eugene/src/main/java/org/nuiton/eugene/java/ObjectModelTransformerToJava.java trunk/eugene/src/main/java/org/nuiton/eugene/java/package-info.java trunk/eugene/src/main/java/org/nuiton/eugene/models/Model.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModel.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelAssociationClass.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelAttribute.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelBuilder.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelClass.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelClassifier.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelDependency.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelElement.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelEnumeration.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelGenerator.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelInterface.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelModifier.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelOperation.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelParameter.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelReader.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelTransformer.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelType.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelVisibility.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/AttributeNamesValidator.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/ClassNamesValidator.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/NameBasedValidator.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/ObjectModelValidator.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/DigesterObjectModelRuleSet.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ExternalCacheExtension.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModeImplAssociationClassParticipant.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelAssociationClassImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelAttributeImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelClassImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelClassifierImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelDependencyImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelElementImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelEnumerationImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplRef.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplSuperClassRef.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplTagValue.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelInterfaceImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelOperationImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelParameterImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModel.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelComplexState.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelGenerator.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelReader.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelSimpleState.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelState.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelStateChart.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelTransition.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/DigesterStateModelRuleSet.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelComplexeStateImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelSimpleStateImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelStateChartImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelStateImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelTransitionImpl.java trunk/eugene/src/main/java/org/nuiton/eugene/package-info.java trunk/eugene/src/main/java/org/nuiton/eugene/writer/AbstractChainedFileWriter.java trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriter.java trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriterConfiguration.java trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriterEntry.java trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedWriterEngine.java trunk/eugene/src/main/java/org/nuiton/eugene/writer/DefaultChainedWriterEngine.java trunk/eugene/src/main/java/org/nuiton/eugene/writer/package-info.java trunk/eugene/src/site/fr/rst/DevUIDoc.rst trunk/eugene/src/site/fr/rst/DiscussionSurTypeDeGeneration.rst trunk/eugene/src/site/fr/rst/Todo.rst trunk/eugene/src/site/fr/rst/index.rst trunk/eugene/src/site/fr/rst/plugineclipse.rst trunk/eugene/src/site/rst/LutinGenerator.rst trunk/eugene/src/site/rst/generatorHelp.rst trunk/eugene/src/site/rst/index.rst trunk/eugene/src/site/site_en.xml trunk/eugene/src/site/site_fr.xml trunk/eugene/src/test/java/org/nuiton/eugene/GeneratorUtilTest.java trunk/eugene/src/test/java/org/nuiton/eugene/java/ImportsManagerExtensionTest.java trunk/eugene/src/test/java/org/nuiton/eugene/java/ImportsManagerTest.java trunk/eugene/src/test/java/org/nuiton/eugene/java/JavaBuilderTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/object/ModelMergeTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/object/ObjectModelGeneratorTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/object/XMI12ToObjectModelTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/object/XMI21ToObjectModelTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ExternalCacheExtensionTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ObjectModelBuilderTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ObjectModelImplTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/state/StateModelDTDTest.java trunk/eugene/src/test/java/org/nuiton/eugene/models/state/StateModelTest.java trunk/maven-eugene-plugin/pom.xml trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/AvailableDataMojo.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/CopyVersionFiles.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/EugeneAbstractMojo.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/EugenePlugin.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/SmartGenerateMojo.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2Model.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2ObjectModel.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2StateModel.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Zargo2Xmi.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/BaseChainedFileWriter.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/ModelChainedFileWriter.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/XmiChainedFileWriter.java trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/ZargoChainedFileWriter.java trunk/maven-eugene-plugin/src/site/fr/rst/example.rst trunk/maven-eugene-plugin/src/site/fr/rst/index.rst trunk/maven-eugene-plugin/src/site/fr/rst/usage.rst trunk/maven-eugene-plugin/src/site/rst/example.rst trunk/maven-eugene-plugin/src/site/rst/index.rst trunk/maven-eugene-plugin/src/site/rst/usage.rst trunk/maven-eugene-plugin/src/site/site_en.xml trunk/maven-eugene-plugin/src/site/site_fr.xml trunk/pom.xml trunk/src/license/project.xml trunk/src/site/fr/rst/01-introduction.rst trunk/src/site/fr/rst/02-objectmodel.rst trunk/src/site/fr/rst/03-generation.rst trunk/src/site/fr/rst/04-templates.rst trunk/src/site/fr/rst/05-execution.rst trunk/src/site/fr/rst/06-fonctionnalites-avancees.rst trunk/src/site/fr/rst/07-glossaire.rst trunk/src/site/fr/rst/08-FAQ.rst trunk/src/site/fr/rst/09-tutoriel-index.rst trunk/src/site/fr/rst/eugene-plan.rst trunk/src/site/fr/rst/index.rst trunk/src/site/rst/01-introduction.rst trunk/src/site/rst/02-objectmodel.rst trunk/src/site/rst/03-generation.rst trunk/src/site/rst/04-templates.rst trunk/src/site/rst/05-execution.rst trunk/src/site/rst/06-fonctionnalites-avancees.rst trunk/src/site/rst/07-glossaire.rst trunk/src/site/rst/08-FAQ.rst trunk/src/site/rst/09-tutoriel-index.rst trunk/src/site/rst/index.rst trunk/src/site/site_en.xml trunk/src/site/site_fr.xml Modified: trunk/ant-eugene-task/pom.xml =================================================================== --- trunk/ant-eugene-task/pom.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/pom.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: Ant task + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2006 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> Modified: trunk/ant-eugene-task/src/main/java/org/nuiton/eugene/GeneratorTask.java =================================================================== --- trunk/ant-eugene-task/src/main/java/org/nuiton/eugene/GeneratorTask.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/src/main/java/org/nuiton/eugene/GeneratorTask.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% - * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * +/* + * #%L + * EUGene :: Ant task + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene; @@ -296,8 +305,8 @@ String[] includedFilenames = scanner.getIncludedFiles(); List<File> includedFiles = new ArrayList<File>( includedFilenames.length); - for (int i = 0; i < includedFilenames.length; ++i) { - includedFiles.add(new File(srcDir, includedFilenames[i])); + for (String includedFilename : includedFilenames) { + includedFiles.add(new File(srcDir, includedFilename)); } doExecute(includedFiles, destDir, generators); } @@ -333,7 +342,8 @@ for (Template<Model> generator : generators) { if (generator != null) { - File[] modelFilesArray = modelFiles.toArray(new File[0]); + File[] modelFilesArray = + modelFiles.toArray(new File[modelFiles.size()]); log("Applying " + generator.getClass().getSimpleName() + " on " + Arrays.toString(modelFilesArray), Project.MSG_INFO); @@ -342,22 +352,27 @@ for (String transformation : transformationsArray) { if ("object".equals(transformation)) { - ModelReader<ObjectModel> objectModelReader = new ObjectModelReader(); - ObjectModel model = objectModelReader.read(modelFilesArray); + ModelReader<ObjectModel> objectModelReader = + new ObjectModelReader(); + ObjectModel model = + objectModelReader.read(modelFilesArray); try { generator.applyTemplate(model, destDir); } catch (IOException e) { - throw new BuildException("Can't apply template on object model", e); + throw new BuildException( + "Can't apply template on object model", e); } } else if ("state".equals(transformation)) { - ModelReader<StateModel> stateModelReader = new StateModelReader(); + ModelReader<StateModel> stateModelReader = + new StateModelReader(); Model model = stateModelReader.read(modelFilesArray); try { generator.applyTemplate(model, destDir); } catch (IOException e) { - throw new BuildException("Can't apply template on state model", e); + throw new BuildException( + "Can't apply template on state model", e); } } } @@ -476,7 +491,8 @@ "xmi1.2ToStateModel.xsl"); } else if (xmiVersion.equals("2.1")) { throw new BuildException( - "State model transformation is not supported for xmi 2.1"); + "State model transformation is not " + + "supported for xmi 2.1"); } // can have more than one model file @@ -577,10 +593,9 @@ */ protected class XmiVersionHandler extends DefaultHandler { - public String version = null; + public String version; public XmiVersionHandler() { - super(); } public String getVersion() { @@ -679,9 +694,11 @@ } catch (ClassNotFoundException e) { throw new BuildException("Can't find resolver", e); } catch (IOException e) { - throw new BuildException("Error while trying to access stylesheet", e); + throw new BuildException( + "Error while trying to access stylesheet", e); } catch (SecurityException e) { - throw new BuildException("Error while trying to access stylesheet", e); + throw new BuildException( + "Error while trying to access stylesheet", e); } } Modified: trunk/ant-eugene-task/src/site/fr/rst/index.rst =================================================================== --- trunk/ant-eugene-task/src/site/fr/rst/index.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/src/site/fr/rst/index.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -4,6 +4,34 @@ .. contents:: +.. - +.. * #%L +.. * EUGene :: Ant task +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2006 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Téléchargement -------------- Modified: trunk/ant-eugene-task/src/site/resources/build.xml =================================================================== --- trunk/ant-eugene-task/src/site/resources/build.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/src/site/resources/build.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,30 @@ +<!-- + #%L + EUGene :: Ant task + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2006 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> <project name="EugeneHelloWorld" default="compile" basedir="."> <description> Simple example build file Modified: trunk/ant-eugene-task/src/site/rst/index.rst =================================================================== --- trunk/ant-eugene-task/src/site/rst/index.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/src/site/rst/index.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -7,6 +7,34 @@ .. contents:: +.. - +.. * #%L +.. * EUGene :: Ant task +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2006 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Download -------- Modified: trunk/ant-eugene-task/src/site/site_en.xml =================================================================== --- trunk/ant-eugene-task/src/site/site_en.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/src/site/site_en.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: Ant task + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2006 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project name="${project.name}"> <bannerLeft> Modified: trunk/ant-eugene-task/src/site/site_fr.xml =================================================================== --- trunk/ant-eugene-task/src/site/site_fr.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/src/site/site_fr.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: Ant task + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2006 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project name="${project.name}"> <bannerLeft> Modified: trunk/ant-eugene-task/src/test/java/org/nuiton/eugene/BasicObjectModelGenerator.java =================================================================== --- trunk/ant-eugene-task/src/test/java/org/nuiton/eugene/BasicObjectModelGenerator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/src/test/java/org/nuiton/eugene/BasicObjectModelGenerator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% - * EUGene :: EUGene - * Copyright (C) 2010 CodeLutin - * +/* + * #%L + * EUGene :: Ant task + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene; @@ -37,17 +46,12 @@ */ public class BasicObjectModelGenerator extends ObjectModelGenerator { - /* - * @see org.nuiton.eugene.models.object.ObjectModelGenerator#getFilenameForClass(org.nuiton.eugene.models.object.ObjectModelClass) - */ @Override public String getFilenameForClass(ObjectModelClass clazz) { - return clazz.getQualifiedName().replace('.', File.separatorChar) + ".java"; + return clazz.getQualifiedName().replace('.', File.separatorChar) + + ".java"; } - /* - * @see org.nuiton.eugene.models.object.ObjectModelGenerator#generateFromClass(java.io.Writer, org.nuiton.eugene.models.object.ObjectModelClass) - */ @Override public void generateFromClass(Writer output, ObjectModelClass clazz) throws IOException { Modified: trunk/ant-eugene-task/src/test/java/org/nuiton/eugene/GeneratorTaskTest.java =================================================================== --- trunk/ant-eugene-task/src/test/java/org/nuiton/eugene/GeneratorTaskTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/ant-eugene-task/src/test/java/org/nuiton/eugene/GeneratorTaskTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% - * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * +/* + * #%L + * EUGene :: Ant task + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene; @@ -91,10 +100,21 @@ generatorTask.execute(); // Test some file existence - Assert.assertTrue(new File(destDirGen, "org/codelutin/math/matrix/MatrixND.java").exists()); - Assert.assertTrue(new File(destDirGen, "org/codelutin/math/matrix/MatrixND.java").exists()); - Assert.assertTrue(new File(destDirGen, "org/test/enums/TestClass.java").exists()); + Assert.assertTrue(new File( + destDirGen, + "org/codelutin/math/matrix/MatrixND.java" + ).exists()); + Assert.assertTrue(new File( + destDirGen, + "org/codelutin/math/matrix/MatrixND.java" + ).exists()); + + Assert.assertTrue(new File( + destDirGen, + "org/test/enums/TestClass.java" + ).exists()); + // remove created temp dir FileUtil.deleteRecursively(destDirGen); } @@ -208,7 +228,8 @@ if (!"TestXMI21.objectmodel".equals(file.getName()) && !"TestXMI21.properties".equals(file.getName())) { Assert.fail("Unexpected file: " + filePath + - ". Should be TestXMI21.objectmodel or TestXMI21.properties"); + ". Should be TestXMI21.objectmodel or " + + "TestXMI21.properties"); } } Modified: trunk/eugene/pom.xml =================================================================== --- trunk/eugene/pom.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/pom.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,31 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: EUGene + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2004 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> @@ -248,16 +275,7 @@ </plugins> </build> - - <reporting> - <plugins> - <plugin> - <groupId>org.codehaus.plexus</groupId> - <artifactId>plexus-maven-plugin</artifactId> - <version>1.3.8</version> - </plugin> - </plugins> - </reporting> + <!-- ************************************************************* --> <!-- *** Build Environment ************************************** --> <!-- ************************************************************* --> @@ -300,6 +318,28 @@ </plugins> </build> </profile> + + <!-- perform only on a release stage when using the maven-release-plugin --> + <profile> + <id>reporting</id> + <activation> + <property> + <name>performRelease</name> + <value>true</value> + </property> + </activation> + + <reporting> + <plugins> + <plugin> + <groupId>org.codehaus.plexus</groupId> + <artifactId>plexus-maven-plugin</artifactId> + <version>1.3.8</version> + </plugin> + </plugins> + </reporting> + + </profile> </profiles> </project> Modified: trunk/eugene/src/main/java/org/nuiton/eugene/AbstractGenerator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/AbstractGenerator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/AbstractGenerator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene; import org.nuiton.eugene.models.Model; @@ -38,14 +46,12 @@ */ public abstract class AbstractGenerator<M extends Model> extends Template<M> { - protected AbstractGenerator<M> parent = null; + protected AbstractGenerator<M> parent; public AbstractGenerator() { - super(); } public AbstractGenerator(AbstractGenerator<M> parent) { - super(); setParent(parent); } @@ -112,8 +118,9 @@ /** * Test if given package is allowed for generation. * - * An element can be generated if his package is in the {@link #generatedPackages} list - * or if {@link #generatedPackages} is null or empty. + * An element can be generated if his package is in the + * {@link #generatedPackages} list or if {@link #generatedPackages} is null + * or empty. * * @param packageName package name to test * @return generation allowed @@ -124,7 +131,8 @@ return parent.canGeneratePackage(packageName); } // if not generation restriction, generate everything - if (getGeneratedPackages() != null && !getGeneratedPackages().isEmpty()) { + if (getGeneratedPackages() != null && + !getGeneratedPackages().isEmpty()) { canGenerate = false; // on doit donc tester que le package courant @@ -133,7 +141,8 @@ for (String generatedPackage : getGeneratedPackages()) { // cas egalité parfaites - if (packageName != null && packageName.equals(generatedPackage)) { + if (packageName != null && + packageName.equals(generatedPackage)) { canGenerate = true; } @@ -142,7 +151,8 @@ if (!localGeneratedPackage.endsWith(".")) { localGeneratedPackage += "."; } - if (packageName != null && packageName.startsWith(localGeneratedPackage)) { + if (packageName != null && + packageName.startsWith(localGeneratedPackage)) { canGenerate = true; } @@ -161,26 +171,29 @@ if (!write0utputFile.getParentFile().exists()) { boolean b = write0utputFile.getParentFile().mkdirs(); if (!b) { - throw new IllegalStateException("could not create directory " + write0utputFile.getParentFile()); + throw new IllegalStateException( + "could not create directory " + + write0utputFile.getParentFile()); } } Writer output; String encoding = getEncoding(); + FileOutputStream stream = new FileOutputStream(write0utputFile); if (encoding != null) { if (log.isDebugEnabled()) { log.debug("Force encoding to " + encoding + " : " + this); } - output = new OutputStreamWriter(new FileOutputStream( - write0utputFile), encoding); + output = new OutputStreamWriter(stream, encoding); } else { - output = new OutputStreamWriter(new FileOutputStream( - write0utputFile)); + output = new OutputStreamWriter(stream); } - - output.write(out.getBuffer().toString()); - output.close(); + try { + output.write(out.getBuffer().toString()); + } finally { + output.close(); + } } catch (IOException eee) { if (log.isWarnEnabled()) { log.warn("Unable to write file : " + write0utputFile.getAbsolutePath(), eee); Modified: trunk/eugene/src/main/java/org/nuiton/eugene/AbstractMetaTransformer.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/AbstractMetaTransformer.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/AbstractMetaTransformer.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,31 @@ +/* + * #%L + * EUGene :: EUGene + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Lesser Public License for more details. + * + * You should have received a copy of the GNU General Lesser Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/lgpl-3.0.html>. + * #L% + */ + package org.nuiton.eugene; import org.nuiton.eugene.models.Model; @@ -8,7 +36,8 @@ import java.util.List; /** - * Abstract meta transformer which contains some templates to apply to an incoming model. + * Abstract meta transformer which contains some templates to apply to an + * incoming model. * * Using the {@link #getExcludeTemplates()} to restrict use of some templates. * @@ -25,7 +54,8 @@ private final Class<? extends Template<M>>[] transformers; - public AbstractMetaTransformer(Class<? extends Template<M>>... transformers) { + public AbstractMetaTransformer( + Class<? extends Template<M>>... transformers) { this.transformers = transformers; } @@ -33,7 +63,9 @@ @Override public final void generate(File[] file, File destDir) { - throw new UnsupportedOperationException("Transformer does not implements any longer this deprecated method"); + throw new UnsupportedOperationException( + "Transformer does not implements any longer this deprecated " + + "method"); } @Override @@ -52,7 +84,8 @@ for (Template<M> template : templates) { // log if (log.isDebugEnabled()) { - log.debug("call template : " + template.getClass().getSimpleName()); + log.debug("call template : " + + template.getClass().getSimpleName()); } template.applyTemplate(model, destDir); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/GeneratorException.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/GeneratorException.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/GeneratorException.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/GeneratorUtil.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/GeneratorUtil.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/GeneratorUtil.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,32 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene; import org.apache.commons.lang.StringUtils; @@ -149,10 +158,10 @@ return false; } String type = attribute.getType(); - return ("byte".equals(type) || "short".equals(type) + return "byte".equals(type) || "short".equals(type) || "int".equals(type) || "long".equals(type) || "float".equals(type) || "double".equals(type) - || "char".equals(type) || "boolean".equals(type)); + || "char".equals(type) || "boolean".equals(type); } /** @@ -265,7 +274,7 @@ * @param params the paramters to treate * @return la chaine de caractere dont on a besoin pour la declaration * des parametres d'une methode avec leurs types. - * @deprecated since 2.0.1, use {@link #getOperationParametersListDeclaration(org.nuiton.eugene.models.object.ObjectModelOperation)} instead + * @deprecated since 2.0.1, use {@link #getOperationParametersListDeclaration(ObjectModelOperation)} instead */ @Deprecated public static String getMethodParameterDeclaration( @@ -285,7 +294,7 @@ * @param params the paramters to treate * @return la chaine de caractere qui represente chaque nom de parametre * separer par des ','. - * @deprecated since 2.0.1, use {@link #getOperationParametersListName(org.nuiton.eugene.models.object.ObjectModelOperation) Declaration(org.nuiton.eugene.models.object.ObjectModelOperation)} instead + * @deprecated since 2.0.1, use {@link #getOperationParametersListName(ObjectModelOperation) Declaration(org.nuiton.eugene.models.object.ObjectModelOperation)} instead */ @Deprecated public static String getMethodParameterListName( @@ -311,7 +320,7 @@ } public static boolean isNMultiplicity(int multiplicity) { - return (multiplicity == -1) || (multiplicity > 1); + return multiplicity == -1 || multiplicity > 1; } /** @@ -441,7 +450,7 @@ /** * ToString contract for ObjectModelParameter with type and name. This * contract is used in - * {@link org.nuiton.util.StringUtil#join(java.util.Collection, org.nuiton.util.StringUtil.ToString, java.lang.String, boolean) } + * {@link StringUtil#join(Iterable, StringUtil.ToString, String, boolean)} */ static final StringUtil.ToString<ObjectModelParameter> OBJECT_MODEL_PARAMETER_TO_STRING_TYPE = @@ -459,7 +468,7 @@ /** * ToString contract for ObjectModelParameter with name only. This contract * is used in - * {@link org.nuiton.util.StringUtil#join(java.util.Collection, org.nuiton.util.StringUtil.ToString, java.lang.String, boolean) } + * {@link StringUtil#join(Iterable, StringUtil.ToString, String, boolean)} */ static final StringUtil.ToString<ObjectModelParameter> OBJECT_MODEL_PARAMETER_TO_STRING_NAME = @@ -537,8 +546,8 @@ public static boolean isFirstAttribute(ObjectModelAttribute attr) { boolean firstAttribute = true; if (attr.getReverseAttribute() != null) { - firstAttribute = (attr.getName().compareTo( - attr.getReverseAttribute().getName()) < 0); + firstAttribute = attr.getName().compareTo( + attr.getReverseAttribute().getName()) < 0; } return firstAttribute; } @@ -560,7 +569,7 @@ * @return true si <code>s</code> n'est pas vide */ public static boolean notEmpty(String s) { - return (s != null && !"".equals(s)); + return s != null && !"".equals(s); } /** Modified: trunk/eugene/src/main/java/org/nuiton/eugene/ImportsManager.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/ImportsManager.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/ImportsManager.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene; import java.util.ArrayList; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/ModelReader.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/ModelReader.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/ModelReader.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/MonitorWriter.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/MonitorWriter.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/MonitorWriter.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene; @@ -39,9 +48,9 @@ */ public class MonitorWriter extends FilterWriter { // MonitorWriter - boolean modified = false; + boolean modified; //FIXME : ca sert a quoi duplique cette propriete qui existe dans FilterWriter ? - StringWriter out = null; + StringWriter out; public MonitorWriter(StringWriter out) { super(out); Modified: trunk/eugene/src/main/java/org/nuiton/eugene/PackageValidator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/PackageValidator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/PackageValidator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene; @@ -49,11 +58,8 @@ for (int i = 0; i < packages.length; i++) { packages[i] = packages[i].trim(); if (packages[i].startsWith(localPackageNameDot)) { - if (localPackageNameDot.length() < (packages[i] - .lastIndexOf(".") + 1)) { - return true; - } - return false; + return localPackageNameDot.length() < packages[i] + .lastIndexOf(".") + 1; } } return false; @@ -79,7 +85,7 @@ String[] packages = extraPackages.split(","); for (int i = 0; i < packages.length; i++) { packages[i] = packages[i].trim(); - if ((localPackageName).matches(packages[i]) + if (localPackageName.matches(packages[i]) || packages[i].startsWith(localPackageName)) { return true; } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/Template.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/Template.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/Template.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,29 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene; @@ -77,8 +85,8 @@ protected M model; /** - * Old method from EUGene 1.0.1 used to generate files. Now, you have to use a Reader instead of - * directly use a Template. + * Old method from EUGene 1.0.1 used to generate files. Now, you have to + * use a Reader instead of directly use a Template. * * @param file list of tiles * @param destDir destination folder @@ -92,8 +100,9 @@ /** * @param v override value - * @deprecated since 2.0.0, use a Properties object to add the {@link Template#PROP_OVERWRITE} value - * @see Template#setProperties(java.util.Properties) + * @deprecated since 2.0.0, use a Properties object to add the + * {@link Template#PROP_OVERWRITE} value + * @see Template#setProperties(Properties) */ @Deprecated public void setOverwrite(boolean v) { @@ -111,8 +120,9 @@ /** * @param encoding encoding value - * @deprecated since 2.0.0, use a Properties object to add the {@link Template#PROP_ENCODING} value - * @see Template#setProperties(java.util.Properties) + * @deprecated since 2.0.0, use a Properties object to add the + * {@link Template#PROP_ENCODING} value + * @see Template#setProperties(Properties) */ @Deprecated public void setEncoding(String encoding) { @@ -121,7 +131,7 @@ } public void setProperties(Properties p) { - this.properties = p; + properties = p; } /** @@ -159,21 +169,24 @@ // } } } - return this.generatedPackages; + return generatedPackages; } /** * @param lastModifiedSource lastModifiedSource value - * @deprecated since 2.0.0, use a Properties object to add the {@link Template#PROP_LAST_MODIFIED_SOURCE} value - * @see Template#setProperties(java.util.Properties) + * @deprecated since 2.0.0, use a Properties object to add the + * {@link Template#PROP_LAST_MODIFIED_SOURCE} value + * @see Template#setProperties(Properties) */ @Deprecated public void setLastModifiedSource(long lastModifiedSource) { - properties.setProperty(PROP_LAST_MODIFIED_SOURCE, String.valueOf(lastModifiedSource)); + properties.setProperty(PROP_LAST_MODIFIED_SOURCE, + String.valueOf(lastModifiedSource)); } public long getLastModifiedSource() { - return Long.parseLong(properties.getProperty(PROP_LAST_MODIFIED_SOURCE, "0")); + return Long.parseLong( + properties.getProperty(PROP_LAST_MODIFIED_SOURCE, "0")); } public List<String> getExcludeTemplates() { @@ -197,7 +210,7 @@ } public M getModel() { - return this.model; + return model; } } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/Transformer.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/Transformer.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/Transformer.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene; @@ -42,7 +49,9 @@ public abstract class Transformer<I extends Model, O extends Model> extends Template<I> { /** - * Output generator, to generate files from Output model. Could be an other Transformer. + * Output generator, to generate files from Output model. + * + * Could be an other Transformer. */ protected Template<O> outputTemplate; @@ -62,7 +71,6 @@ protected Properties outputProperties; public Transformer() { - super(); } /** @@ -78,10 +86,10 @@ */ protected void init(I model) { this.model = model; - this.previousTransformer = initPreviousTransformer(); - this.outputTemplate = initOutputTemplate(); - this.outputTemplate.setProperties(getOutputProperties()); - this.outputModel = initOutputModel(); + previousTransformer = initPreviousTransformer(); + outputTemplate = initOutputTemplate(); + outputTemplate.setProperties(getOutputProperties()); + outputModel = initOutputModel(); } protected Transformer<I, I> initPreviousTransformer() { @@ -89,8 +97,8 @@ } /** - * Initialization of the Output generator. Must be override to instanciate the Generator that will - * make the generation of the Output model. + * Initialization of the Output generator. Must be override to instanciate + * the Generator that will make the generation of the Output model. * * @return the output generator * @since 2.0.0 @@ -98,9 +106,12 @@ protected abstract Template<O> initOutputTemplate(); /** - * Initialization of the Output model. Must be override to instanciate and initialize the output model. - * For ObjectModel you can use, ObjectModelBuilder to build easily an empty ObjectModel. + * Initialization of the Output model. Must be override to instanciate + * and initialize the output model. * + * For ObjectModel you can use, ObjectModelBuilder to build easily an + * empty ObjectModel. + * * @return the output model * @since 2.0.0 */ @@ -125,15 +136,16 @@ } public Template<O> getOutputTemplate() { - return this.outputTemplate; + return outputTemplate; } public O getOutputModel() { - return this.outputModel; + return outputModel; } /** - * Old method from previous EUGene 1.0.1 version. Used before creation of ModelReader. + * Old method from previous EUGene 1.0.1 version. Used before creation + * of ModelReader. * * @param file * @param destDir @@ -142,18 +154,22 @@ @Override @Deprecated public void generate(File[] file, File destDir) { - this.outputTemplate = initOutputTemplate(); - this.outputTemplate.setProperties(getOutputProperties()); + outputTemplate = initOutputTemplate(); + outputTemplate.setProperties(getOutputProperties()); getOutputTemplate().generate(file, destDir); } /** - * This method apply the current transformation. You can use an other transformer for previous transformation - * by overriding {@link #initPreviousTransformer} method. In this case, the current transformation will be apply - * on the output model of the previous one. In the simple other case, the current transformation transform the input model - * into an output model. You must override {@link #initOutputModel} and {@link #initOutputTemplate } methods to initialize - * output model and output template to apply (generally a generator). + * This method apply the current transformation. You can use an other + * transformer for previous transformation by overriding + * {@link #initPreviousTransformer} method. In this case, the current + * transformation will be apply on the output model of the previous one. + * In the simple other case, the current transformation transform the + * input model into an output model. You must override + * {@link #initOutputModel} and {@link #initOutputTemplate } methods + * to initialize output model and output template to apply (generally a + * generator). * * @param model input model to transform and generate * @param destDir destination directory to put generated files @@ -177,8 +193,9 @@ } /** - * Transformation method from an input Model. This method also initialize previous transformer, output model - * and output generator with ${@link #init(org.nuiton.eugene.models.Model) } method. + * Transformation method from an input Model. This method also initialize + * previous transformer, output model and output generator with + * ${@link #init(Model) } method. * * @param model input model * @since 2.0.0 @@ -189,8 +206,11 @@ } /** - * Method to override for the transformation. Initialization (PreviousTransformer, OutputModel, OutputGenerator) - * is made before transformation call. This method only transform an input model into an output model. + * Method to override for the transformation. Initialization + * (PreviousTransformer, OutputModel, OutputGenerator) is made before + * transformation call. This method only transform an input model into an + * output model. + * * No generation is done neither outputGenerator call. * * @since 2.0.0 Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/AnnotationsManager.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/AnnotationsManager.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/AnnotationsManager.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,31 @@ +/* + * #%L + * EUGene :: EUGene + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Lesser Public License for more details. + * + * You should have received a copy of the GNU General Lesser Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/lgpl-3.0.html>. + * #L% + */ + package org.nuiton.eugene.java; import org.nuiton.eugene.models.object.ObjectModelElement; @@ -8,7 +36,7 @@ import java.util.Map; /** - * To manage annotations for any {@link org.nuiton.eugene.models.object.ObjectModelElement} of a classifier. + * To manage annotations for any {@link ObjectModelElement} of a classifier. * <p/> * Created: 17 déc. 2009 * @@ -21,10 +49,13 @@ */ public class AnnotationsManager { + private static final String[] EMPTY_STRING_ARRAY = new String[]{}; + protected Map<ObjectModelElement, List<String>> annotations; /** - * Add the {@code annotation} for the given {@code element} of the classifier. + * Add the {@code annotation} for the given {@code element} of + * the classifier. * * @param element the element where to register the annotation * @param annotation the annotation to register @@ -40,7 +71,8 @@ } /** - * Obtain the array of annotations registred for a given element of the classifier. + * Obtain the array of annotations registred for a given element of + * the classifier. * * @param element the element where to search for annotations * @return the annotations for the element (empty arry if none found @@ -48,7 +80,8 @@ public String[] getAnnotations(ObjectModelElement element) { Map<ObjectModelElement, List<String>> map = getAnnotations(); List<String> list = map.get(element); - return list == null ? new String[0] : list.toArray(new String[list.size()]); + return list == null ? EMPTY_STRING_ARRAY : + list.toArray(new String[list.size()]); } protected Map<ObjectModelElement, List<String>> getAnnotations() { Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/AnnotationsManagerExtension.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/AnnotationsManagerExtension.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/AnnotationsManagerExtension.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,31 @@ +/* + * #%L + * EUGene :: EUGene + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Lesser Public License for more details. + * + * You should have received a copy of the GNU General Lesser Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/lgpl-3.0.html>. + * #L% + */ + package org.nuiton.eugene.java; import org.apache.commons.logging.Log; @@ -22,37 +50,44 @@ private static final Log log = LogFactory.getLog(AnnotationsManagerExtension.class); /** - * Extension static used to identify AnnotationsManagerExtension in ObjectModel + * Extension static used to identify AnnotationsManagerExtension in + * ObjectModel. */ public static final String OBJECTMODEL_EXTENSION = "annotations"; /** - * Map of AnotationsManager with key equals to the classifier qualified name associated to - * the AnotationsManager + * Map of AnotationsManager with key equals to the classifier qualified + * name associated to the AnotationsManager */ protected Map<String, AnnotationsManager> managers; + private static final String[] EMPTY_STRING_ARRAY = new String[]{}; + /** - * Get the registred annotations for the given {@code element} in the given {@code classifier}. + * Get the registred annotations for the given {@code element} in the + * given {@code classifier}. * * <b>Note:</b> The method always returns a {@code none null} value, but - * an empty array when no annotation when no annotation found for the element. + * an empty array when no annotation when no annotation found for the + * element. * * @param classifier the classifier where is the element * @param element the element on which searching annotations * @return the array of annotation registred or an empty array if none. */ - public String[] getAnnotations(ObjectModelClassifier classifier, ObjectModelElement element) { + public String[] getAnnotations(ObjectModelClassifier classifier, + ObjectModelElement element) { AnnotationsManager annotationsManager = getManager(classifier); String[] result = null; if (annotationsManager != null) { result = annotationsManager.getAnnotations(element); } - return result == null ? new String[]{} : result; + return result == null ? EMPTY_STRING_ARRAY : result; } /** - * Get the AnotationsManager associated to the classifier. If not exist, it will be created. + * Get the AnotationsManager associated to the classifier. If not exist, + * it will be created. * * @param classifier reference for the AnotationsManager * @return the annotationsManager associated to the classifier (never null) Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/ConstantsManager.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/ConstantsManager.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/ConstantsManager.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% * Copyright (C) 2004 - 2010 CodeLutin - * + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.java; import org.nuiton.eugene.GeneratorUtil; @@ -28,7 +36,7 @@ /** * Manager of constant names. * - * @author tchemit < chemit@codelutin.com > + * @author tchemit <chemit@codelutin.com> * @since 2.3 */ public class ConstantsManager { Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/ConstantsManagerExtension.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/ConstantsManagerExtension.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/ConstantsManagerExtension.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,33 +1,41 @@ /* - * *##% + * #%L * EUGene :: EUGene + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% * Copyright (C) 2004 - 2010 CodeLutin - * + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.java; /** - * @author tchemit < chemit@codelutin.com > + * @author tchemit <chemit@codelutin.com> * @since 2.3 */ public class ConstantsManagerExtension { /** - * Extension static used to identify {@link ConstantsManagerExtension} in + * Extension static used to identify {@code ConstantsManagerExtension} in * ObjectModel */ public static final String OBJECTMODEL_EXTENSION = "constants"; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/ImportsManager.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/ImportsManager.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/ImportsManager.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.java; import java.util.ArrayList; @@ -158,7 +166,8 @@ state = State.READING; List<String> result = new ArrayList<String>(); for (String fqn : imports.values()) { - if (!(fqn.lastIndexOf(".") == packageName.length() && fqn.startsWith(packageName + "."))) { + if (!(fqn.lastIndexOf(".") == packageName.length() && + fqn.startsWith(packageName + "."))) { result.add(fqn); } } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/ImportsManagerExtension.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/ImportsManagerExtension.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/ImportsManagerExtension.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.java; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/JavaBuilder.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/JavaBuilder.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/JavaBuilder.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.java; import java.util.Arrays; @@ -28,7 +36,6 @@ import org.apache.commons.logging.LogFactory; import org.nuiton.eugene.GeneratorUtil; import org.nuiton.eugene.models.object.*; -import org.nuiton.eugene.models.object.ObjectModelModifier; import org.nuiton.eugene.models.object.xml.*; /** @@ -70,17 +77,17 @@ @SuppressWarnings("unchecked") public JavaBuilder(String modelName) { - this.modelBuilder = new ObjectModelBuilder(modelName); + modelBuilder = new ObjectModelBuilder(modelName); - this.importsManagerExtension = getModel().getExtension( + importsManagerExtension = getModel().getExtension( ImportsManagerExtension.OBJECTMODEL_EXTENSION, ImportsManagerExtension.class); - this.annotationsManagerExtension = getModel().getExtension( + annotationsManagerExtension = getModel().getExtension( AnnotationsManagerExtension.OBJECTMODEL_EXTENSION, AnnotationsManagerExtension.class); - this.constanssManagerExtension = getModel().getExtension( + constanssManagerExtension = getModel().getExtension( ConstantsManagerExtension.OBJECTMODEL_EXTENSION, ConstantsManagerExtension.class); } @@ -91,7 +98,7 @@ * @return an ObjectModel */ public ObjectModel getModel() { - return this.modelBuilder.getModel(); + return modelBuilder.getModel(); } public void setDocumentation(ObjectModelElement element, @@ -100,19 +107,19 @@ } /** - * Add an import to a classifier. Imports are automatic for lots of JavaBuilder's methods except body - * code of operations. + * Add an import to a classifier. Imports are automatic for lots of + * JavaBuilder's methods except body code of operations. * <pre> * You can have some complex imports like : * - new java.util.List<org.chorem.bonzoms.Role>() - * --> two imports 'java.util.List' and 'org.chorem.bonzoms.Role' + * --> two imports 'java.util.List' and 'org.chorem.bonzoms.Role' * - java.util.Collection<T extends org.nuiton.topia.TopiaEntity> - * --> two imports 'java.util.Collection' and 'org.nuiton.topia.TopiaEntity' + * --> two imports 'java.util.Collection' and 'org.nuiton.topia.TopiaEntity' * </pre> * * @param classifier where the imports will be added. * @param imports to add - * @see org.nuiton.eugene.GeneratorUtil#getTypesList(java.lang.String) + * @see GeneratorUtil#getTypesList(String) */ public void addImport(ObjectModelClassifier classifier, String imports) { if (imports == null) { @@ -172,7 +179,7 @@ * @param name * @param packageName package's name of the class to create * @return a new ObjectModelClass - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#createClass(java.lang.String, java.lang.String,org.nuiton.eugene.models.object.ObjectModelModifier...) + * @see ObjectModelBuilder#createClass(String, String, ObjectModelModifier...) */ public ObjectModelClass createClass(String name, String packageName) { return modelBuilder.createClass(name, packageName); @@ -184,7 +191,7 @@ * @param name * @param packageName package's name of the class to create * @return a new ObjectModelClass - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#createClass(java.lang.String,java.lang.String, org.nuiton.eugene.models.object.ObjectModelModifier...) + * @see ObjectModelBuilder#createClass(String, String, ObjectModelModifier...) */ public ObjectModelClass createAbstractClass(String name, String packageName) { @@ -198,7 +205,7 @@ * @param name * @param packageName package's name of the interface to create * @return a new ObjectModelInterface - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#createInterface(java.lang.String, java.lang.String) + * @see ObjectModelBuilder#createInterface(String, String) */ public ObjectModelInterface createInterface(String name, String packageName) { @@ -218,20 +225,21 @@ } /** - * Set the superclass of an other class. Only one superclass can be set to the class. + * Set the superclass of an other class. Only one superclass can be set + * to the class. * IMPORTS superclassQualifiedName. * * @param classifier * @param superclassQualifiedName - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#addInterface( - *org.nuiton.eugene.models.object.ObjectModelClassifier, java.lang.String) + * @see ObjectModelBuilder#addInterface( + *ObjectModelClassifier, String) */ public void setSuperClass(ObjectModelClass classifier, String superclassQualifiedName) { ObjectModelClassImpl impl = (ObjectModelClassImpl) classifier; impl.clearSuperclasses(); // suppress all existing superclass: only one can be set for java modelBuilder.addSuperclass(impl, superclassQualifiedName); - this.addImport(classifier, superclassQualifiedName); + addImport(classifier, superclassQualifiedName); } /** @@ -240,13 +248,13 @@ * * @param classifier * @param interfaceQualifiedName - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#addInterface( - *org.nuiton.eugene.models.object.ObjectModelClassifier, java.lang.String) + * @see ObjectModelBuilder#addInterface( + *ObjectModelClassifier, String) */ public void addInterface(ObjectModelClassifier classifier, String interfaceQualifiedName) { modelBuilder.addInterface(classifier, interfaceQualifiedName); - this.addImport(classifier, interfaceQualifiedName); + addImport(classifier, interfaceQualifiedName); } /** @@ -259,14 +267,14 @@ * @param value * @param modifiers * @return a new ObjectModelAttribute - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#addAttribute(org.nuiton.eugene.models.object.ObjectModelClassifier, java.lang.String,java.lang.String, java.lang.String, org.nuiton.eugene.models.object.ObjectModelModifier...) + * @see ObjectModelBuilder#addAttribute(ObjectModelClassifier, String, String, String, ObjectModelModifier...) */ public ObjectModelAttribute addAttribute(ObjectModelClassifier classifier, String name, String type, String value, ObjectModelModifier... modifiers) { - this.addImport(classifier, type); + addImport(classifier, type); // ANO#474 FD-20100408 : problem with import from defaultValue, will // not be supported from version 2.0.1 //this.addImport(classifier, value); @@ -275,7 +283,8 @@ } /** - * Add a new constant to a classifier. A constant is static and final and have a value. + * Add a new constant to a classifier. A constant is static and final + * and have a value. * IMPORTS type, value. * * @param classifier @@ -303,7 +312,8 @@ } /** - * Add a new attribute to a classifier with no default value. Default visibility is set to PROTECTED. + * Add a new attribute to a classifier with no default value. + * Default visibility is set to PROTECTED. * IMPORTS type. * * @param classifier @@ -362,13 +372,13 @@ * @param type * @param modifiers * @return a new ObjectModelOperation - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#addOperation(org.nuiton.eugene.models.object.ObjectModelClassifier, java.lang.String,java.lang.String, org.nuiton.eugene.models.object.ObjectModelModifier...) + * @see ObjectModelBuilder#addOperation(ObjectModelClassifier, String, String, ObjectModelModifier...) */ public ObjectModelOperation addOperation(ObjectModelClassifier classifier, String name, String type, ObjectModelModifier... modifiers) { - this.addImport(classifier, type); + addImport(classifier, type); return modelBuilder.addOperation(classifier, name, type, modifiers); } @@ -378,7 +388,7 @@ * @param classifier * @param modifiers * @return a new ObjectModelOperation - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#addOperation(org.nuiton.eugene.models.object.ObjectModelClassifier, java.lang.String,java.lang.String, org.nuiton.eugene.models.object.ObjectModelModifier...) + * @see ObjectModelBuilder#addOperation(ObjectModelClassifier, String, String, ObjectModelModifier...) */ public ObjectModelOperation addBlock(ObjectModelClassifier classifier, ObjectModelModifier... modifiers) { @@ -417,13 +427,13 @@ * @param type * @param name * @return a new ObjectModelParameter - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#addParameter( - *org.nuiton.eugene.models.object.ObjectModelOperation, java.lang.String, java.lang.String) + * @see ObjectModelBuilder#addParameter( + *ObjectModelOperation, String, String) */ public ObjectModelParameter addParameter(ObjectModelOperation operation, String type, String name) { - this.addImport((ObjectModelClassifier) operation.getDeclaringElement(), + addImport((ObjectModelClassifier) operation.getDeclaringElement(), type); return modelBuilder.addParameter(operation, type, name); } @@ -433,11 +443,11 @@ * * @param operation * @param exception - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#addException( - *org.nuiton.eugene.models.object.ObjectModelOperation, java.lang.String) + * @see ObjectModelBuilder#addException( + *ObjectModelOperation, String) */ public void addException(ObjectModelOperation operation, String exception) { - this.addImport((ObjectModelClassifier) operation.getDeclaringElement(), + addImport((ObjectModelClassifier) operation.getDeclaringElement(), exception); modelBuilder.addException(operation, exception); } @@ -448,8 +458,8 @@ * @param operation * @param body * @throws IllegalArgumentException if operation is abstract - * @see org.nuiton.eugene.models.object.ObjectModelBuilder#setOperationBody( - *org.nuiton.eugene.models.object.ObjectModelOperation, java.lang.String) + * @see ObjectModelBuilder#setOperationBody( + *ObjectModelOperation, String) */ public void setOperationBody(ObjectModelOperation operation, String body) throws IllegalArgumentException { Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/JavaGenerator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/JavaGenerator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/JavaGenerator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.java; @@ -102,7 +109,7 @@ preparePrefix(clazz); // Imports, package et documentation - this.generateHeader(output, clazz); + generateHeader(output, clazz); String abstractStr = clazz.isAbstract() ? " abstract " : " "; String className = clazz.getName(); @@ -271,8 +278,8 @@ }*/ } } - this.generateAttributes(output, enumz, enumz.getAttributes()); - this.generateOperations(output, enumz, enumz.getOperations()); + generateAttributes(output, enumz, enumz.getAttributes()); + generateOperations(output, enumz, enumz.getOperations()); /*{ <%=prefix%>} //<%=enumzName%> }*/ @@ -301,7 +308,6 @@ generateFromEnum(output, (ObjectModelEnumeration) innerClassifier); innerLevel--; - continue; } } } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/ObjectModelTransformerToJava.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/ObjectModelTransformerToJava.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/ObjectModelTransformerToJava.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.java; import org.apache.commons.logging.Log; @@ -38,7 +46,8 @@ */ public abstract class ObjectModelTransformerToJava extends ObjectModelTransformer<ObjectModel> { - private static final Log log = LogFactory.getLog(ObjectModelTransformerToJava.class); + private static final Log log = + LogFactory.getLog(ObjectModelTransformerToJava.class); /** * internal builder */ @@ -55,7 +64,7 @@ if (log.isDebugEnabled()) { log.debug("inputModelName = " + getModel().getName()); } - this.builder = new JavaBuilder(getModel().getName()); + builder = new JavaBuilder(getModel().getName()); return builder.getModel(); } @@ -65,15 +74,20 @@ log.debug("classes : " + getOutputModel().getClasses().size()); for (ObjectModelClass clazz : getOutputModel().getClasses()) { log.debug(" class : " + clazz.getQualifiedName()); - ImportsManager manager = getOutputModel().getExtension(clazz.getQualifiedName(), ImportsManager.class); - for (String imports : manager.getImports(clazz.getPackageName())) { + ImportsManager manager = getOutputModel().getExtension( + clazz.getQualifiedName(), ImportsManager.class + ); + for (String imports : + manager.getImports(clazz.getPackageName())) { log.debug(" import : " + imports); } for (ObjectModelAttribute attribute : clazz.getAttributes()) { - log.debug(" attribute : " + attribute.getType() + " " + attribute.getName()); + log.debug(" attribute : " + attribute.getType() + + " " + attribute.getName()); } for (ObjectModelOperation operation : clazz.getOperations()) { - log.debug(" operation : " + operation.getReturnType() + " " + operation.getName()); + log.debug(" operation : " + operation.getReturnType() + + " " + operation.getName()); } } } @@ -83,43 +97,53 @@ return builder.createClass(name, packageName); } - public ObjectModelEnumeration createEnumeration(String name, String packageName) { + public ObjectModelEnumeration createEnumeration(String name, + String packageName) { return builder.createEnumeration(name, packageName); } - protected ObjectModelClass createAbstractClass(String name, String packageName) { + protected ObjectModelClass createAbstractClass(String name, + String packageName) { return builder.createAbstractClass(name, packageName); } - protected ObjectModelInterface createInterface(String name, String packageName) { + protected ObjectModelInterface createInterface(String name, + String packageName) { return builder.createInterface(name, packageName); } - protected void setSuperClass(ObjectModelClass classifier, String superclassQualifiedName) { + protected void setSuperClass(ObjectModelClass classifier, + String superclassQualifiedName) { builder.setSuperClass(classifier, superclassQualifiedName); } - protected void setSuperClass(ObjectModelClass classifier, Class<?> superclassQualifiedName) { + protected void setSuperClass(ObjectModelClass classifier, + Class<?> superclassQualifiedName) { builder.setSuperClass(classifier, superclassQualifiedName.getName()); } - protected void addInterface(ObjectModelClassifier classifier, String interfaceQualifiedName) { + protected void addInterface(ObjectModelClassifier classifier, + String interfaceQualifiedName) { builder.addInterface(classifier, interfaceQualifiedName); } - protected void addInterface(ObjectModelClassifier classifier, Class<?> interfaceQualifiedName) { + protected void addInterface(ObjectModelClassifier classifier, + Class<?> interfaceQualifiedName) { builder.addInterface(classifier, interfaceQualifiedName.getName()); } - protected void addImport(ObjectModelClassifier classifier, String imports) { + protected void addImport(ObjectModelClassifier classifier, + String imports) { builder.addImport(classifier, imports); } - protected void addImport(ObjectModelClassifier classifier, ObjectModelClass imports) { + protected void addImport(ObjectModelClassifier classifier, + ObjectModelClass imports) { builder.addImport(classifier, imports.getPackageName() + "." + imports.getName()); } - protected void addImport(ObjectModelClassifier classifier, Class<?> imports) { + protected void addImport(ObjectModelClassifier classifier, + Class<?> imports) { builder.addImport(classifier, imports.getName()); } @@ -127,51 +151,80 @@ return builder.getConstantName(propertyName); } - protected ObjectModelAttribute addConstant(ObjectModelClassifier classifier, String name, String type, String value, - ObjectModelModifier visibility) throws IllegalArgumentException { + protected ObjectModelAttribute addConstant( + ObjectModelClassifier classifier, + String name, + String type, + String value, + ObjectModelModifier visibility) throws IllegalArgumentException { return builder.addConstant(classifier, name, type, value, visibility); } - protected ObjectModelAttribute addConstant(ObjectModelClassifier classifier, String name, Class<?> type, String value, - ObjectModelModifier visibility) throws IllegalArgumentException { + protected ObjectModelAttribute addConstant( + ObjectModelClassifier classifier, + String name, + Class<?> type, + String value, + ObjectModelModifier visibility) throws IllegalArgumentException { return builder.addConstant(classifier, name, type.getName(), value, visibility); } - protected ObjectModelAttribute addAttribute(ObjectModelClassifier classifier, String name, String type, String value, - ObjectModelModifier... modifiers) { + protected ObjectModelAttribute addAttribute( + ObjectModelClassifier classifier, + String name, + String type, + String value, + ObjectModelModifier... modifiers) { return builder.addAttribute(classifier, name, type, value, modifiers); } - protected ObjectModelAttribute addAttribute(ObjectModelClassifier classifier, String name, Class<?> type, String value, - ObjectModelModifier... modifiers) { + protected ObjectModelAttribute addAttribute( + ObjectModelClassifier classifier, + String name, + Class<?> type, + String value, + ObjectModelModifier... modifiers) { return builder.addAttribute(classifier, name, type.getName(), value, modifiers); } - protected ObjectModelAttribute addAttribute(ObjectModelClassifier classifier, ObjectModelAttribute attribute) { + protected ObjectModelAttribute addAttribute( + ObjectModelClassifier classifier, + ObjectModelAttribute attribute) { return builder.addAttribute(classifier, attribute); } - public ObjectModelAttribute addAttribute(ObjectModelClassifier classifier, String name, String type) { + public ObjectModelAttribute addAttribute( + ObjectModelClassifier classifier, + String name, + String type) { return builder.addAttribute(classifier, name, type); } - protected ObjectModelOperation addConstructor(ObjectModelClass clazz, ObjectModelModifier visibility) + protected ObjectModelOperation addConstructor( + ObjectModelClass clazz, ObjectModelModifier visibility) throws IllegalArgumentException { return builder.addConstructor(clazz, visibility); } - protected ObjectModelOperation addConstructor(ObjectModelEnumeration clazz, ObjectModelModifier visibility) + protected ObjectModelOperation addConstructor( + ObjectModelEnumeration clazz, ObjectModelModifier visibility) throws IllegalArgumentException { return builder.addConstructor(clazz, visibility); } - protected ObjectModelOperation addOperation(ObjectModelClassifier classifier, String name, String type, - ObjectModelModifier... modifiers) { + protected ObjectModelOperation addOperation( + ObjectModelClassifier classifier, + String name, + String type, + ObjectModelModifier... modifiers) { return builder.addOperation(classifier, name, type, modifiers); } - protected ObjectModelOperation addOperation(ObjectModelClassifier classifier, String name, Class<?> type, - ObjectModelModifier... modifiers) { + protected ObjectModelOperation addOperation( + ObjectModelClassifier classifier, + String name, + Class<?> type, + ObjectModelModifier... modifiers) { return builder.addOperation(classifier, name, type == null ? null : type.getName(), modifiers); } @@ -179,40 +232,58 @@ builder.addLiteral(classifier, name); } - protected ObjectModelParameter addParameter(ObjectModelOperation operation, String type, String name) { + protected ObjectModelParameter addParameter( + ObjectModelOperation operation, + String type, + String name) { return builder.addParameter(operation, type, name); } - protected ObjectModelParameter addParameter(ObjectModelOperation operation, Class<?> type, String name) { + protected ObjectModelParameter addParameter( + ObjectModelOperation operation, + Class<?> type, + String name) { return builder.addParameter(operation, type.getName(), name); } - protected void addException(ObjectModelOperation operation, String exception) { + protected void addException( + ObjectModelOperation operation, + String exception) { builder.addException(operation, exception); } - protected void addException(ObjectModelOperation operation, Class<?> exception) { + protected void addException( + ObjectModelOperation operation, + Class<?> exception) { builder.addException(operation, exception.getName()); } - protected void setOperationBody(ObjectModelOperation operation, String body) + protected void setOperationBody(ObjectModelOperation operation, + String body) throws IllegalArgumentException { builder.setOperationBody(operation, body); } - public ObjectModelClassifier addInnerClassifier(ObjectModelClass clazz, ObjectModelType type, String name) throws IllegalArgumentException { + public ObjectModelClassifier addInnerClassifier( + ObjectModelClass clazz, + ObjectModelType type, + String name) throws IllegalArgumentException { return builder.addInnerClassifier(clazz, type, name); } - public void setDocumentation(ObjectModelElement element, String documentation) { + public void setDocumentation(ObjectModelElement element, + String documentation) { builder.setDocumentation(element, documentation); } - public void addAnnotation(ObjectModelClassifier classifier, ObjectModelElement element, String annotation) { + public void addAnnotation(ObjectModelClassifier classifier, + ObjectModelElement element, + String annotation) { builder.addAnnotation(classifier, element, annotation); } - public ObjectModelOperation addBlock(ObjectModelClassifier classifier, ObjectModelModifier... modifiers) { + public ObjectModelOperation addBlock(ObjectModelClassifier classifier, + ObjectModelModifier... modifiers) { return builder.addBlock(classifier, modifiers); } } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/java/package-info.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/java/package-info.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/java/package-info.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + /** * Eugene java package : all specific class for Java generation. * <pre> Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/Model.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/Model.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/Model.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,32 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ + package org.nuiton.eugene.models; import java.util.Map; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModel.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModel.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModel.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,32 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ + package org.nuiton.eugene.models.object; import java.util.Collection; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelAssociationClass.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelAssociationClass.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelAssociationClass.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; @@ -39,7 +48,7 @@ * * @return a List containing all participants attributes for this association class. */ - public List<ObjectModelAttribute> getParticipantsAttributes(); + List<ObjectModelAttribute> getParticipantsAttributes(); /** * Returns all participants (that is association ends) classifiers for this association class. @@ -47,6 +56,6 @@ * * @return a List containing all participants classifiers for this association class. */ - public List<ObjectModelClassifier> getParticipantsClassifiers(); + List<ObjectModelClassifier> getParticipantsClassifiers(); } //ObjectModelAssociationClass Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelAttribute.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelAttribute.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelAttribute.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelBuilder.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelBuilder.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelBuilder.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,24 +1,32 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.models.object; import org.nuiton.eugene.models.object.xml.*; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelClass.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelClass.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelClass.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; @@ -38,16 +47,12 @@ /** * Returns all parent classes for this class. - * @see ObjectModelClass - * * @return a Collection containing all parent ObjectModelClass for this class. */ Collection<ObjectModelClass> getSuperclasses(); /** * Returns all inner classes for this class. - * @see ObjectModelClass - * * @return a Collection containing all inner ObjectModelClass for this class. */ Collection<ObjectModelClassifier> getInnerClassifiers(); @@ -62,16 +67,12 @@ /** * Returns all known direct specialized classes for this class. - * @see ObjectModelClass - * * @return a Collection containing all known direct specialized ObjectModelClass for this class. */ Collection<ObjectModelClass> getSpecialisations(); /** * Returns all known direct specialized classes for this class for the specified discriminator. - * @see ObjectModelClass - * * @param discriminator discriminator to get specialisations * @return a Collection containing all known direct specialized ObjectModelClass for this class for the specified discriminator. */ Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelClassifier.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelClassifier.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelClassifier.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; @@ -38,7 +47,7 @@ * * @return the package name of this classifier. */ - public String getPackageName(); + String getPackageName(); /** * Returns the qualified name of this classifier. @@ -46,16 +55,14 @@ * * @return the qualified name of this classifier. */ - public String getQualifiedName(); + String getQualifiedName(); /** * Returns all parent interfaces for this classifier. * - * @see ObjectModelClassifier - * * @return a Collection containing all parent ObjectModelInterface for this classifier. */ - public Collection<ObjectModelInterface> getInterfaces(); + Collection<ObjectModelInterface> getInterfaces(); /** * Returns all operations defined on this classifier. @@ -65,7 +72,7 @@ * * @see ObjectModelOperation */ - public Collection<ObjectModelOperation> getOperations(String name); + Collection<ObjectModelOperation> getOperations(String name); /** * Returns all operations defined on this classifier. @@ -73,7 +80,7 @@ * * @return a Collection containing all ObjectModelOperation for this classifier. */ - public Collection<ObjectModelOperation> getOperations(); + Collection<ObjectModelOperation> getOperations(); /** * Returns all operations defined on all interfaces implemented by this @@ -82,7 +89,7 @@ * are add to list. * @return a Collection of ObjectModelOperation */ - public Collection<ObjectModelOperation> getAllInterfaceOperations( + Collection<ObjectModelOperation> getAllInterfaceOperations( boolean distinct); /** @@ -94,7 +101,7 @@ * are add to list. * @return a Collection of ObjectModelOperation */ - public Collection<ObjectModelOperation> getAllOtherOperations( + Collection<ObjectModelOperation> getAllOtherOperations( boolean distinct); /** @@ -103,7 +110,7 @@ * * @return a Collection containing all ObjectModelAttribute for this class. */ - public Collection<ObjectModelAttribute> getAttributes(); + Collection<ObjectModelAttribute> getAttributes(); /** * Returns the attribute corresponding to the given name, or null if the class contains no attribute for this name. @@ -111,35 +118,35 @@ * @param attributeName attribute name * @return the ObjectModelAttribute of the found attribute, or null if the class contains no attribute for this name. */ - public ObjectModelAttribute getAttribute(String attributeName); + ObjectModelAttribute getAttribute(String attributeName); /** * Returns all attributes defined on all interfaces implemented by this * classifier, directly or indirectly. * @return a Collection of ObjectModelAttribute */ - public Collection<ObjectModelAttribute> getAllInterfaceAttributes(); + Collection<ObjectModelAttribute> getAllInterfaceAttributes(); /** * Returns all attributes defined on all super class extended by this * classifier, directly or indirectly. * @return a Collection of ObjectModelAttribute */ - public Collection<ObjectModelAttribute> getAllOtherAttributes(); + Collection<ObjectModelAttribute> getAllOtherAttributes(); /** * Returns all dependencies of this client classifier * * @return a Collection of ObjectModelDependency */ - public Collection<ObjectModelDependency> getDependencies(); + Collection<ObjectModelDependency> getDependencies(); /** * Return a dependency identifier by her name * @param name of the dependency * @return the dependency */ - public ObjectModelDependency getDependency(String name); + ObjectModelDependency getDependency(String name); /** * Returns whether this classifier is a class or not @@ -147,7 +154,7 @@ * * @return a boolean indicating whether this classifier is a class or not. */ - public boolean isClass(); + boolean isClass(); /** * Returns whether this classifier is an interface or not @@ -155,7 +162,7 @@ * * @return a boolean indicating whether this classifier is an interface or not. */ - public boolean isInterface(); + boolean isInterface(); /** * Returns whether this classifier is an enumeration or not @@ -163,7 +170,7 @@ * * @return a boolean indicating whether this classifier is an enumeration or not. */ - public boolean isEnum(); + boolean isEnum(); /** * Returns whether this class is inner an other class or not. Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelDependency.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelDependency.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelDependency.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; @@ -39,19 +48,19 @@ * * @return a String */ - public String getName(); + String getName(); /** * Supplier classifier of the dependency * * @return an ObjectModelClassifier */ - public ObjectModelClassifier getSupplier(); + ObjectModelClassifier getSupplier(); /** * Client classifier of the dependency * * @return an ObjectModelClassifier */ - public ObjectModelClassifier getClient(); + ObjectModelClassifier getClient(); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelElement.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelElement.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelElement.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; @@ -40,28 +49,28 @@ * * @return the name of this element. */ - public String getName(); + String getName(); /** * Returns the element in which this element is defined, or null if there's none. * * @return the ObjectModelElement in which this element is defined, or null if there's none. */ - public ObjectModelElement getDeclaringElement(); + ObjectModelElement getDeclaringElement(); /** * Returns the whole documentation associated with this element (description + source documentation). * * @return the whole documentation associated with this element. */ - public String getDocumentation(); + String getDocumentation(); /** * Returns the description associated with this element. * * @return the description associated with this element. */ - public String getDescription(); + String getDescription(); /** * Returns the source documentation part associated with this element. @@ -70,14 +79,14 @@ * * @return the source documentation part associated with this element. */ - public String getSourceDocumentation(); + String getSourceDocumentation(); /** * Returns the stereotypes names associated with this element. * * @return a Collection containing all stereotypes names associated with this element as String. */ - public Collection<String> getStereotypes(); + Collection<String> getStereotypes(); /** * Returns whether this element has a stereotype corresponding to the given name, or not. @@ -85,7 +94,7 @@ * @param stereotypeName stereotype name * @return a boolean indicating whether this element has a stereotype corresponding to the given name, or not. */ - public boolean hasStereotype(String stereotypeName); + boolean hasStereotype(String stereotypeName); /** * Returns the tagValues associated with this element. @@ -93,7 +102,7 @@ * * @return a Map containing all tagValues associated with this element */ - public Map<String, String> getTagValues(); + Map<String, String> getTagValues(); /** * Returns the tagValue corresponding to the given name, or null if the element has no associated tagValue for this name. @@ -101,7 +110,7 @@ * @param tagValue tag value name * @return the value of the found tagValue, or null if the element has no associated tagValue for this name. */ - public String getTagValue(String tagValue); + String getTagValue(String tagValue); /** * Returns whether this element has a tagValue corresponding to the given name, or not. @@ -109,7 +118,7 @@ * @param tagValue tag value name * @return a boolean indicating whether this element has a tagValue corresponding to the given name, or not. */ - public boolean hasTagValue(String tagValue); + boolean hasTagValue(String tagValue); /** * Return if this element has static declaration, only valid when @@ -117,13 +126,13 @@ * to have static innerClass (from XMI 1.2 and 2.1). * @return true if element is static */ - public boolean isStatic(); + boolean isStatic(); /** * Returns all comments lied to this particular model element * * @return a List containing all comments for this element as Strings. */ - public List<String> getComments(); + List<String> getComments(); } //ObjectModelElement Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelEnumeration.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelEnumeration.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelEnumeration.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; @@ -50,7 +59,7 @@ * * @return a Collection of String */ - public Collection<String> getLiterals(); + Collection<String> getLiterals(); // /** // * Returns all operations defined on this en enumeration. Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelGenerator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelGenerator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelGenerator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; @@ -71,7 +80,6 @@ private static Log log = LogFactory.getLog(ObjectModelGenerator.class); public ObjectModelGenerator() { - super(); } public ObjectModelGenerator(AbstractGenerator<ObjectModel> parent) { Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelInterface.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelInterface.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelInterface.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelModifier.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelModifier.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelModifier.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,24 +1,32 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.models.object; /** Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelOperation.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelOperation.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelOperation.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; @@ -42,7 +51,7 @@ * * @return the return type of this operation. */ - public String getReturnType(); + String getReturnType(); /** * Returns the visibility of this operation. @@ -50,14 +59,14 @@ * * @return the visibility of this operation. */ - public String getVisibility(); + String getVisibility(); /** * Returns whether this operation is abstract or not. * * @return a boolean indicating whether this operation is abstract or not. */ - public boolean isAbstract(); + boolean isAbstract(); /** * Returns all parameters defined on this operation. @@ -65,18 +74,18 @@ * * @return a Collection containing all parameters defined on this operation. */ - public Collection<ObjectModelParameter> getParameters(); + Collection<ObjectModelParameter> getParameters(); /** * Return the return parameter of the operation * @return an ObjectModelParameter representing the return parameter */ - public ObjectModelParameter getReturnParameter(); + ObjectModelParameter getReturnParameter(); - /** - * In implementation you must write a good equals method - */ - public boolean equals(Object o); +// /** +// * In implementation you must write a good equals method +// */ +// boolean equals(Object o); /** * Returns all exception qualified names thrown by this operation @@ -84,12 +93,12 @@ * * @return a Set containing the exceptions strings */ - public Set<String> getExceptions(); + Set<String> getExceptions(); /** * Return body of the operation (source code) * @return body of the operation (source code) */ - public String getBodyCode(); + String getBodyCode(); } //ObjectModelOperation Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelParameter.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelParameter.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelParameter.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelReader.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelReader.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelReader.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,24 +1,32 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.models.object; import java.io.File; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelTransformer.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelTransformer.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelTransformer.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.models.object; import org.nuiton.eugene.Transformer; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelType.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelType.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelType.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelVisibility.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelVisibility.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/ObjectModelVisibility.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.models.object; /** Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/AttributeNamesValidator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/AttributeNamesValidator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/AttributeNamesValidator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.validator; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/ClassNamesValidator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/ClassNamesValidator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/ClassNamesValidator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.validator; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/NameBasedValidator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/NameBasedValidator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/NameBasedValidator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.validator; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/ObjectModelValidator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/ObjectModelValidator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/validator/ObjectModelValidator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,26 +1,34 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.validator; import java.util.ArrayList; -import java.util.Iterator; import java.util.List; import org.nuiton.eugene.models.object.ObjectModel; @@ -78,25 +86,21 @@ //On recréé une nouvelle liste errors = new ArrayList<String>(); } - boolean isValid = validateModel(this.model); - for (Iterator<ObjectModelClassifier> classifiers = model.getClassifiers().iterator(); - classifiers.hasNext(); ){ - ObjectModelClassifier classifier = classifiers.next(); + boolean isValid = validateModel(model); + for (ObjectModelClassifier classifier : model.getClassifiers()) { isValid &= validateClassifier(classifier); if (classifier instanceof ObjectModelInterface) { - isValid &= validateInterface((ObjectModelInterface)classifier); + isValid &= validateInterface((ObjectModelInterface) classifier); } if (classifier instanceof ObjectModelClass) { - ObjectModelClass clazz = (ObjectModelClass)classifier; + ObjectModelClass clazz = (ObjectModelClass) classifier; isValid &= validateClass(clazz); - for (Iterator<ObjectModelAttribute> attributes = clazz.getAttributes().iterator(); - attributes.hasNext(); ) { - isValid &= validateAttribute(attributes.next()); + for (ObjectModelAttribute objectModelAttribute : clazz.getAttributes()) { + isValid &= validateAttribute(objectModelAttribute); } } - for (Iterator<ObjectModelOperation> operations = classifier.getOperations().iterator(); - operations.hasNext(); ) { - isValid &= validateOperation(operations.next()); + for (ObjectModelOperation objectModelOperation : classifier.getOperations()) { + isValid &= validateOperation(objectModelOperation); } } return isValid; @@ -136,7 +140,7 @@ ObjectModelClassifier classifier = (ObjectModelClassifier) onElement; elementString = classifier.getQualifiedName(); } - this.errors.add("[" + elementString + "] " + reason); + errors.add("[" + elementString + "] " + reason); } } //ObjectModelValidator Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/DigesterObjectModelRuleSet.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/DigesterObjectModelRuleSet.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/DigesterObjectModelRuleSet.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -49,21 +58,17 @@ */ public class DigesterObjectModelRuleSet extends RuleSetBase { - protected String prefix = null; + protected String prefix; public DigesterObjectModelRuleSet() { this(""); } public DigesterObjectModelRuleSet(String prefix) { - super(); this.prefix = prefix; - this.namespaceURI = "http://www.codelutin.org/lutingenerator/objectModel"; + namespaceURI = "http://www.codelutin.org/lutingenerator/objectModel"; } - /* (non-Javadoc) - * @see org.apache.commons.digester.RuleSetBase#addRuleInstances(org.apache.commons.digester.Digester) - */ @Override public void addRuleInstances(Digester d) { Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ExternalCacheExtension.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ExternalCacheExtension.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ExternalCacheExtension.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.models.object.xml; @@ -40,45 +47,54 @@ */ public class ExternalCacheExtension { - private static final Log log = LogFactory.getLog(ExternalCacheExtension.class); + private static final Log log = + LogFactory.getLog(ExternalCacheExtension.class); public static final String OBJECTMODEL_EXTENSION = "externalClassifiers"; protected Map<String, ObjectModelClassifierImpl> cache; public ExternalCacheExtension() { - this.cache = new HashMap<String, ObjectModelClassifierImpl>(); + cache = new HashMap<String, ObjectModelClassifierImpl>(); } @SuppressWarnings("unchecked") - public <C extends ObjectModelClassifierImpl> C getCache(ObjectModelImplRef reference, Class<C> classifierClass) + public <C extends ObjectModelClassifierImpl> C getCache( + ObjectModelImplRef reference, Class<C> classifierClass) throws RuntimeException { ObjectModelClassifierImpl classifier = cache.get(reference.getName()); C result; - if (classifier != null && !classifierClass.isAssignableFrom(classifier.getClass())) { - throw new ClassCastException("Invalid cast for " + classifierClass.getName()); + if (classifier != null && + !classifierClass.isAssignableFrom(classifier.getClass())) { + throw new ClassCastException( + "Invalid cast for " + classifierClass.getName()); } if (classifier == null) { try { result = classifierClass.newInstance(); addClassifierToCache(reference, result); if (log.isDebugEnabled()) { - log.debug("Add '" + reference.getName() + "' to external cache"); + log.debug("Add '" + reference.getName() + + "' to external cache"); } - } catch (Exception eee) { // IllegalAccessException and InstantiationException - throw new RuntimeException("Unable to add new '" + classifierClass.getName() + + } catch (Exception eee) { + // IllegalAccessException and InstantiationException + throw new RuntimeException( + "Unable to add new '" + classifierClass.getName() + "' to cache for '" + reference.getName() + "'", eee); } } else { if (log.isDebugEnabled()) { - log.debug("Get '" + reference.getName() + "' from external cache"); + log.debug("Get '" + reference.getName() + + "' from external cache"); } result = (C) classifier; } return result; } - protected void addClassifierToCache(ObjectModelImplRef reference, ObjectModelClassifierImpl classifier) { + protected void addClassifierToCache(ObjectModelImplRef reference, + ObjectModelClassifierImpl classifier) { String fqn = reference.getName(); String packageName = GeneratorUtil.getParentPackageName(fqn); String name = GeneratorUtil.getClassNameFromQualifiedName(fqn); Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModeImplAssociationClassParticipant.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModeImplAssociationClassParticipant.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModeImplAssociationClassParticipant.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -34,13 +43,12 @@ ObjectModelImplRef { // class - protected ObjectModelAssociationClassImpl associationClass = null; + protected ObjectModelAssociationClassImpl associationClass; // role - protected String attributeName = null; + protected String attributeName; public ObjectModeImplAssociationClassParticipant() { - super(); } /** @@ -56,9 +64,10 @@ } public String getAttributeName() { - if ((attributeName == null) || ("".equals(attributeName))) { - for (ObjectModeImplAssociationClassParticipant participant : associationClass.getParticipantsRefs()) { - if (participant != this) { + if (attributeName == null || "".equals(attributeName)) { + for (ObjectModeImplAssociationClassParticipant participant : + associationClass.getParticipantsRefs()) { + if (!equals(participant)) { attributeName = GeneratorUtil .toLowerCaseFirstLetter(GeneratorUtil .getClassNameFromQualifiedName(participant Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelAssociationClassImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelAssociationClassImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelAssociationClassImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * \*##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.models.object.xml; @@ -48,12 +55,11 @@ private static Log log = LogFactory .getLog(ObjectModelAssociationClassImpl.class); - protected List<ObjectModelAttribute> participantsAttributes = null; - protected List<ObjectModelClassifier> participantsClassifiers = null; + protected List<ObjectModelAttribute> participantsAttributes; + protected List<ObjectModelClassifier> participantsClassifiers; protected List<ObjectModeImplAssociationClassParticipant> participantsRefs = new ArrayList<ObjectModeImplAssociationClassParticipant>(); public ObjectModelAssociationClassImpl() { - super(); } public void addParticipant( @@ -72,6 +78,7 @@ * * @return a List containing all participants attributes for this association class. */ + @Override public List<ObjectModelAttribute> getParticipantsAttributes() { if (participantsAttributes == null) { parseParticipantsRefs(); @@ -85,6 +92,7 @@ * * @return a List containing all participants classifiers for this association class. */ + @Override public List<ObjectModelClassifier> getParticipantsClassifiers() { if (participantsClassifiers == null) { parseParticipantsRefs(); Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelAttributeImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelAttributeImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelAttributeImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -38,18 +47,17 @@ public class ObjectModelAttributeImpl extends ObjectModelParameterImpl implements ObjectModelAttribute { - protected String reverseAttributeName = null; + protected String reverseAttributeName; protected int reverseMaxMultiplicity = -1; - protected String associationType = null; + protected String associationType; protected String visibility = "protected"; - protected ObjectModelClassifier reference = null; - protected String associationClassName = null; - protected boolean isStatic = false; - protected boolean isFinal = false; + protected ObjectModelClassifier reference; + protected String associationClassName; + protected boolean isStatic; + protected boolean isFinal; protected boolean isNavigable = true; public ObjectModelAttributeImpl() { - super(); } public void postInit() { @@ -94,6 +102,7 @@ * @return a boolean indicating whether this attribute is an aggregate or * not. */ + @Override public boolean isAggregate() { return "aggregate".equals(associationType) || "shared".equals(associationType); } @@ -104,10 +113,12 @@ * @return a boolean indicating whether this attribute is an composite or * not. */ + @Override public boolean isComposite() { return "composite".equals(associationType); } + @Override public String getVisibility() { return visibility; } @@ -122,8 +133,9 @@ * @return a boolean indicating whether this attribute reference a model * classifier or not. */ + @Override public boolean referenceClassifier() { - return (getClassifier() != null); + return getClassifier() != null; } /** @@ -133,6 +145,7 @@ * @return the ObjectModelClassfifier referenced by this attribute or null * if it does not reference a model classifier. */ + @Override public ObjectModelClassifier getClassifier() { return getModel().getClassifier(type); } @@ -146,6 +159,7 @@ * other end of the association or null if this is not an * association, or if it is not bi-directionnal. */ + @Override public ObjectModelAttribute getReverseAttribute() { ObjectModelAttribute reverseAttribute = null; ObjectModelClassifier classifier = getClassifier(); @@ -155,14 +169,16 @@ return reverseAttribute; } + @Override public String getReverseAttributeName() { - if ((reverseAttributeName == null) || ("".equals(reverseAttributeName))) { + if (reverseAttributeName == null || "".equals(reverseAttributeName)) { reverseAttributeName = GeneratorUtil .toLowerCaseFirstLetter(getDeclaringElement().getName()); } return reverseAttributeName; } + @Override public String getName() { if ((name == null || "".equals(name)) && getClassifier() != null) { name = GeneratorUtil.toLowerCaseFirstLetter(getClassifier() @@ -176,6 +192,7 @@ * * @see org.nuiton.eugene.models.object.ObjectModelAttribute#getReverseMaxMultiplicity() */ + @Override public int getReverseMaxMultiplicity() { return reverseMaxMultiplicity; } @@ -187,6 +204,7 @@ * @return a ObjectModelClass corresponding to the association class * associated with this association, or null if there is none. */ + @Override public ObjectModelClass getAssociationClass() { return getModel().getClass(associationClassName); } @@ -198,8 +216,9 @@ * @return a boolean indicating whether this association has an associated * association class, ot not. */ + @Override public boolean hasAssociationClass() { - return (getAssociationClass() != null); + return getAssociationClass() != null; } /** @@ -207,6 +226,7 @@ * * @return a boolean indicating whether this attribute is static or not. */ + @Override public boolean isStatic() { return isStatic; } @@ -216,6 +236,7 @@ * * @return a boolean indicating whether this attribute is final or not. */ + @Override public boolean isFinal() { return isFinal; } @@ -223,6 +244,7 @@ /* * @see org.nuiton.eugene.models.object.ObjectModelAttribute#isNavigable() */ + @Override public boolean isNavigable() { return isNavigable; } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelClassImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelClassImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelClassImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -47,15 +56,14 @@ */ public class ObjectModelClassImpl extends ObjectModelClassifierImpl implements ObjectModelClass { - protected List<ObjectModelClass> superclasses = null; + protected List<ObjectModelClass> superclasses; protected Map<ObjectModelClass, String> superclassesDiscriminators = new HashMap<ObjectModelClass, String>(); protected List<ObjectModelImplRef> superclassesRefs = new ArrayList<ObjectModelImplRef>(); - protected List<ObjectModelClass> specialisations = null; - protected List<ObjectModelClassifier> innerClasses = null; - protected boolean abstractz = false; + protected List<ObjectModelClass> specialisations; + protected List<ObjectModelClassifier> innerClasses; + protected boolean abstractz; public ObjectModelClassImpl() { - super(); } public void clearSuperclasses() { @@ -112,7 +120,7 @@ @Override public Collection<ObjectModelClassifier> getInnerClassifiers() { - return this.innerClasses; + return innerClasses; } /** Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelClassifierImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelClassifierImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelClassifierImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -36,19 +45,24 @@ public abstract class ObjectModelClassifierImpl extends ObjectModelElementImpl implements ObjectModelClassifier { - protected boolean extern = false; + protected boolean extern; - protected String qualifiedName = null; - protected String packageName = null; - protected List<ObjectModelInterface> interfaces = null; - protected List<ObjectModelImplRef> interfacesRefs = new ArrayList<ObjectModelImplRef>(); - protected List<ObjectModelOperation> operations = new ArrayList<ObjectModelOperation>(); - protected Map<String, ObjectModelAttribute> attributes = new HashMap<String, ObjectModelAttribute>(); - protected List<ObjectModelAttribute> orderedAttributes = new ArrayList<ObjectModelAttribute>(); - protected List<ObjectModelDependency> dependencies = new ArrayList<ObjectModelDependency>(); + protected String qualifiedName; + protected String packageName; + protected List<ObjectModelInterface> interfaces; + protected List<ObjectModelImplRef> interfacesRefs = + new ArrayList<ObjectModelImplRef>(); + protected List<ObjectModelOperation> operations = + new ArrayList<ObjectModelOperation>(); + protected Map<String, ObjectModelAttribute> attributes = + new HashMap<String, ObjectModelAttribute>(); + protected List<ObjectModelAttribute> orderedAttributes = + new ArrayList<ObjectModelAttribute>(); + protected List<ObjectModelDependency> dependencies = + new ArrayList<ObjectModelDependency>(); - protected String type = null; - protected boolean inner = false; + protected String type; + protected boolean inner; @Override public String toString() { @@ -132,15 +146,19 @@ for(ObjectModelImplRef ref : interfacesRefs) { ObjectModelInterfaceImpl interfacez = - (ObjectModelInterfaceImpl)objectModelImpl.getInterface(ref.getName()); + (ObjectModelInterfaceImpl) + objectModelImpl.getInterface(ref.getName()); if (interfacez == null) { // Interface not exist in model - ExternalCacheExtension cache = objectModelImpl.getExtension( - ExternalCacheExtension.OBJECTMODEL_EXTENSION, ExternalCacheExtension.class); + ExternalCacheExtension cache = + objectModelImpl.getExtension( + ExternalCacheExtension.OBJECTMODEL_EXTENSION, + ExternalCacheExtension.class); // get external interface from cache (or create it) - interfacez = cache.getCache(ref, ObjectModelInterfaceImpl.class); + interfacez = + cache.getCache(ref, ObjectModelInterfaceImpl.class); } interfaces.add(interfacez); } @@ -206,7 +224,7 @@ */ @Override public ObjectModelAttribute getAttribute(String attributeName) { - return (attributeName == null ? null : attributes.get(attributeName)); + return attributeName == null ? null : attributes.get(attributeName); } @Override @@ -234,7 +252,7 @@ @Override public Collection<ObjectModelDependency> getDependencies() { - return this.dependencies; + return dependencies; } @Override @@ -242,7 +260,7 @@ if (name.isEmpty()) { return null; } - for (ObjectModelDependency dependency : this.dependencies) { + for (ObjectModelDependency dependency : dependencies) { if (dependency.getName().equalsIgnoreCase(name)) { return dependency; } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelDependencyImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelDependencyImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelDependencyImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -55,7 +64,7 @@ } public String getSupplierName() { - return this.supplierName; + return supplierName; } /** @@ -64,11 +73,11 @@ */ @Override public ObjectModelClassifier getSupplier() { - if (this.supplier == null) { - ObjectModelClassifier classifier = this.client.getModel().getClassifier(supplierName); - this.supplier = classifier; + if (supplier == null) { + ObjectModelClassifier classifier = client.getModel().getClassifier(supplierName); + supplier = classifier; } - return this.supplier; + return supplier; } public void setClient(ObjectModelClassifierImpl client) { @@ -77,7 +86,7 @@ @Override public ObjectModelClassifier getClient() { - return this.client; + return client; } } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelElementImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelElementImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelElementImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * \*##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.models.object.xml; @@ -44,15 +51,14 @@ protected ObjectModelImpl objectModelImpl; protected ObjectModelElement declaringElement; - protected String name = null; - protected boolean isStatic = false; - protected String documentation = null; + protected String name; + protected boolean isStatic; + protected String documentation; protected List<String> stereotypes = new ArrayList<String>(); protected Map<String, String> tagValues = new HashMap<String, String>(); protected List<String> comments = new ArrayList<String>(); public ObjectModelElementImpl() { - super(); } /** @@ -114,7 +120,7 @@ } public void addComment(String comment) { - this.comments.add(comment); + comments.add(comment); } @Override @@ -203,7 +209,7 @@ */ @Override public String getTagValue(String tagValue) { - return (tagValue == null ? null : tagValues.get(tagValue)); + return tagValue == null ? null : tagValues.get(tagValue); } /** Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelEnumerationImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelEnumerationImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelEnumerationImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,31 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ + package org.nuiton.eugene.models.object.xml; import java.util.ArrayList; @@ -57,14 +67,15 @@ * logger */ private static final Log log = LogFactory.getLog(ObjectModelImpl.class); - protected String name = null; - protected String version = null; + protected String name; + protected String version; protected Map<String, ObjectModelClass> classes = new HashMap<String, ObjectModelClass>(); protected Map<String, ObjectModelInterface> interfaces = new HashMap<String, ObjectModelInterface>(); protected Map<String, ObjectModelClassifier> classifiers = new HashMap<String, ObjectModelClassifier>(); protected Map<String, ObjectModelEnumeration> enumerations = new HashMap<String, ObjectModelEnumeration>(); protected List<String> comments = new ArrayList<String>(); private Map<String, String> tagValues = new HashMap<String, String>(); + /** * Used to add others specific object to the model * The key defined must be unique to get the significative extension associated to @@ -175,8 +186,8 @@ */ @Override public ObjectModelClassifier getClassifier(String qualifiedClassifierName) { - return (qualifiedClassifierName == null ? null - : classifiers.get(qualifiedClassifierName)); + return qualifiedClassifierName == null ? null + : classifiers.get(qualifiedClassifierName); } /** @@ -311,7 +322,7 @@ protected void mergeClassifiers( ObjectModelClassifierImpl initialClazzifier, ObjectModelClassifierImpl additionalClazzifier) { - Iterator it; + Iterator<?> it; // On n'utilise pas les parsetXXX puisque les post-init sont censés être // déjà faits... @@ -391,7 +402,7 @@ */ private void mergeClasses(ObjectModelClassImpl initialClazz, ObjectModelClassImpl additionalClazz) { - Iterator it; + Iterator<?> it; mergeClassifiers(initialClazz, additionalClazz); for (it = additionalClazz.getAttributes().iterator(); it.hasNext();) { @@ -415,7 +426,7 @@ ObjectModelAssociationClassImpl initialAssocClazz, ObjectModelAssociationClassImpl additionalAssocClazz) { mergeClasses(initialAssocClazz, additionalAssocClazz); - Iterator it; + Iterator<?> it; for (it = additionalAssocClazz.participantsRefs.iterator(); it.hasNext();) { ObjectModeImplAssociationClassParticipant participant = (ObjectModeImplAssociationClassParticipant) it.next(); if (!contains(initialAssocClazz.participantsRefs, participant)) { @@ -444,12 +455,12 @@ return false; } - private boolean contains(Collection coll, ObjectModelOperationImpl toFind) { + private boolean contains(Collection<?> coll, ObjectModelOperationImpl toFind) { return coll.contains(toFind); // Le equals(...) de // ObjectModelOperationImpl convient } - private boolean contains(Collection coll, ObjectModelImplRef toFind) { + private boolean contains(Collection<?> coll, ObjectModelImplRef toFind) { return coll.contains(toFind); // Le equals(...) de ObjectModelImplRef // convient } @@ -483,7 +494,7 @@ */ @Override public String getTagValue(String tagValue) { - return (tagValue == null ? null : tagValues.get(tagValue)); + return tagValue == null ? null : tagValues.get(tagValue); } /** Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplRef.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplRef.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplRef.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -33,7 +42,7 @@ */ public class ObjectModelImplRef { - protected String name = null; + protected String name; public void postInit() { } @@ -46,13 +55,14 @@ return name; } + @Override public boolean equals(Object o) { if (!(o instanceof ObjectModelImplRef)) { return false; } ObjectModelImplRef oRef = (ObjectModelImplRef) o; if (name == null) { - return (oRef.getName() == null); + return oRef.getName() == null; } return name.equals(oRef.getName()); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplSuperClassRef.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplSuperClassRef.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplSuperClassRef.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -33,7 +42,7 @@ */ public class ObjectModelImplSuperClassRef extends ObjectModelImplRef { - protected String discrimininator = null; + protected String discrimininator; public void setDiscriminator(String discrimininator) { this.discrimininator = discrimininator; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplTagValue.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplTagValue.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelImplTagValue.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -30,7 +39,7 @@ */ public class ObjectModelImplTagValue extends ObjectModelImplRef { - protected String value = null; + protected String value; public void setValue(String value) { this.value = value; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelInterfaceImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelInterfaceImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelInterfaceImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -38,11 +47,12 @@ */ public class ObjectModelInterfaceImpl extends ObjectModelClassifierImpl implements ObjectModelInterface { + @Override public String toString() { StringBuffer result = new StringBuffer(); result.append("interface ").append(getQualifiedName()).append(" "); result.append("extends "); - for (Iterator i = getInterfaces().iterator(); i.hasNext();) { + for (Iterator<?> i = getInterfaces().iterator(); i.hasNext();) { result.append(((ObjectModelClassifier) i.next()).getName()); if (i.hasNext()) { result.append(", "); Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelOperationImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelOperationImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelOperationImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -43,13 +52,13 @@ public class ObjectModelOperationImpl extends ObjectModelElementImpl implements ObjectModelOperation { - protected ObjectModelParameter returnParameter = null; + protected ObjectModelParameter returnParameter; protected String visibility = "public"; protected String transactionLevel = "supports"; - protected boolean abstractz = false; + protected boolean abstractz; protected List<ObjectModelParameter> parameters = new ArrayList<ObjectModelParameter>(); @@ -58,7 +67,6 @@ protected String bodyCode = ""; public ObjectModelOperationImpl() { - super(); } public String toString() { @@ -74,7 +82,7 @@ ObjectModelOperation op = (ObjectModelOperation) o; if (getName().equals(op.getName()) && getParameters().size() == op.getParameters().size()) { - for (Iterator i = getParameters().iterator(), opi = op + for (Iterator<?> i = getParameters().iterator(), opi = op .getParameters().iterator(); i.hasNext() && opi.hasNext();) { ObjectModelParameter p = (ObjectModelParameter) i.next(); @@ -129,7 +137,7 @@ @Override public ObjectModelParameter getReturnParameter() { - return this.returnParameter; + return returnParameter; } @Override @@ -169,7 +177,7 @@ raisedParameter.postInit(); raisedParameter.setDeclaringElement(this); - this.exceptions.add(raisedParameter.getType()); + exceptions.add(raisedParameter.getType()); } @Override Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelParameterImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelParameterImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/object/xml/ObjectModelParameterImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object.xml; @@ -35,15 +44,14 @@ public class ObjectModelParameterImpl extends ObjectModelElementImpl implements ObjectModelParameter { - protected String type = null; + protected String type; protected int minMultiplicity = 1; protected int maxMultiplicity = 1; protected String ordering = "unspecified"; protected boolean isUnique = true; - protected String defaultValue = null; + protected String defaultValue; public ObjectModelParameterImpl() { - super(); } public void setType(String type) { @@ -62,8 +70,8 @@ this.ordering = ordering; } - public void setUnique(boolean unique) { - this.isUnique = unique; + public void setUnique(boolean isUnique) { + this.isUnique = isUnique; } public void setDefaultValue(String defaultValue) { @@ -90,9 +98,6 @@ return maxMultiplicity; } - /** - * @see org.nuiton.eugene.models.object.ObjectModelAttribute#isOrdered() - */ @Override public boolean isOrdered() { return "ordered".equals(ordering); @@ -100,7 +105,7 @@ @Override public boolean isUnique() { - return this.isUnique; + return isUnique; } @Override Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModel.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModel.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModel.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelComplexState.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelComplexState.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelComplexState.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; @@ -38,7 +47,7 @@ * Return the states set * @return a collection of states */ - public Collection<StateModelState> getStates(); + Collection<StateModelState> getStates(); /** * Return the non initial state pointed by the initial state of the state @@ -53,5 +62,5 @@ * * @return a state */ - public StateModelState getInitialState(); + StateModelState getInitialState(); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelGenerator.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelGenerator.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelGenerator.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; @@ -23,9 +32,6 @@ import org.apache.commons.logging.LogFactory; import org.nuiton.eugene.AbstractGenerator; import org.nuiton.eugene.MonitorWriter; -import org.nuiton.eugene.models.state.StateModel; -import org.nuiton.eugene.models.state.StateModelState; -import org.nuiton.eugene.models.state.StateModelStateChart; import java.io.File; import java.io.IOException; @@ -61,7 +67,6 @@ * Empty constructor */ public StateModelGenerator() { - super(); } /** @@ -94,7 +99,7 @@ /** - * Par défaut, appel {@link #generateFromModel(org.nuiton.eugene.MonitorWriter , org.nuiton.eugene.models.state.StateModel)} pour le + * Par défaut, appel {@link #generateFromModel(MonitorWriter , StateModel)} pour le * model et {@link #generateFromState(Writer,StateModelState)} pour tous les * etats du modele. * Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelReader.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelReader.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelReader.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.models.state; @@ -29,7 +36,6 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.nuiton.eugene.ModelReader; -import org.nuiton.eugene.models.state.StateModel; import org.nuiton.eugene.models.state.xml.DigesterStateModelRuleSet; import org.nuiton.eugene.models.state.xml.StateModelImpl; import org.nuiton.util.FileUtil; @@ -102,10 +108,20 @@ if (log.isInfoEnabled()) { log.info("Reading model property file " + propFile); } + FileInputStream inStream = null; try { - prop.load(new FileInputStream(propFile)); + inStream = new FileInputStream(propFile); + prop.load(inStream); } catch (IOException e) { log.warn("Cannot read property file " + propFile, e); + }finally { + try { + if (inStream != null) { + inStream.close(); + } + } catch (IOException e) { + log.warn("Cannot close property file " + propFile, e); + } } // on ajoute les proprietes du fichier associe au model Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelSimpleState.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelSimpleState.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelSimpleState.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; @@ -36,11 +45,11 @@ * State final status * @return true il the state is final */ - public boolean isFinal(); + boolean isFinal(); /** * State initial status * @return true if the state is initial */ - public boolean isInitial(); + boolean isInitial(); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelState.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelState.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelState.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; @@ -26,8 +35,8 @@ * * A state, that can be simple or complexe * - * @see org.nuiton.eugene.models.state.StateModelSimpleState - * @see org.nuiton.eugene.models.state.StateModelComplexState + * @see StateModelSimpleState + * @see StateModelComplexState * * @author chatellier * @version $Revision$ @@ -41,17 +50,17 @@ * Get the state name * @return state name */ - public String getName(); + String getName(); /** * Return the state's transition set * @return a list of transition */ - public List<StateModelTransition> getTransitions(); + List<StateModelTransition> getTransitions(); /** * State complex status * @return true if the state is complex */ - public boolean isComplex(); + boolean isComplex(); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelStateChart.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelStateChart.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelStateChart.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; @@ -37,5 +46,5 @@ * Get package name * @return package name */ - public String getPackageName(); + String getPackageName(); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelTransition.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelTransition.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/StateModelTransition.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; @@ -36,11 +45,11 @@ * Return the destination state * @return a state */ - public StateModelState getDestinationState(); + StateModelState getDestinationState(); /** * Return the event name * @return the event name */ - public String getEvent(); + String getEvent(); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/DigesterStateModelRuleSet.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/DigesterStateModelRuleSet.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/DigesterStateModelRuleSet.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state.xml; @@ -48,16 +57,15 @@ */ public class DigesterStateModelRuleSet extends RuleSetBase { - protected String prefix = null; + protected String prefix; public DigesterStateModelRuleSet() { this(""); } public DigesterStateModelRuleSet(String prefix) { - super(); this.prefix = prefix; - this.namespaceURI = "http://www.codelutin.org/lutingenerator/stateModel"; + namespaceURI = "http://www.codelutin.org/lutingenerator/stateModel"; } public void addRuleInstances(Digester digester) { Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelComplexeStateImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelComplexeStateImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelComplexeStateImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,27 +1,35 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state.xml; import java.util.Collection; import java.util.HashMap; -import java.util.Iterator; import java.util.Map; import org.nuiton.eugene.models.state.StateModelComplexState; @@ -50,7 +58,6 @@ * Constructor */ public StateModelComplexeStateImpl() { - super(); mapState = new HashMap<String, StateModelState>(); } @@ -71,14 +78,14 @@ /** * Correct association, because, the xml file migth be non ordonated + * @param parent */ void correctTransitionNameToInstance(StateModelComplexeStateImpl parent) { // iterator - Iterator<StateModelState> it = mapState.values().iterator(); - while (it.hasNext()) { - StateModelState state = it.next(); + for (StateModelState stateModelState : mapState.values()) { + StateModelState state = stateModelState; // reboucle si l'etat est complexe if (state instanceof StateModelComplexeStateImpl) { @@ -86,12 +93,13 @@ .correctTransitionNameToInstance(this); } else { for (StateModelTransition tr : state.getTransitions()) { - StateModelTransitionImpl tri = (StateModelTransitionImpl) tr; + StateModelTransitionImpl tri = + (StateModelTransitionImpl) tr; String name = tri.getStateName(); // l'etat apartient au cas complexe courant - if (this.getState(name) != null) { - tri.setState(this.getState(name)); + if (getState(name) != null) { + tri.setState(getState(name)); } else { // l'etat apartient au cas complexe parent if (parent != null && parent.getState(name) != null) { @@ -105,41 +113,37 @@ } /** - * Return a state ref by his name + * @return a state ref by his name * @param stateName a state or null if state doesnt exists */ StateModelState getState(String stateName) { return mapState.get(stateName); } - /* (non-Javadoc) - * @see org.nuiton.eugene.models.state.xml.StateModelStateImpl#isComplexe() - */ @Override public boolean isComplex() { // TODO Auto-generated method stub return true; } - /* (non-Javadoc) - * @see org.nuiton.eugene.models.state.StateModelComplexeState#getInitialState() - */ + @Override public StateModelState getInitialState() { StateModelState response = null; // iterator - Iterator<StateModelState> it = mapState.values().iterator(); - while (it.hasNext()) { - StateModelState state = it.next(); + for (StateModelState stateModelState : mapState.values()) { + StateModelState state = stateModelState; // if state is simple if (!state.isComplex()) { - StateModelSimpleState simpleState = (StateModelSimpleState) state; + StateModelSimpleState simpleState = + (StateModelSimpleState) state; if (simpleState.isInitial()) { - // get(0), normalement il n'y a qu'une transition sur un etat initial + // get(0), normalement il n'y a qu'une transition sur + // un etat initial response = simpleState.getTransitions().get(0) .getDestinationState(); } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state.xml; @@ -49,12 +58,12 @@ /** * Name of this model */ - protected String name = null; + protected String name; /** * Version of this model */ - protected String version = null; + protected String version; /** * Model tagged values @@ -65,14 +74,13 @@ * Construteur */ public StateModelImpl() { - super(); listStateCharts = new ArrayList<StateModelStateChart>(); modelTagValues = new HashMap<String, String>(); } @Override public String getName() { - return this.name; + return name; } /** @@ -135,7 +143,7 @@ */ @Override public String getTagValue(String key) { - return (key == null ? null : (String) modelTagValues.get(key)); + return key == null ? null : modelTagValues.get(key); } /** @@ -154,7 +162,7 @@ */ @Override public String getVersion() { - return this.version; + return version; } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelSimpleStateImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelSimpleStateImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelSimpleStateImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state.xml; @@ -49,6 +58,7 @@ /** * @return the finalState */ + @Override public boolean isFinal() { return finalState; } @@ -63,6 +73,7 @@ /** * @return the initialState */ + @Override public boolean isInitial() { return initialState; } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelStateChartImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelStateChartImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelStateChartImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state.xml; @@ -36,9 +45,7 @@ /** Package name. */ protected String packageName; - /* - * @see org.nuiton.eugene.models.state.StateModelStateChart#getPackageName() - */ + @Override public String getPackageName() { return packageName; } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelStateImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelStateImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelStateImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state.xml; @@ -59,13 +68,10 @@ * Constructor */ public StateModelStateImpl() { - super(); listTransitions = new ArrayList<StateModelTransition>(); } - /* (non-Javadoc) - * @see org.nuiton.eugene.models.state.StateModelState#getName() - */ + @Override public String getName() { return name; } @@ -86,16 +92,12 @@ listTransitions.add(transition); } - /* (non-Javadoc) - * @see org.nuiton.eugene.models.state.StateModelState#getTransitions() - */ + @Override public List<StateModelTransition> getTransitions() { return listTransitions; } - /* (non-Javadoc) - * @see org.nuiton.eugene.models.state.StateModelState#isComplexe() - */ + @Override public boolean isComplex() { return false; } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelTransitionImpl.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelTransitionImpl.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/models/state/xml/StateModelTransitionImpl.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state.xml; @@ -36,7 +45,7 @@ /** * Destination state name */ - protected String stateName = null; + protected String stateName; /** * Event @@ -46,13 +55,12 @@ /** * Destination state reference */ - protected StateModelState state = null; + protected StateModelState state; /** * Constructor */ public StateModelTransitionImpl() { - super(); } /** @@ -84,16 +92,12 @@ this.state = state; } - /* - * @see org.nuiton.eugene.models.state.StateModelTransition#getDestinationState() - */ + @Override public StateModelState getDestinationState() { return state; } - /* - * @see org.nuiton.eugene.models.state.StateModelTransition#getEvent() - */ + @Override public String getEvent() { return event; } Modified: trunk/eugene/src/main/java/org/nuiton/eugene/package-info.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/package-info.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/package-info.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + /** * Eugene. */ Modified: trunk/eugene/src/main/java/org/nuiton/eugene/writer/AbstractChainedFileWriter.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/writer/AbstractChainedFileWriter.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/writer/AbstractChainedFileWriter.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.writer; import org.apache.commons.logging.Log; @@ -30,7 +38,7 @@ /** * Abstract implementation of the {@link ChainedFileWriter}. * - * @author tchemit + * @author tchemit <chemit@codelutin.com> * @since 2.0.0 */ public abstract class AbstractChainedFileWriter implements ChainedFileWriter { Modified: trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriter.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriter.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriter.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,30 +1,37 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.writer; import java.io.File; import java.io.IOException; import java.util.List; import java.util.Map; -import java.util.regex.Matcher; /** * Contract to generate files from any incoming sources (zargo, xmi, ...) to any @@ -131,7 +138,10 @@ */ void addEntry(ChainedFileWriterEntry entry); - /** @return the array of properties names authorized for the chanied writer. */ + /** + * @return the array of properties names authorized for the chained + * writer. + */ String[] getAuthorizedPropertyNames(); /** Modified: trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriterConfiguration.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriterConfiguration.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriterConfiguration.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.writer; import org.nuiton.eugene.ModelReader; @@ -30,7 +38,7 @@ * Shared configuration of a {@link ChainedFileWriter}, should be the same for * all writers to use at a time. * - * @author tchemit + * @author tchemit <chemit@codelutin.com> * @since 2.0.0 */ public interface ChainedFileWriterConfiguration { Modified: trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriterEntry.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriterEntry.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedFileWriterEntry.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,31 @@ +/* + * #%L + * EUGene :: EUGene + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Lesser Public License for more details. + * + * You should have received a copy of the GNU General Lesser Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/lgpl-3.0.html>. + * #L% + */ + package org.nuiton.eugene.writer; import java.io.File; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedWriterEngine.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedWriterEngine.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/writer/ChainedWriterEngine.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,31 @@ +/* + * #%L + * EUGene :: EUGene + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Lesser Public License for more details. + * + * You should have received a copy of the GNU General Lesser Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/lgpl-3.0.html>. + * #L% + */ + package org.nuiton.eugene.writer; import java.util.List; Modified: trunk/eugene/src/main/java/org/nuiton/eugene/writer/DefaultChainedWriterEngine.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/writer/DefaultChainedWriterEngine.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/writer/DefaultChainedWriterEngine.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,31 @@ +/* + * #%L + * EUGene :: EUGene + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Lesser Public License for more details. + * + * You should have received a copy of the GNU General Lesser Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/lgpl-3.0.html>. + * #L% + */ + package org.nuiton.eugene.writer; import org.apache.commons.logging.Log; @@ -9,7 +37,7 @@ import java.util.regex.Pattern; /** - * Default implementation of the {@link org.nuiton.eugene.writer.ChainedWriterEngine}. + * Default implementation of the {@link ChainedWriterEngine}. * <p/> * Created: 17 déc. 2009 * Modified: trunk/eugene/src/main/java/org/nuiton/eugene/writer/package-info.java =================================================================== --- trunk/eugene/src/main/java/org/nuiton/eugene/writer/package-info.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/main/java/org/nuiton/eugene/writer/package-info.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + /** * Eugene writer package : a small framework to chain writers. */ Modified: trunk/eugene/src/site/fr/rst/DevUIDoc.rst =================================================================== --- trunk/eugene/src/site/fr/rst/DevUIDoc.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/fr/rst/DevUIDoc.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -6,9 +6,35 @@ :Revision: $Revision$ :Date: $Date$ - .. contents:: +.. - +.. * #%L +.. * EUGene :: EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - Model UIModel ============= Modified: trunk/eugene/src/site/fr/rst/DiscussionSurTypeDeGeneration.rst =================================================================== --- trunk/eugene/src/site/fr/rst/DiscussionSurTypeDeGeneration.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/fr/rst/DiscussionSurTypeDeGeneration.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -2,6 +2,37 @@ Principe de la génération ========================= +.. - +.. * #%L +.. * EUGene :: EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + +Principe de la génération +~~~~~~~~~~~~~~~~~~~~~~~~~ + Il y a deux façon de voir la génération. La première que l'on rencontre le plus Modified: trunk/eugene/src/site/fr/rst/Todo.rst =================================================================== --- trunk/eugene/src/site/fr/rst/Todo.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/fr/rst/Todo.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -2,10 +2,36 @@ TODO ==== - :Revision: $Revision$ :Date: $Date$ +.. - +.. * #%L +.. * EUGene :: EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - Idées ou choses à faire ======================= Modified: trunk/eugene/src/site/fr/rst/index.rst =================================================================== --- trunk/eugene/src/site/fr/rst/index.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/fr/rst/index.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -4,6 +4,33 @@ .. contents:: +.. - +.. * #%L +.. * EUGene :: EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - Origine du projet ----------------- Modified: trunk/eugene/src/site/fr/rst/plugineclipse.rst =================================================================== --- trunk/eugene/src/site/fr/rst/plugineclipse.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/fr/rst/plugineclipse.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,6 +1,38 @@ +===================================== Installation du plugin LutinGenerator ===================================== +.. - +.. * #%L +.. * EUGene :: EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + +Installation du plugin LutinGenerator +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + Ce guide détail comment installer le plugin eclipse LutinGenerator via l'update site (assitant d'instalation de plugins). Modified: trunk/eugene/src/site/rst/LutinGenerator.rst =================================================================== --- trunk/eugene/src/site/rst/LutinGenerator.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/rst/LutinGenerator.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -7,9 +7,35 @@ :Revision: $Revision$ :Date: $Date$ - .. contents:: +.. - +.. * #%L +.. * EUGene :: EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - Project origin ============== Modified: trunk/eugene/src/site/rst/generatorHelp.rst =================================================================== --- trunk/eugene/src/site/rst/generatorHelp.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/rst/generatorHelp.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,35 @@ +============== +Generator Help +============== +.. - +.. * #%L +.. * EUGene :: EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + How to create a UML model for use with Eugene --------------------------------------------- Modified: trunk/eugene/src/site/rst/index.rst =================================================================== --- trunk/eugene/src/site/rst/index.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/rst/index.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -7,9 +7,35 @@ :Revision: $Revision$ :Date: $Date$ - .. contents:: +.. - +.. * #%L +.. * EUGene :: EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - Project origin ============== Modified: trunk/eugene/src/site/site_en.xml =================================================================== --- trunk/eugene/src/site/site_en.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/site_en.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: EUGene + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2004 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project name="${project.name}"> <bannerLeft> Modified: trunk/eugene/src/site/site_fr.xml =================================================================== --- trunk/eugene/src/site/site_fr.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/site/site_fr.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: EUGene + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2004 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project name="${project.name}"> <bannerLeft> Modified: trunk/eugene/src/test/java/org/nuiton/eugene/GeneratorUtilTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/GeneratorUtilTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/GeneratorUtilTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,24 +1,32 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene; import java.util.Set; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/java/ImportsManagerExtensionTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/java/ImportsManagerExtensionTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/java/ImportsManagerExtensionTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.java; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/java/ImportsManagerTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/java/ImportsManagerTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/java/ImportsManagerTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.java; import java.io.Serializable; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/java/JavaBuilderTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/java/JavaBuilderTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/java/JavaBuilderTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,33 +1,40 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.java; -import java.util.ArrayList; import java.util.List; import org.junit.After; import org.junit.AfterClass; import org.junit.Before; import org.junit.BeforeClass; import org.junit.Test; +import org.nuiton.eugene.GeneratorUtilTest; import org.nuiton.eugene.models.object.ObjectModel; import static org.junit.Assert.*; import org.nuiton.eugene.models.object.ObjectModelAttribute; @@ -36,6 +43,7 @@ import org.nuiton.eugene.models.object.ObjectModelModifier; import org.nuiton.eugene.models.object.ObjectModelOperation; import org.nuiton.eugene.models.object.xml.ObjectModelAttributeImpl; +import org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest; /** * JavaBuilderTest @@ -71,8 +79,10 @@ /** * Test of getModel. - * No test needed : model created in modelBuilder instanciated in constructor (ObjectModelBuilder). - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testGetModel() + * No test needed : model created in modelBuilder instanciated in + * constructor (ObjectModelBuilder). + * + * @see ObjectModelBuilderTest#testGetModel() */ @Test public void testGetModel() { @@ -89,8 +99,7 @@ * - Add a simple type to import. * - Add a type to import with generic (List of Category) : two imports are added. * NOTE : Use of ImportsManager addImport() method and GeneratorUtil getTypesList() method. - * @see org.nuiton.eugene.ImportsManagerTest#testAddImport() - * @see org.nuiton.eugene.GeneratorUtilTest#testGetTypesList() + * @see GeneratorUtilTest#testGetTypesList() */ @Test public void testAddImport() { @@ -113,7 +122,7 @@ /** * Test of createClass method, of class JavaBuilder. * No test needed : call of createClass in ObjectModelBuilder - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testCreateClass() + * @see ObjectModelBuilderTest#testCreateClass() */ @Test public void testCreateClass() { @@ -142,7 +151,7 @@ * Test of setSuperClass method, of class JavaBuilder. * Only one superclass can be set. * Check imports on superclass qualified name - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testAddSuperclass() + * @see ObjectModelBuilderTest#testAddSuperclass() */ @Test public void testSetSuperClass() { @@ -170,7 +179,7 @@ /** * Test of addInterface method, of class JavaBuilder. * Check imports on adding interface : imports added on interfaceQualifiedName - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testAddInterface() + * @see ObjectModelBuilderTest#testAddInterface() */ @Test public void testAddInterface() { @@ -213,7 +222,7 @@ /** * Test of addAttribute method, of class JavaBuilder. * Check imports on adding attribute : imports added on type and value. - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testAddAttribute() + * @see ObjectModelBuilderTest#testAddAttribute() */ @Test public void testAddAttribute() { @@ -291,7 +300,7 @@ /** * Test of addOperation method, of class JavaBuilder. * Check imports on adding operation : returnType of the operation - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testAddOperation() + * @see ObjectModelBuilderTest#testAddOperation() */ @Test public void testAddOperation() { @@ -304,7 +313,8 @@ ObjectModelOperation result = builder.addOperation(classifier, "methodName", "java.util.List<java.lang.String>", ObjectModelModifier.PUBLIC); - result = builder.addOperation(classifier, "addPropertyChangeListener", null, + result = builder.addOperation(classifier, + "addPropertyChangeListener", null, ObjectModelModifier.PUBLIC, ObjectModelModifier.ABSTRACT); // Check imports @@ -319,7 +329,7 @@ /** * Test of addParameter method, of class JavaBuilder. * Check imports on adding parameter : type of the parameter - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testAddParameter() + * @see ObjectModelBuilderTest#testAddParameter() */ @Test public void testAddParameter() { @@ -346,7 +356,7 @@ /** * Test of addException method, of class JavaBuilder. * Check imports on adding exception : exception name - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testAddException() + * @see ObjectModelBuilderTest#testAddException() */ @Test public void testAddException() { @@ -372,7 +382,7 @@ /** * Test of setOperationBody method, of class JavaBuilder. * No body code for an abstract operation : throw an IllegalArgumentException - * @see org.nuiton.eugene.models.object.xml.ObjectModelBuilderTest#testSetOperationBody() + * @see ObjectModelBuilderTest#testSetOperationBody() */ @Test public void testSetOperationBody() { Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/object/ModelMergeTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/object/ModelMergeTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/object/ModelMergeTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/object/ObjectModelGeneratorTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/object/ObjectModelGeneratorTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/object/ObjectModelGeneratorTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/object/XMI12ToObjectModelTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/object/XMI12ToObjectModelTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/object/XMI12ToObjectModelTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/object/XMI21ToObjectModelTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/object/XMI21ToObjectModelTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/object/XMI21ToObjectModelTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.object; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ExternalCacheExtensionTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ExternalCacheExtensionTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ExternalCacheExtensionTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,24 +1,32 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.models.object.xml; import org.junit.After; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ObjectModelBuilderTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ObjectModelBuilderTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ObjectModelBuilderTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,24 +1,32 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.models.object.xml; import java.util.Iterator; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ObjectModelImplTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ObjectModelImplTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/object/xml/ObjectModelImplTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,29 @@ /* - * *##% + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ package org.nuiton.eugene.models.object.xml; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/state/StateModelDTDTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/state/StateModelDTDTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/state/StateModelDTDTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; Modified: trunk/eugene/src/test/java/org/nuiton/eugene/models/state/StateModelTest.java =================================================================== --- trunk/eugene/src/test/java/org/nuiton/eugene/models/state/StateModelTest.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/eugene/src/test/java/org/nuiton/eugene/models/state/StateModelTest.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,30 @@ -/* *##% +/* + * #%L * EUGene :: EUGene - * Copyright (C) 2004 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2004 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ package org.nuiton.eugene.models.state; Modified: trunk/maven-eugene-plugin/pom.xml =================================================================== --- trunk/maven-eugene-plugin/pom.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/pom.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: Maven plugin + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2006 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> @@ -63,18 +91,6 @@ <plugins> - <!-- plugin plugin --> - <plugin> - <artifactId>maven-plugin-plugin</artifactId> - <executions> - <execution> - <goals> - <goal>helpmojo</goal> - </goals> - </execution> - </executions> - </plugin> - <!-- expose new plexus components --> <plugin> <groupId>org.codehaus.plexus</groupId> @@ -92,24 +108,67 @@ </build> - <!--Site--> - <reporting> - <plugins> - <!--Site report's plugin--> - <plugin> - <artifactId>maven-plugin-plugin</artifactId> - </plugin> + <profiles> - <plugin> - <groupId>org.codehaus.plexus</groupId> - <artifactId>plexus-maven-plugin</artifactId> - <version>1.3.8</version> - </plugin> - </plugins> - </reporting> + <!-- perform only on a release stage when using the maven-release-plugin --> + <profile> + <id>release-profile</id> + <activation> + <property> + <name>performRelease</name> + <value>true</value> + </property> + </activation> - <profiles> + + <build> + + <plugins> + + <!-- plugin plugin --> + <plugin> + <artifactId>maven-plugin-plugin</artifactId> + <executions> + <execution> + <goals> + <goal>helpmojo</goal> + </goals> + </execution> + </executions> + </plugin> + </plugins> + </build> + + </profile> + + <!-- perform only on a release stage when using the maven-release-plugin --> <profile> + <id>reporting</id> + <activation> + <property> + <name>performRelease</name> + <value>true</value> + </property> + </activation> + + <reporting> + <plugins> + <!--Site report's plugin--> + <plugin> + <artifactId>maven-plugin-plugin</artifactId> + </plugin> + + <plugin> + <groupId>org.codehaus.plexus</groupId> + <artifactId>plexus-maven-plugin</artifactId> + <version>1.3.8</version> + </plugin> + </plugins> + </reporting> + + </profile> + + <profile> <id>run-its</id> <activation> <property> Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/AvailableDataMojo.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/AvailableDataMojo.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/AvailableDataMojo.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.plugin; import org.apache.commons.lang.StringUtils; Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/CopyVersionFiles.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/CopyVersionFiles.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/CopyVersionFiles.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,31 @@ -/* *##% +/* + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ + package org.nuiton.eugene.plugin; import org.nuiton.plugin.PluginIOContext; @@ -110,11 +120,11 @@ * * Type string, parce que elle peut avoir la forme "1.3.2" par exemple */ - protected String versionFound = null; + protected String versionFound; /** * Nom du model sauvegarde */ - protected String modelNameFound = null; + protected String modelNameFound; /** * Dossier incluant le nom de la version */ Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/EugeneAbstractMojo.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/EugeneAbstractMojo.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/EugeneAbstractMojo.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.plugin; import org.nuiton.plugin.PluginIOContext; @@ -156,7 +164,7 @@ // init goal io context PluginIOContext p = initResources(); - if ((p.getInputs() == null || p.getInputs().length == 0)) { + if (p.getInputs() == null || p.getInputs().length == 0) { throw new MojoExecutionException("no input defined"); } if (p.getOutput() == null) { Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/EugenePlugin.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/EugenePlugin.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/EugenePlugin.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,31 @@ -/* *##% +/* + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ + package org.nuiton.eugene.plugin; import org.apache.commons.lang.StringUtils; Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/SmartGenerateMojo.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/SmartGenerateMojo.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/SmartGenerateMojo.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.plugin; import org.apache.commons.lang.StringUtils; Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2Model.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2Model.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2Model.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,31 @@ -/* *##% +/* + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ + package org.nuiton.eugene.plugin; import org.nuiton.plugin.PluginIOContext; @@ -227,7 +237,7 @@ protected String[] getSuffixPattern(String prefix) { String[] acceptedSuffixes = getAcceptedTypesAsArray(); int max = acceptedSuffixes.length; - final String[] patterns = new String[max]; + String[] patterns = new String[max]; for (int i = 0; i < max; i++) { patterns[i] = prefix + acceptedSuffixes[i]; } @@ -283,8 +293,10 @@ transformer.setParameter("extraPackages", extractedPackages); transformer.setURIResolver(fileResolver); - transformer.transform(new StreamSource(file), new StreamResult( - new FileOutputStream(result))); + transformer.transform( + new StreamSource(file), + new StreamResult(new FileOutputStream(result)) + ); } catch (Exception e) { throw new MojoExecutionException(e.getMessage(), e); Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2ObjectModel.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2ObjectModel.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2ObjectModel.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,22 +1,31 @@ -/* *##% +/* + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.plugin; import org.xml.sax.Attributes; @@ -101,10 +110,9 @@ */ protected class XmiVersionHandler extends DefaultHandler { - public String version = null; + public String version; public XmiVersionHandler() { - super(); } public String getVersion() { Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2StateModel.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2StateModel.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Xmi2StateModel.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,31 @@ -/* *##% +/* + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ + package org.nuiton.eugene.plugin; import java.io.File; Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Zargo2Xmi.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Zargo2Xmi.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/Zargo2Xmi.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,21 +1,31 @@ -/* *##% +/* + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%*/ + * #L% + */ + package org.nuiton.eugene.plugin; import org.nuiton.plugin.PluginHelper; Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/BaseChainedFileWriter.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/BaseChainedFileWriter.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/BaseChainedFileWriter.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.plugin.writer; import org.apache.maven.plugin.logging.Log; Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/ModelChainedFileWriter.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/ModelChainedFileWriter.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/ModelChainedFileWriter.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.plugin.writer; import org.apache.commons.lang.StringUtils; Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/XmiChainedFileWriter.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/XmiChainedFileWriter.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/XmiChainedFileWriter.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.plugin.writer; import org.nuiton.eugene.models.object.ObjectModel; @@ -49,7 +57,8 @@ import java.util.List; /** - * Implentation pour les writer to type xmi (qui transforme du xmi via xsl vers du model). + * Implentation pour les writer to type xmi (qui transforme du xmi via xsl + * vers du model). * * @author tchemit * @since 2.0.0 @@ -58,11 +67,15 @@ public class XmiChainedFileWriter extends BaseChainedFileWriter { public static final String PROP_RESOLVER = "resolver"; - // public static final String PROP_EXTRACTED_PACKAGES = "extractedPackages"; + public static final String PROP_FULL_PACKAGE_PATH = "fullPackagePath"; public XmiChainedFileWriter() { - super(PROP_RESOLVER, "resolver", PROP_FULL_PACKAGE_PATH, "fullPackagePath"); + super(PROP_RESOLVER, + "resolver", + PROP_FULL_PACKAGE_PATH, + "fullPackagePath" + ); } @Override @@ -71,22 +84,6 @@ return acceptObjectModelOrStateModel(modelType); } -// /** -// * Get style sheet. -// * -// * @param modelType model type used -// * @param model the model file used to determine the stylesheet to use -// * @return the stylesheet name -// */ -// protected abstract String getStyleSheet(String modelType, File model); - -// /** -// * Get extension. -// * -// * @return the extension -// */ -// protected abstract String getExtension(); - @Override public String getInputProtocol() { return "xmi"; @@ -141,35 +138,40 @@ return getProperty(PROP_FULL_PACKAGE_PATH, String.class); } -// public String getExtractedPackages() { -// return getProperty(PROP_EXTRACTED_PACKAGES, String.class); -// } - public String getResolver() { return getProperty(PROP_RESOLVER, String.class); } @Override - public void generate(ChainedFileWriterConfiguration configuration, File outputDir, File inputDirectory, String includePattern) throws IOException { + public void generate(ChainedFileWriterConfiguration configuration, + File outputDir, + File inputDirectory, + String includePattern) throws IOException { long t0 = System.nanoTime(); boolean overwrite = configuration.isOverwrite(); try { - getLog().info("Processing XSL tranformation on " + inputDirectory + " for " + includePattern); + getLog().info("Processing XSL tranformation on " + + inputDirectory + " for " + includePattern); getLog().info(" with fullPackagePath : " + getFullPackagePath()); -// getLog().info(" with extractedPackages : " + getExtractedPackages()); -// getLog().info(" with acceptedXmiTypes : " + getFullPackagePath()); getLog().info(" with resolver : " + getResolver()); // recuperation des fichiers a traiter - List<File> files = PluginHelper.getIncludedFiles(inputDirectory, new String[]{includePattern}, null); + List<File> files = PluginHelper.getIncludedFiles( + inputDirectory, new String[]{includePattern}, null); // lancement des traitements xsl sur les fichiers trouvés // dans le repertoire - actionXsl(configuration, outputDir, inputDirectory, files, overwrite); + actionXsl(configuration, + outputDir, + inputDirectory, + files, + overwrite + ); } finally { - getLog().info("xsl done in " + PluginHelper.convertTime(System.nanoTime() - t0)); + getLog().info("xsl done in " + + PluginHelper.convertTime(System.nanoTime() - t0)); } getLog().info("Copy resources files"); @@ -177,11 +179,18 @@ PluginIOContext ioContext = new PluginIOContext(); ioContext.setInput(inputDirectory); ioContext.setOutput(outputDir); -// String[] excludes = getSuffixPattern("**/*"); - PluginHelper.copyFiles(ioContext, null, new String[]{includePattern}, overwrite); + PluginHelper.copyFiles(ioContext, + null, + new String[]{includePattern}, + overwrite + ); } - protected void actionXsl(ChainedFileWriterConfiguration configuration, File outputDir, File dir, List<File> files, boolean overwrite) throws IOException { + protected void actionXsl(ChainedFileWriterConfiguration configuration, + File outputDir, + File dir, + List<File> files, + boolean overwrite) throws IOException { for (File file : files) { try { @@ -190,7 +199,8 @@ } // Prepare resolver, stylesheet URIResolver fileResolver = getUriResolver(configuration, file); - String styleSheet = getStyleSheet(configuration.getModelType(), file); + String styleSheet = + getStyleSheet(configuration.getModelType(), file); URL xsl = Resource.getURL(styleSheet); //TC-20090820 : using recursive for xmi @@ -198,16 +208,18 @@ // acceptedSuffixes).concat(".").concat(getExtension())); String extension = "." + FileUtil.extension(file); - String filename = FileUtil.basename(file, extension).concat(".").concat(configuration.getModelType()); -// String filename = FileUtil.basename(file, extension).concat(".").concat(getExtension()); - String relatifPath = file.getParentFile().getAbsolutePath().substring(dir.getAbsolutePath().length()); + String filename = FileUtil.basename(file, extension). + concat(".").concat(configuration.getModelType()); + String relatifPath = file.getParentFile().getAbsolutePath(). + substring(dir.getAbsolutePath().length()); File dstDir = outputDir; if (!relatifPath.isEmpty()) { dstDir = new File(dstDir, relatifPath); if (!dstDir.exists()) { boolean b = dstDir.mkdirs(); if (!b) { - throw new IOException("could not create directory " + dstDir); + throw new IOException( + "could not create directory " + dstDir); } } } @@ -221,14 +233,18 @@ } // Create the xsl transformer and set parameters - Transformer transformer = getTransformerFactory().newTransformer(new StreamSource(xsl.openStream())); + Transformer transformer = getTransformerFactory(). + newTransformer(new StreamSource(xsl.openStream())); - transformer.setParameter(PROP_FULL_PACKAGE_PATH, getFullPackagePath()); - //transformer.setParameter("extraPackages", getExtractedPackages()); + transformer.setParameter(PROP_FULL_PACKAGE_PATH, + getFullPackagePath() + ); transformer.setURIResolver(fileResolver); - transformer.transform(new StreamSource(file), new StreamResult( - new FileOutputStream(result))); + transformer.transform( + new StreamSource(file), + new StreamResult(new FileOutputStream(result)) + ); } catch (Exception e) { throw new IOException(e.getMessage(), e); @@ -236,7 +252,8 @@ } } - protected URIResolver getUriResolver(ChainedFileWriterConfiguration configuration, File model) { + protected URIResolver getUriResolver( + ChainedFileWriterConfiguration configuration, File model) { URIResolver result = null; try { @@ -246,13 +263,15 @@ // Try to set the base using the constructor try { // Look for a constructor with a String parameter (base) - Constructor<?> withBaseConstructor = clazz.getConstructor(String.class); + Constructor<?> withBaseConstructor = + clazz.getConstructor(String.class); // Set the xmi folder as the base String base = model.getParentFile().getAbsolutePath(); // Instantiate result = (URIResolver) withBaseConstructor.newInstance(base); } catch (Exception eee) { - getLog().warn("Unable to instantiate resolver with String parameter", + getLog().warn( + "Unable to instantiate resolver with String parameter", eee); } @@ -263,7 +282,8 @@ } if (result instanceof ResourceResolver) { - ((ResourceResolver) result).setVerbose(configuration.isVerbose()); + ((ResourceResolver) result).setVerbose( + configuration.isVerbose()); ((ResourceResolver) result).setCl(loader); if (result instanceof FasterCachedResourceResolver) { boolean offline = configuration.isOffline(); @@ -273,7 +293,8 @@ } } catch (Exception eee) { - getLog().warn("Unable to instantiate resolver using the default constructor", eee); + getLog().warn("Unable to instantiate resolver using " + + "the default constructor", eee); } return result; @@ -297,7 +318,8 @@ return "xmi1.2ToStateModel.xsl"; } - throw new IllegalStateException("unsupported modelType [" + modelType + "]"); + throw new IllegalStateException("unsupported modelType [" + + modelType + "]"); } /** @@ -334,10 +356,9 @@ */ protected class XmiVersionHandler extends DefaultHandler { - protected String version = null; + protected String version; public XmiVersionHandler() { - super(); } public String getVersion() { @@ -345,7 +366,9 @@ } @Override - public void startElement(String uri, String localName, String qName, + public void startElement(String uri, + String localName, + String qName, Attributes attributes) throws SAXException { if (qName.equals("XMI")) { Modified: trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/ZargoChainedFileWriter.java =================================================================== --- trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/ZargoChainedFileWriter.java 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/main/java/org/nuiton/eugene/plugin/writer/ZargoChainedFileWriter.java 2010-04-12 18:16:47 UTC (rev 860) @@ -1,23 +1,31 @@ /* - * *##% + * #%L * EUGene :: Maven plugin - * Copyright (C) 2006 - 2009 CodeLutin - * + * + * $Author$ + * $LastChangedDate$ + * $LastChangedRevision$ + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2006 - 2010 CodeLutin + * %% * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, either version 3 of the + * it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. - * + * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Lesser Public License for more details. - * - * You should have received a copy of the GNU General Lesser Public + * + * You should have received a copy of the GNU General Lesser Public * License along with this program. If not, see * <http://www.gnu.org/licenses/lgpl-3.0.html>. - * ##%* + * #L% */ + package org.nuiton.eugene.plugin.writer; import org.nuiton.eugene.writer.ChainedFileWriterConfiguration; @@ -36,7 +44,8 @@ */ public class ZargoChainedFileWriter extends BaseChainedFileWriter { - public static final String[] XMI_FILE_FILTER = new String[]{"*.xmi", "**/*.xmi"}; + public static final String[] XMI_FILE_FILTER = new String[]{"*.xmi", + "**/*.xmi"}; @Override public String getInputProtocol() { @@ -57,7 +66,8 @@ @Override public boolean acceptInclude(String include) { - return include.startsWith("zargo:") || include.endsWith(".zargo") || include.endsWith(".zuml"); + return include.startsWith("zargo:") || + include.endsWith(".zargo") || include.endsWith(".zuml"); } @Override @@ -86,7 +96,10 @@ } @Override - public void generate(ChainedFileWriterConfiguration configuration, File outputDir, File inputDirectory, String includePattern) throws IOException { + public void generate(ChainedFileWriterConfiguration configuration, + File outputDir, + File inputDirectory, + String includePattern) throws IOException { boolean overwrite = configuration.isOverwrite(); @@ -94,10 +107,23 @@ ioContext.setInput(inputDirectory); ioContext.setOutput(outputDir); - getLog().info("Expanding xmi from " + inputDirectory + " : " + includePattern); - PluginHelper.expandFiles(ioContext, new String[]{includePattern}, null, XMI_FILE_FILTER, overwrite); + getLog().info("Expanding xmi from " + inputDirectory + " : " + + includePattern); - getLog().info("Copying resources from " + inputDirectory + " : " + includePattern); - PluginHelper.copyFiles(ioContext, null, new String[]{includePattern}, overwrite); + PluginHelper.expandFiles(ioContext, + new String[]{includePattern}, + null, + XMI_FILE_FILTER, + overwrite + ); + + getLog().info("Copying resources from " + inputDirectory + " : " + + includePattern); + + PluginHelper.copyFiles(ioContext, + null, + new String[]{includePattern}, + overwrite + ); } } Modified: trunk/maven-eugene-plugin/src/site/fr/rst/example.rst =================================================================== --- trunk/maven-eugene-plugin/src/site/fr/rst/example.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/site/fr/rst/example.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -10,6 +10,34 @@ .. contents:: +.. - +.. * #%L +.. * EUGene :: Maven plugin +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2006 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Cette page regroupe deux examples de configuration/utilisation du plugin dans un pom. Le premier example est très simple, le second est plus complexe et est censé ammener une complète compréhension du plugin combiné à la Modified: trunk/maven-eugene-plugin/src/site/fr/rst/index.rst =================================================================== (Binary files differ) Modified: trunk/maven-eugene-plugin/src/site/fr/rst/usage.rst =================================================================== --- trunk/maven-eugene-plugin/src/site/fr/rst/usage.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/site/fr/rst/usage.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,15 +1,40 @@ Usage ===== - :Authors: Tony Chemit :Contact: chemit@codelutin.com :Revision: $Revision$ :Date: $Date$ - .. contents:: +.. - +.. * #%L +.. * EUGene :: Maven plugin +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2006 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - smart-generate -------------- Modified: trunk/maven-eugene-plugin/src/site/rst/example.rst =================================================================== --- trunk/maven-eugene-plugin/src/site/rst/example.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/site/rst/example.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,15 +1,41 @@ Examples ======== - :Authors: Jean Couteau :Contact: couteau@codelutin.com :Revision: $Revision$ :Date: $Date$ - .. contents:: +.. - +.. * #%L +.. * EUGene :: Maven plugin +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2006 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + This page groups two plugin configuration/usage examples in a pom. The first example is very simple, the second is more complex and aimed to bring a better understanding of the plugin combined with the usages_ documentation. Modified: trunk/maven-eugene-plugin/src/site/rst/index.rst =================================================================== (Binary files differ) Modified: trunk/maven-eugene-plugin/src/site/rst/usage.rst =================================================================== --- trunk/maven-eugene-plugin/src/site/rst/usage.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/site/rst/usage.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,15 +1,44 @@ Usage ===== - :Authors: Tony Chemit :Contact: chemit@codelutin.com :Revision: $Revision$ :Date: $Date$ - .. contents:: +.. - +.. * #%L +.. * EUGene :: Maven plugin +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2006 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + +Abstract +~~~~~~~~ + This page describes the usage of the goals of the eugene plugin. smart-generate Modified: trunk/maven-eugene-plugin/src/site/site_en.xml =================================================================== --- trunk/maven-eugene-plugin/src/site/site_en.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/site/site_en.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: Maven plugin + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2006 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project name="${project.name}"> <bannerLeft> Modified: trunk/maven-eugene-plugin/src/site/site_fr.xml =================================================================== --- trunk/maven-eugene-plugin/src/site/site_fr.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/maven-eugene-plugin/src/site/site_fr.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene :: Maven plugin + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2006 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project name="${project.name}"> <bannerLeft> Modified: trunk/pom.xml =================================================================== --- trunk/pom.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/pom.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2004 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> Modified: trunk/src/license/project.xml =================================================================== --- trunk/src/license/project.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/license/project.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version='1.0' encoding='UTF-8'?> +<!-- + #%L + EUGene + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2004 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project xmlns="http://maven-site.nuiton.org/maven-license-plugin/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven-site.nuiton.org/maven-license-plugin/1.0.0 http://maven-site.nuiton.org/maven-license-plugin/licenseProjectDescriptor-1.0.0.xsd"> @@ -18,7 +46,7 @@ <include>**/*.java</include> </fileSet> <fileSet> - <basedir>src/target/generated-sources/modello</basedir> + <basedir>target/processed-sources/java</basedir> <include>**/*.java</include> </fileSet> </fileSets> Modified: trunk/src/site/fr/rst/01-introduction.rst =================================================================== --- trunk/src/site/fr/rst/01-introduction.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/01-introduction.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -9,6 +9,33 @@ .. contents:: +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - Qu'est ce le MDA (Model Driven Architecture) -------------------------------------------- Modified: trunk/src/site/fr/rst/02-objectmodel.rst =================================================================== --- trunk/src/site/fr/rst/02-objectmodel.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/02-objectmodel.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -15,6 +15,34 @@ TODO : revoir cette documentation +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Introduction ============ Modified: trunk/src/site/fr/rst/03-generation.rst =================================================================== --- trunk/src/site/fr/rst/03-generation.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/03-generation.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -6,6 +6,34 @@ :Revision: $Revision$ :Date: $Date$ +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Le principe de génération réside en trois points : - Fichiers d'entrée, représentant un modèle de données concret Modified: trunk/src/site/fr/rst/04-templates.rst =================================================================== --- trunk/src/site/fr/rst/04-templates.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/04-templates.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -6,6 +6,34 @@ :Revision: $Revision$ :Date: $Date$ +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Comme expliqué dans le chapitre précédent (`Processus de generation`_ ), il y a deux possibilités pour générer des fichiers : Modified: trunk/src/site/fr/rst/05-execution.rst =================================================================== --- trunk/src/site/fr/rst/05-execution.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/05-execution.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -6,6 +6,34 @@ :Revision: $Revision$ :Date: $Date$ +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Pour mettre en oeuvre la génération en utilisant EUGene, il est possible d'utiliser les principaux utilitaires de build : `Ant`_ et `Maven`_ Modified: trunk/src/site/fr/rst/06-fonctionnalites-avancees.rst =================================================================== --- trunk/src/site/fr/rst/06-fonctionnalites-avancees.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/06-fonctionnalites-avancees.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -6,6 +6,34 @@ :Revision: $Revision$ :Date: $Date$ +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Ce chapitre concerne les fonctionnalités avancées d'EUGene, c'est à dire, comment étendre EUGene pour l'adapter à un autre modèle que l'ObjectModel ou comment étendre ce dernier par le biais des extensions. Modified: trunk/src/site/fr/rst/07-glossaire.rst =================================================================== --- trunk/src/site/fr/rst/07-glossaire.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/07-glossaire.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,6 +1,34 @@ Glossaire ========= +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + MDA --- Modified: trunk/src/site/fr/rst/08-FAQ.rst =================================================================== --- trunk/src/site/fr/rst/08-FAQ.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/08-FAQ.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -2,6 +2,34 @@ FAQ === +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Comment convertir les modèles UML de Poseidon vers ArgoUML ? ============================================================ Modified: trunk/src/site/fr/rst/09-tutoriel-index.rst =================================================================== --- trunk/src/site/fr/rst/09-tutoriel-index.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/09-tutoriel-index.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -0,0 +1,33 @@ +============== +Tutorial index +============== + +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + +TODO \ No newline at end of file Modified: trunk/src/site/fr/rst/eugene-plan.rst =================================================================== --- trunk/src/site/fr/rst/eugene-plan.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/eugene-plan.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,4 @@ +============================= Plan documentation EUGene 2.0 ============================= @@ -5,6 +6,37 @@ :Date: 18 fév. 2010 :Version: 1.1 +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + +Plan documentation EUGene 2.0 +============================= + - Introduction * C'est quoi le MDA Modified: trunk/src/site/fr/rst/index.rst =================================================================== --- trunk/src/site/fr/rst/index.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/fr/rst/index.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -2,6 +2,34 @@ EUGene ====== +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + **E**fficient **U**niversal **Gene**rator Vous trouverez dans cette documentation : Modified: trunk/src/site/rst/01-introduction.rst =================================================================== --- trunk/src/site/rst/01-introduction.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/01-introduction.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -8,6 +8,34 @@ .. contents:: +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + What is MDA (Model Driven Architecture) --------------------------------------- Modified: trunk/src/site/rst/02-objectmodel.rst =================================================================== --- trunk/src/site/rst/02-objectmodel.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/02-objectmodel.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -13,6 +13,35 @@ .. contents:: +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + + TODO : revoir cette documentation Introduction Modified: trunk/src/site/rst/03-generation.rst =================================================================== --- trunk/src/site/rst/03-generation.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/03-generation.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -6,6 +6,34 @@ :Revision: $Revision$ :Date: $Date$ +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Generation principle is split into three points : - Input files, representing a data model Modified: trunk/src/site/rst/04-templates.rst =================================================================== --- trunk/src/site/rst/04-templates.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/04-templates.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -6,6 +6,34 @@ :Revision: $Revision$ :Date: $Date$ +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + Like explained in the previous chapter (`Generation process`_ ), there are two ways to generate files : Modified: trunk/src/site/rst/05-execution.rst =================================================================== --- trunk/src/site/rst/05-execution.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/05-execution.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,3 +1,4 @@ +========= Execution ========= @@ -6,6 +7,34 @@ :Revision: $Revision$ :Date: $Date$ +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + To put into place generation using EUGene, it is possible to use main build utilities : `Ant`_ and `Maven`_ Modified: trunk/src/site/rst/06-fonctionnalites-avancees.rst =================================================================== --- trunk/src/site/rst/06-fonctionnalites-avancees.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/06-fonctionnalites-avancees.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,6 +1,34 @@ Advanced functionalities ======================== +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + :Author: Florian Desbois, Jean Couteau :Contact: eugene-devel@list.nuiton.org or eugene-users@list.nuiton.org :Revision: $Revision$ Modified: trunk/src/site/rst/07-glossaire.rst =================================================================== --- trunk/src/site/rst/07-glossaire.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/07-glossaire.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -1,6 +1,34 @@ Glossary ======== +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + MDA --- Modified: trunk/src/site/rst/08-FAQ.rst =================================================================== --- trunk/src/site/rst/08-FAQ.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/08-FAQ.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -2,6 +2,34 @@ FAQ === +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + How to convert UML models from Poseidon to AgroUML ? ==================================================== Modified: trunk/src/site/rst/09-tutoriel-index.rst =================================================================== --- trunk/src/site/rst/09-tutoriel-index.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/09-tutoriel-index.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -0,0 +1,33 @@ +============== +Tutoriel index +============== + +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + +TODO \ No newline at end of file Modified: trunk/src/site/rst/index.rst =================================================================== --- trunk/src/site/rst/index.rst 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/rst/index.rst 2010-04-12 18:16:47 UTC (rev 860) @@ -2,6 +2,34 @@ EUGene ====== +.. - +.. * #%L +.. * EUGene +.. * +.. * $Author$ +.. * $LastChangedDate$ +.. * $LastChangedRevision$ +.. * $Id$ +.. * $HeadURL$ +.. * %% +.. * Copyright (C) 2004 - 2010 CodeLutin +.. * %% +.. * This program is free software: you can redistribute it and/or modify +.. * it under the terms of the GNU Lesser General Public License as +.. * published by the Free Software Foundation, either version 3 of the +.. * License, or (at your option) any later version. +.. * +.. * This program is distributed in the hope that it will be useful, +.. * but WITHOUT ANY WARRANTY; without even the implied warranty of +.. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +.. * GNU General Lesser Public License for more details. +.. * +.. * You should have received a copy of the GNU General Lesser Public +.. * License along with this program. If not, see +.. * <http://www.gnu.org/licenses/lgpl-3.0.html>. +.. * #L% +.. - + **E**fficient **U**niversal **Gene**rator You will find in this documentation : Modified: trunk/src/site/site_en.xml =================================================================== --- trunk/src/site/site_en.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/site_en.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2004 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project name="${project.name}"> <bannerLeft> Modified: trunk/src/site/site_fr.xml =================================================================== --- trunk/src/site/site_fr.xml 2010-04-12 16:10:10 UTC (rev 859) +++ trunk/src/site/site_fr.xml 2010-04-12 18:16:47 UTC (rev 860) @@ -1,4 +1,32 @@ <?xml version="1.0" encoding="UTF-8"?> +<!-- + #%L + EUGene + + $Author$ + $LastChangedDate$ + $LastChangedRevision$ + $Id$ + $HeadURL$ + %% + Copyright (C) 2004 - 2010 CodeLutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Lesser Public License for more details. + + You should have received a copy of the GNU General Lesser Public + License along with this program. If not, see + <http://www.gnu.org/licenses/lgpl-3.0.html>. + #L% + --> + <project name="${project.name}"> <bannerLeft>