Return-Path: Delivered-To: apmail-beehive-commits-archive@www.apache.org Received: (qmail 47276 invoked from network); 14 Mar 2006 21:10:47 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 14 Mar 2006 21:10:47 -0000 Received: (qmail 69874 invoked by uid 500); 14 Mar 2006 21:10:47 -0000 Delivered-To: apmail-beehive-commits-archive@beehive.apache.org Received: (qmail 69793 invoked by uid 500); 14 Mar 2006 21:10:46 -0000 Mailing-List: contact commits-help@beehive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Beehive Dev" Delivered-To: mailing list commits@beehive.apache.org Received: (qmail 69775 invoked by uid 99); 14 Mar 2006 21:10:46 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 14 Mar 2006 13:10:46 -0800 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.29) with SMTP; Tue, 14 Mar 2006 13:10:45 -0800 Received: (qmail 47120 invoked by uid 65534); 14 Mar 2006 21:10:25 -0000 Message-ID: <20060314211025.47119.qmail@minotaur.apache.org> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r385891 - in /beehive/trunk/netui: src/core/org/apache/beehive/netui/core/chain/ src/util/org/apache/beehive/netui/util/config/bean/ src/util/org/apache/beehive/netui/util/config/internal/ src/util/org/apache/beehive/netui/util/config/inter... Date: Tue, 14 Mar 2006 21:10:21 -0000 To: commits@beehive.apache.org From: ekoneil@apache.org X-Mailer: svnmailer-1.0.7 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Author: ekoneil Date: Tue Mar 14 13:10:19 2006 New Revision: 385891 URL: http://svn.apache.org/viewcvs?rev=385891&view=rev Log: Rework the definition of a element from: ... to: ... ... ... so that while it's more verbose to author, it's more symmetric with the rest of the beehive-netui-config.xsd definition. BB: self Test: NetUI BVT pass Modified: beehive/trunk/netui/src/core/org/apache/beehive/netui/core/chain/CatalogFactory.java beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/bean/CommandConfig.java beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/beehive-netui-config-default.xml beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/CatalogParser.java beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/catalog-config.xsd beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/schema/beehive-netui-config.xsd beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/CatalogParserTest.java beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/xmls/simple-chain.xml beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/util/config/xmls/beehive-netui-config-with-chain.xml Modified: beehive/trunk/netui/src/core/org/apache/beehive/netui/core/chain/CatalogFactory.java URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/src/core/org/apache/beehive/netui/core/chain/CatalogFactory.java?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/src/core/org/apache/beehive/netui/core/chain/CatalogFactory.java (original) +++ beehive/trunk/netui/src/core/org/apache/beehive/netui/core/chain/CatalogFactory.java Tue Mar 14 13:10:19 2006 @@ -86,7 +86,7 @@ } else { Command command = createCommand(commandConfig); - catalog.addCommand(commandConfig.getName(), command); + catalog.addCommand(commandConfig.getId(), command); } } catalogFactory.setCatalog(catalog); Modified: beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/bean/CommandConfig.java URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/bean/CommandConfig.java?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/bean/CommandConfig.java (original) +++ beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/bean/CommandConfig.java Tue Mar 14 13:10:19 2006 @@ -26,7 +26,6 @@ */ public class CommandConfig { - private String _name; private String _id; private String _classname; private LinkedList _parameters; @@ -45,14 +44,6 @@ public void setId(String id) { _id = id; - } - - public String getName() { - return _name; - } - - public void setName(String name) { - _name = name; } public String getClassname() { Modified: beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/beehive-netui-config-default.xml URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/beehive-netui-config-default.xml?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/beehive-netui-config-default.xml (original) +++ beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/beehive-netui-config-default.xml Tue Mar 14 13:10:19 2006 @@ -51,8 +51,12 @@ - - + + org.apache.beehive.netui.tags.tree.TreeCRI + + + org.apache.beehive.netui.tags.divpanel.DivPanelCRI + Modified: beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/CatalogParser.java URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/CatalogParser.java?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/CatalogParser.java (original) +++ beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/CatalogParser.java Tue Mar 14 13:10:19 2006 @@ -79,7 +79,7 @@ db.setEntityResolver(new EntityResolver() { public InputSource resolveEntity(String publicId, String systemId) { - if(systemId.endsWith("/chain-config.xsd")) { + if(systemId.endsWith("/catalog-config.xsd")) { InputStream inputStream = getClass().getClassLoader().getResourceAsStream(CONFIG_SCHEMA); return new InputSource(inputStream); } @@ -138,9 +138,7 @@ } else if(node.getNodeName().equals("command")) { Element element = (Element)node; - String name = element.getAttribute("name"); CommandConfig commandConfig = parseCommand(element); - commandConfig.setName(name); catalogConfig.addCommand(commandConfig); } } @@ -155,8 +153,8 @@ assert element.getNodeName().equals("command"); CommandConfig commandConfig = new CommandConfig(); - String id = element.getAttribute("id"); - String classname = element.getAttribute("classname"); + String id = DomUtils.getChildElementText(element, "id"); + String classname = DomUtils.getChildElementText(element, "command-class"); commandConfig.setId(id); commandConfig.setClassname(classname); Modified: beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/catalog-config.xsd URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/catalog-config.xsd?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/catalog-config.xsd (original) +++ beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/internal/catalog/catalog-config.xsd Tue Mar 14 13:10:19 2006 @@ -40,11 +40,10 @@ + + - - - Modified: beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/schema/beehive-netui-config.xsd URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/schema/beehive-netui-config.xsd?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/schema/beehive-netui-config.xsd (original) +++ beehive/trunk/netui/src/util/org/apache/beehive/netui/util/config/schema/beehive-netui-config.xsd Tue Mar 14 13:10:19 2006 @@ -327,11 +327,10 @@ + + - - - Modified: beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/CatalogParserTest.java URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/CatalogParserTest.java?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/CatalogParserTest.java (original) +++ beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/CatalogParserTest.java Tue Mar 14 13:10:19 2006 @@ -59,6 +59,7 @@ Catalog catalog = catalogFactory.getCatalog(); Command command = catalog.getCommand("configurable"); ConfigurableCommand configurableCommand = (ConfigurableCommand)command; + assertNotNull(configurableCommand); assertEquals(54321, configurableCommand.getBar()); assertEquals("Homer", configurableCommand.getFoo()); Modified: beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/xmls/simple-chain.xml URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/xmls/simple-chain.xml?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/xmls/simple-chain.xml (original) +++ beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/core/chain/xmls/simple-chain.xml Tue Mar 14 13:10:19 2006 @@ -2,25 +2,33 @@ - + + 1 + org.apache.beehive.netui.test.core.chain.commands.EchoCommand message echo 1 - + + 2 + org.apache.beehive.netui.test.core.chain.commands.EchoCommand message echo 2 - + + 3 + org.apache.beehive.netui.test.core.chain.commands.EchoCommand message echo 3 - + + 4 + org.apache.beehive.netui.test.core.chain.commands.EchoCommand message echo 4 @@ -28,20 +36,26 @@ - + + 1 + org.apache.beehive.netui.test.core.chain.commands.EchoCommand message echo aaa - + + 2 + org.apache.beehive.netui.test.core.chain.commands.EchoCommand message echo bbb - + + configurable + org.apache.beehive.netui.test.core.chain.commands.ConfigurableCommand foo Homer Modified: beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/util/config/xmls/beehive-netui-config-with-chain.xml URL: http://svn.apache.org/viewcvs/beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/util/config/xmls/beehive-netui-config-with-chain.xml?rev=385891&r1=385890&r2=385891&view=diff ============================================================================== --- beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/util/config/xmls/beehive-netui-config-with-chain.xml (original) +++ beehive/trunk/netui/test/src/junitTests/org/apache/beehive/netui/test/util/config/xmls/beehive-netui-config-with-chain.xml Tue Mar 14 13:10:19 2006 @@ -49,8 +49,14 @@ - - + + 1 + Foobar + + + 2 + Raboof +