[Buix-commits] r1521 - in trunk/guix-compiler/src/main/java/org/nuiton/guix: generator tags
Author: kmorin Date: 2009-07-23 17:30:02 +0200 (Thu, 23 Jul 2009) New Revision: 1521 Modified: trunk/guix-compiler/src/main/java/org/nuiton/guix/generator/GuixGenerator.java trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/ApplicationHandler.java trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/DefaultTagHandler.java trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/PanelHandler.java trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/TagHandler.java Log: Add javadoc + licences Modified: trunk/guix-compiler/src/main/java/org/nuiton/guix/generator/GuixGenerator.java =================================================================== --- trunk/guix-compiler/src/main/java/org/nuiton/guix/generator/GuixGenerator.java 2009-07-23 14:46:10 UTC (rev 1520) +++ trunk/guix-compiler/src/main/java/org/nuiton/guix/generator/GuixGenerator.java 2009-07-23 15:30:02 UTC (rev 1521) @@ -50,9 +50,14 @@ protected List<File> cssFiles = null; /** Name to give to the generated launcher*/ protected String launcherName = null; - /** */ + /** Maps the field name with a map of the attribute and its value */ protected Map<String,Map<String, String>> bindings2Generate = new HashMap<String,Map<String, String>>(); + /** + * Generates a JavaFile + * + * @return the JavaFile generated + */ public abstract JavaFile generate(); public File getDestDir() { @@ -128,8 +133,26 @@ this.bindings2Generate = bindings2Generate; } + /** + * Saves the generated files + */ public abstract void saveFiles(); + /** + * Checks if the objects of the binding exist + * + * @param dbCreation the method code to apply the binding + * @param dbDeletion the method code to remove the binding + * @param prevTh the TagHandler of the parent of the object inspected + * @param jf the javaFile of the inspected object (null if it is not a generated object) + * @param clazz the clazz of the inspected object (null if it is a generated object) + * @param binding the array containing the name of the objects to check + * @param i the index of the being checked object + * @param alreadyChecked list of the already checked objects + * @param methodToInvoke the name of the method which will process the databinding + * @param generatedFiles maps the GuixGenerator with its JavaFile + * @return the list of the listeners to add to the objects for the databinding + */ public abstract List<Class> generateBindings(StringBuffer dbCreation, StringBuffer dbDeletion, TagHandler prevTh, JavaFile jf, Class clazz, String[] binding, int i, List<String> alreadyChecked, String methodToInvoke, Map<GuixGenerator,JavaFile> generatedFiles); } Modified: trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/ApplicationHandler.java =================================================================== --- trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/ApplicationHandler.java 2009-07-23 14:46:10 UTC (rev 1520) +++ trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/ApplicationHandler.java 2009-07-23 15:30:02 UTC (rev 1521) @@ -1,13 +1,27 @@ -/* - * To change this template, choose Tools | Templates - * and open the template in the editor. +/** + * *##% guix-compiler + * Copyright (C) 2009 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>. ##%* */ package org.nuiton.guix.tags; /** - * - * @author kevin + * Application Handler for the tests + * @author kmorin */ public abstract class ApplicationHandler extends DefaultTagHandler { Modified: trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/DefaultTagHandler.java =================================================================== --- trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/DefaultTagHandler.java 2009-07-23 14:46:10 UTC (rev 1520) +++ trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/DefaultTagHandler.java 2009-07-23 15:30:02 UTC (rev 1521) @@ -1,14 +1,27 @@ -/* - * To change this template, choose Tools | Templates - * and open the template in the editor. +/** + * *##% guix-compiler + * Copyright (C) 2009 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>. ##%* */ +package org.nuiton.guix.tags; -package org.nuiton.guix.tags; import java.beans.BeanInfo; import java.beans.EventSetDescriptor; import java.beans.IntrospectionException; import java.beans.Introspector; -import java.beans.MethodDescriptor; import java.beans.PropertyDescriptor; import java.lang.reflect.Field; import java.lang.reflect.Method; @@ -18,11 +31,13 @@ import org.nuiton.guix.UnsupportedAttributeException; /** + * Default TagHandler, containing common methods for all the tags * - * @author kevin + * @author kmorin */ public abstract class DefaultTagHandler implements TagHandler { + /** Maps the common name for an attribute with its real name for the class to generate */ protected Map<String,String> attrMap = new HashMap<String,String>(); /** Maps property names to their respective ProxyEventInfos. */ Modified: trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/PanelHandler.java =================================================================== --- trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/PanelHandler.java 2009-07-23 14:46:10 UTC (rev 1520) +++ trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/PanelHandler.java 2009-07-23 15:30:02 UTC (rev 1521) @@ -1,13 +1,27 @@ -/* - * To change this template, choose Tools | Templates - * and open the template in the editor. +/** + * *##% guix-compiler + * Copyright (C) 2009 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>. ##%* */ - package org.nuiton.guix.tags; /** + * Panel Handler for the tests * - * @author kevin + * @author kmorin */ public abstract class PanelHandler extends DefaultTagHandler { Modified: trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/TagHandler.java =================================================================== --- trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/TagHandler.java 2009-07-23 14:46:10 UTC (rev 1520) +++ trunk/guix-compiler/src/main/java/org/nuiton/guix/tags/TagHandler.java 2009-07-23 15:30:02 UTC (rev 1521) @@ -1,13 +1,29 @@ -/* - * To change this template, choose Tools | Templates - * and open the template in the editor. +/** + * *##% guix-compiler + * Copyright (C) 2009 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>. ##%* */ - package org.nuiton.guix.tags; /** + * Interface of the tag handlers. + * It permits to get the right class or the right attribiute names to generate for the common tags. + * It also permits to know which listeners to add for the binding * - * @author kevin + * @author kmorin */ public interface TagHandler {
participants (1)
-
kmorin@users.labs.libre-entreprise.org