You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@twill.apache.org by ch...@apache.org on 2014/04/21 20:10:34 UTC

git commit: Enable stricter checkstyle rule for whitespace around LCURLY

Repository: incubator-twill
Updated Branches:
  refs/heads/master 9393df80b -> 2e52a947c


Enable stricter checkstyle rule for whitespace around LCURLY

Project: http://git-wip-us.apache.org/repos/asf/incubator-twill/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-twill/commit/2e52a947
Tree: http://git-wip-us.apache.org/repos/asf/incubator-twill/tree/2e52a947
Diff: http://git-wip-us.apache.org/repos/asf/incubator-twill/diff/2e52a947

Branch: refs/heads/master
Commit: 2e52a947cee9ec4662e24e9d099b43f0f35d3de8
Parents: 9393df8
Author: Terence Yim <te...@continuuity.com>
Authored: Mon Apr 21 11:10:28 2014 -0700
Committer: Terence Yim <te...@continuuity.com>
Committed: Mon Apr 21 11:10:28 2014 -0700

----------------------------------------------------------------------
 checkstyle.xml                                               | 4 ++--
 .../java/org/apache/twill/api/ResourceSpecification.java     | 8 ++++----
 .../twill/internal/json/ResourceSpecificationCodecTest.java  | 2 +-
 .../java/org/apache/twill/internal/yarn/YarnAMClient.java    | 2 +-
 4 files changed, 8 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-twill/blob/2e52a947/checkstyle.xml
----------------------------------------------------------------------
diff --git a/checkstyle.xml b/checkstyle.xml
index 6404c8f..8729af2 100644
--- a/checkstyle.xml
+++ b/checkstyle.xml
@@ -326,11 +326,11 @@ page at http://checkstyle.sourceforge.net/config.html -->
       -->
       <property name="tokens" value="ASSIGN, BAND, BAND_ASSIGN, BOR,
         BOR_ASSIGN, BSR, BSR_ASSIGN, BXOR, BXOR_ASSIGN, COLON, DIV, DIV_ASSIGN,
-        EQUAL, GE, GT, LAND, LCURLY, LE, LITERAL_CATCH, LITERAL_DO, LITERAL_ELSE,
+        EQUAL, GE, GT, LAND, LE, LITERAL_CATCH, LITERAL_DO, LITERAL_ELSE,
         LITERAL_FINALLY, LITERAL_FOR, LITERAL_IF, LITERAL_RETURN,
         LITERAL_SYNCHRONIZED, LITERAL_TRY, LITERAL_WHILE, LOR, LT, MINUS,
         MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN, QUESTION,
-        SL, SL_ASSIGN, SR_ASSIGN, STAR, STAR_ASSIGN"/>
+        SL, SLIST, SL_ASSIGN, SR_ASSIGN, STAR, STAR_ASSIGN"/>
       <property name="allowEmptyConstructors" value="true"/>
       <property name="allowEmptyMethods" value="true"/>
       <property name="severity" value="error"/>

http://git-wip-us.apache.org/repos/asf/incubator-twill/blob/2e52a947/twill-api/src/main/java/org/apache/twill/api/ResourceSpecification.java
----------------------------------------------------------------------
diff --git a/twill-api/src/main/java/org/apache/twill/api/ResourceSpecification.java b/twill-api/src/main/java/org/apache/twill/api/ResourceSpecification.java
index 7600041..4b602bc 100644
--- a/twill-api/src/main/java/org/apache/twill/api/ResourceSpecification.java
+++ b/twill-api/src/main/java/org/apache/twill/api/ResourceSpecification.java
@@ -164,8 +164,8 @@ public interface ResourceSpecification {
         return new Done();
       }
 
-      public Done setRacks(Iterable<String> racks){
-        if (racks != null){
+      public Done setRacks(Iterable<String> racks) {
+        if (racks != null) {
           Iterables.addAll(Builder.this.racks, racks);
         }
         return new Done();
@@ -180,8 +180,8 @@ public interface ResourceSpecification {
         return new AfterHosts();
       }
 
-      public AfterHosts setHosts(Iterable<String> hosts){
-        if (hosts != null){
+      public AfterHosts setHosts(Iterable<String> hosts) {
+        if (hosts != null) {
           Iterables.addAll(Builder.this.hosts, hosts);
         }
         return new AfterHosts();

http://git-wip-us.apache.org/repos/asf/incubator-twill/blob/2e52a947/twill-core/src/test/java/org/apache/twill/internal/json/ResourceSpecificationCodecTest.java
----------------------------------------------------------------------
diff --git a/twill-core/src/test/java/org/apache/twill/internal/json/ResourceSpecificationCodecTest.java b/twill-core/src/test/java/org/apache/twill/internal/json/ResourceSpecificationCodecTest.java
index 96f272c..e8b0eff 100644
--- a/twill-core/src/test/java/org/apache/twill/internal/json/ResourceSpecificationCodecTest.java
+++ b/twill-core/src/test/java/org/apache/twill/internal/json/ResourceSpecificationCodecTest.java
@@ -29,7 +29,7 @@ import org.unitils.reflectionassert.ReflectionAssert;
 import java.util.Arrays;
 
 /**
- * Maybe this checkstyle rule needs to be removed
+ * Maybe this checkstyle rule needs to be removed.
  */
 public class ResourceSpecificationCodecTest {
   private final Gson gson = new GsonBuilder().serializeNulls()

http://git-wip-us.apache.org/repos/asf/incubator-twill/blob/2e52a947/twill-yarn/src/main/java/org/apache/twill/internal/yarn/YarnAMClient.java
----------------------------------------------------------------------
diff --git a/twill-yarn/src/main/java/org/apache/twill/internal/yarn/YarnAMClient.java b/twill-yarn/src/main/java/org/apache/twill/internal/yarn/YarnAMClient.java
index 6a5ee36..a5a061a 100644
--- a/twill-yarn/src/main/java/org/apache/twill/internal/yarn/YarnAMClient.java
+++ b/twill-yarn/src/main/java/org/apache/twill/internal/yarn/YarnAMClient.java
@@ -72,7 +72,7 @@ public interface YarnAMClient extends Service {
     public abstract String apply();
 
     private <T> ContainerRequestBuilder add(Collection<T> collection, Collection<T> more) {
-      if (more != null){
+      if (more != null) {
         collection.addAll(more);
       }
       return this;