myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lof...@apache.org
Subject svn commit: r909550 - /myfaces/tobago/trunk/example/demo/src/main/java/org/apache/myfaces/tobago/example/demo/TobagoDemoController.java
Date Fri, 12 Feb 2010 18:31:41 GMT
Author: lofwyr
Date: Fri Feb 12 18:31:38 2010
New Revision: 909550

URL: http://svn.apache.org/viewvc?rev=909550&view=rev
Log:
change boolean[] to Boolean[] as workaround of a problem with jetty

Modified:
    myfaces/tobago/trunk/example/demo/src/main/java/org/apache/myfaces/tobago/example/demo/TobagoDemoController.java

Modified: myfaces/tobago/trunk/example/demo/src/main/java/org/apache/myfaces/tobago/example/demo/TobagoDemoController.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/example/demo/src/main/java/org/apache/myfaces/tobago/example/demo/TobagoDemoController.java?rev=909550&r1=909549&r2=909550&view=diff
==============================================================================
--- myfaces/tobago/trunk/example/demo/src/main/java/org/apache/myfaces/tobago/example/demo/TobagoDemoController.java
(original)
+++ myfaces/tobago/trunk/example/demo/src/main/java/org/apache/myfaces/tobago/example/demo/TobagoDemoController.java
Fri Feb 12 18:31:38 2010
@@ -17,10 +17,6 @@
  * limitations under the License.
  */
 
-/*
- * $Id$
- */
-
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 import org.apache.myfaces.tobago.component.Attributes;
@@ -59,7 +55,8 @@
 
   private SelectItem[] salutationItems;
 
-  private boolean[] bool;
+  // XXX jetty 6.1.22 has problems with boolean[] (primitive), see: http://jira.codehaus.org/browse/JETTY-1181
+  private Boolean[] bool;
 
   private boolean update;
 
@@ -123,7 +120,6 @@
 
   private TabChangeListener tabChangeListener;
 
-
   public TobagoDemoController() {
 
     String[] salutationKeys = {
@@ -136,17 +132,7 @@
     salutationItems = getSelectItems(salutationKeys, "demo");
     this.salutation = new String[]{"", "", "", ""};
 
-    bool = new boolean[10];
-    bool[0] = true;
-    bool[1] = false;
-    bool[2] = true;
-    bool[3] = false;
-    bool[4] = true;
-    bool[5] = false;
-    bool[6] = true;
-    bool[7] = false;
-    bool[8] = true;
-    bool[9] = false;
+    bool = new Boolean[] {true, false, true, false, true, false, true, false, true, false};
     boolTest = Boolean.TRUE;
 
     text = new String[11];
@@ -234,7 +220,7 @@
     return null;
   }
 
-  public void resetSession() throws IOException {
+  public String resetSession() throws IOException {
     LOG.info("Resetting the session.");
     FacesContext facesContext = FacesContext.getCurrentInstance();
     HttpSession session = (HttpSession) facesContext.getExternalContext().getSession(false);
@@ -244,6 +230,7 @@
     ExternalContext externalContext = facesContext.getExternalContext();
     externalContext.redirect(externalContext.getRequestContextPath());
     facesContext.responseComplete();
+    return null;
   }
 
   public TabChangeListener getTabChangeListener() {
@@ -323,14 +310,10 @@
     this.salutationItems = salutationItems;
   }
 
-  public boolean[] getBool() {
+  public Boolean[] getBool() {
     return this.bool;
   }
 
-  public void setBool(boolean[] argBool) {
-    this.bool = argBool;
-  }
-
   public Boolean getBoolTest() {
     return boolTest;
   }



Mime
View raw message