You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lo...@apache.org on 2012/04/18 11:17:35 UTC

svn commit: r1327431 - in /myfaces/tobago/branches/tobago-tree-table: tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/ tobago-core/src/main/java/org/apache/myfaces/tobago/model/ tobago-example/tobago-example-test/src/main/java/or...

Author: lofwyr
Date: Wed Apr 18 09:17:34 2012
New Revision: 1327431

URL: http://svn.apache.org/viewvc?rev=1327431&view=rev
Log:
checkstyle

Modified:
    myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java
    myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/ExpandedState.java
    myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/MarkedState.java
    myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeDataModel.java
    myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeState.java
    myfaces/tobago/branches/tobago-tree-table/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/TreeController.java
    myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRendererBase.java
    myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/util/RenderUtils.java

Modified: myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java?rev=1327431&r1=1327430&r2=1327431&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java (original)
+++ myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIData.java Wed Apr 18 09:17:34 2012
@@ -178,7 +178,7 @@ public abstract class AbstractUIData ext
   public TreePath getPath() {
     final DataModel model = getDataModel();
     if (model instanceof TreeDataModel) {
-      return ((TreeDataModel)model).getPath();
+      return ((TreeDataModel) model).getPath();
     } else {
       throw new IllegalStateException("Not a tree model");
     }

Modified: myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/ExpandedState.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/ExpandedState.java?rev=1327431&r1=1327430&r2=1327431&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/ExpandedState.java (original)
+++ myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/ExpandedState.java Wed Apr 18 09:17:34 2012
@@ -1,5 +1,22 @@
 package org.apache.myfaces.tobago.model;
 
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 

Modified: myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/MarkedState.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/MarkedState.java?rev=1327431&r1=1327430&r2=1327431&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/MarkedState.java (original)
+++ myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/MarkedState.java Wed Apr 18 09:17:34 2012
@@ -1,5 +1,22 @@
 package org.apache.myfaces.tobago.model;
 
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
 import java.io.Serializable;
 
 public class MarkedState implements Serializable {

Modified: myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeDataModel.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeDataModel.java?rev=1327431&r1=1327430&r2=1327431&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeDataModel.java (original)
+++ myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeDataModel.java Wed Apr 18 09:17:34 2012
@@ -72,7 +72,8 @@ public class TreeDataModel extends DataM
   public void update(ExpandedState expandedState) {
     this.expandedState = expandedState;
     DefaultMutableTreeNode current = data;
-    for (int counter = back.size(); current != null; ) {
+    int counter = back.size();
+    while (current != null) {
 
       if (!back.containsKey(current)) {
         mapping.put(counter, new Data(current));

Modified: myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeState.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeState.java?rev=1327431&r1=1327430&r2=1327431&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeState.java (original)
+++ myfaces/tobago/branches/tobago-tree-table/tobago-core/src/main/java/org/apache/myfaces/tobago/model/TreeState.java Wed Apr 18 09:17:34 2012
@@ -1,9 +1,26 @@
 package org.apache.myfaces.tobago.model;
 
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
 import java.io.Serializable;
 
 public class TreeState implements Serializable {
-  
+
   private ExpandedState expandedState;
   private MarkedState markedState;
 

Modified: myfaces/tobago/branches/tobago-tree-table/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/TreeController.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-tree-table/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/TreeController.java?rev=1327431&r1=1327430&r2=1327431&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-tree-table/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/TreeController.java (original)
+++ myfaces/tobago/branches/tobago-tree-table/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/TreeController.java Wed Apr 18 09:17:34 2012
@@ -66,9 +66,9 @@ public class TreeController {
   }
 
   public void openAll(DefaultMutableTreeNode node) {
-    ((Node)node.getUserObject()).setExpanded(true);
+    ((Node) node.getUserObject()).setExpanded(true);
     for (int i = 0; i < node.getChildCount(); i++) {
-      openAll((DefaultMutableTreeNode)node.getChildAt(i));
+      openAll((DefaultMutableTreeNode) node.getChildAt(i));
     }
   }
 

Modified: myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRendererBase.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRendererBase.java?rev=1327431&r1=1327430&r2=1327431&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRendererBase.java (original)
+++ myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRendererBase.java Wed Apr 18 09:17:34 2012
@@ -1,21 +1,21 @@
 package org.apache.myfaces.tobago.renderkit.html.scarborough.standard.tag;
 
 /*
-* Licensed to the Apache Software Foundation (ASF) under one or more
-* contributor license agreements.  See the NOTICE file distributed with
-* this work for additional information regarding copyright ownership.
-* The ASF licenses this file to You under the Apache License, Version 2.0
-* (the "License"); you may not use this file except in compliance with
-* the License.  You may obtain a copy of the License at
-*
-*      http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
 
 import org.apache.myfaces.tobago.component.UITreeNode;
 import org.apache.myfaces.tobago.context.Markup;

Modified: myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/util/RenderUtils.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/util/RenderUtils.java?rev=1327431&r1=1327430&r2=1327431&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/util/RenderUtils.java (original)
+++ myfaces/tobago/branches/tobago-tree-table/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/util/RenderUtils.java Wed Apr 18 09:17:34 2012
@@ -386,7 +386,7 @@ public class RenderUtils {
       if (isTree) {
         final MarkedState markedState = ((AbstractUITree) data).getMarkedState();
         final boolean oldMarked = markedState.isMarked(path);
-        final boolean newMarked = ((Integer)rowIndex).equals(markedIndex);
+        final boolean newMarked = ((Integer) rowIndex).equals(markedIndex);
         if (newMarked != oldMarked) {
   //          new TreeMarkedEvent(node, oldValue, newValue).queue();
           if (newMarked) {