Hi,
The rules from checkstlye are quite different than the IDE code formatter
templates we were recommending. For example, the template for Eclipse sets
the maximum characters per line to 150 while the checkstyle complains at
120.
Which one should we follow? If it's the checkstyle, then we should update
the IDE templates so that we are not confused.
Thanks,
Raymond
----- Original Message -----
From: "Jim Marino" <[EMAIL PROTECTED]>
To: <tuscany-dev@ws.apache.org>
Sent: Tuesday, August 29, 2006 1:12 AM
Subject: Fwd: svn commit: r438000
Hi Raymond,
Could you please make sure you format this code: mvn -Psourcecheck? It
breaks Checkstyle.
Thanks,
Jim
Begin forwarded message:
From: [EMAIL PROTECTED]
Date: August 29, 2006 1:00:16 AM PDT
To: tuscany-commits@ws.apache.org
Subject: svn commit: r438000 - in /incubator/tuscany/java/sca/core/ src:
main/java/org/apache/tuscany/core/loader/ComponentLoader.java
test/java/org/apache/tuscany/core/loader/ComponentLoaderTestCase.java
Reply-To: tuscany-dev@ws.apache.org
Author: rfeng
Date: Tue Aug 29 01:00:16 2006
New Revision: 438000
URL: http://svn.apache.org/viewvc?rev=438000&view=rev
Log:
Make sure the StAX loading only ends upon </component>
Modified:
incubator/tuscany/java/sca/core/src/main/java/org/apache/
tuscany/core/loader/ComponentLoader.java
incubator/tuscany/java/sca/core/src/test/java/org/apache/
tuscany/core/loader/ComponentLoaderTestCase.java
Modified: incubator/tuscany/java/sca/core/src/main/java/org/apache/
tuscany/core/loader/ComponentLoader.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/core/
src/main/java/org/apache/tuscany/core/loader/ComponentLoader.java?
rev=438000&r1=437999&r2=438000&view=diff
======================================================================
========
--- incubator/tuscany/java/sca/core/src/main/java/org/apache/
tuscany/core/loader/ComponentLoader.java (original)
+++ incubator/tuscany/java/sca/core/src/main/java/org/apache/
tuscany/core/loader/ComponentLoader.java Tue Aug 29 01:00:16 2006
@@ -113,7 +113,8 @@
reader.next();
break;
case END_ELEMENT:
- return componentDefinition;
+ if(reader.getName().equals(COMPONENT))
+ return componentDefinition;
}
}
} catch (LoaderException e) {
Modified: incubator/tuscany/java/sca/core/src/test/java/org/apache/
tuscany/core/loader/ComponentLoaderTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/core/
src/test/java/org/apache/tuscany/core/loader/
ComponentLoaderTestCase.java?rev=438000&r1=437999&r2=438000&view=diff
======================================================================
========
--- incubator/tuscany/java/sca/core/src/test/java/org/apache/
tuscany/core/loader/ComponentLoaderTestCase.java (original)
+++ incubator/tuscany/java/sca/core/src/test/java/org/apache/
tuscany/core/loader/ComponentLoaderTestCase.java Tue Aug 29 01:00:16
2006
@@ -57,7 +57,7 @@
private ComponentLoader loader;
public void testEmptyComponent() throws LoaderException,
XMLStreamException {
- mockReader.expects(once()).method("getName").will
(returnValue(COMPONENT));
+ mockReader.expects(atLeastOnce()).method("getName").will
(returnValue(COMPONENT));
mockReader.expects(atLeastOnce()).method("getAttributeValue")
.with(ANYTHING, ANYTHING)
.will(onConsecutiveCalls(returnValue(NAME), returnValue
(null)));
@@ -71,7 +71,7 @@
}
public void testInitValue20() throws LoaderException,
XMLStreamException {
- mockReader.expects(once()).method("getName").will
(returnValue(COMPONENT));
+ mockReader.expects(atLeastOnce()).method("getName").will
(returnValue(COMPONENT));
mockReader.expects(atLeastOnce()).method("getAttributeValue")
.with(ANYTHING, ANYTHING)
.will(onConsecutiveCalls(returnValue(NAME), returnValue
("20")));
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]