You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by mm...@apache.org on 2005/08/24 13:58:29 UTC
svn commit: r239615 -
/myfaces/sandbox/trunk/src/java/org/apache/myfaces/custom/autoupdatedatatable/AutoUpdateDataTable.java
Author: mmarinschek
Date: Wed Aug 24 04:58:09 2005
New Revision: 239615
URL: http://svn.apache.org/viewcvs?rev=239615&view=rev
Log: (empty)
Modified:
myfaces/sandbox/trunk/src/java/org/apache/myfaces/custom/autoupdatedatatable/AutoUpdateDataTable.java
Modified: myfaces/sandbox/trunk/src/java/org/apache/myfaces/custom/autoupdatedatatable/AutoUpdateDataTable.java
URL: http://svn.apache.org/viewcvs/myfaces/sandbox/trunk/src/java/org/apache/myfaces/custom/autoupdatedatatable/AutoUpdateDataTable.java?rev=239615&r1=239614&r2=239615&view=diff
==============================================================================
--- myfaces/sandbox/trunk/src/java/org/apache/myfaces/custom/autoupdatedatatable/AutoUpdateDataTable.java (original)
+++ myfaces/sandbox/trunk/src/java/org/apache/myfaces/custom/autoupdatedatatable/AutoUpdateDataTable.java Wed Aug 24 04:58:09 2005
@@ -1,3 +1,18 @@
+/**
+ * Copyright 2004 The Apache Software Foundation.
+ *
+ * Licensed 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.
+ */
package org.apache.myfaces.custom.autoupdatedatatable;
import org.apache.myfaces.component.html.ext.HtmlDataTable;
@@ -9,27 +24,38 @@
import java.io.IOException;
/**
- * Created by IntelliJ IDEA.
- * User: ich
- * Date: 13.07.2005
- * Time: 19:16:29
- * To change this template use File | Settings | File Templates.
+ * @author Jörg Artaker
+ * @author Thomas Huber
+ * @version $Revision: $ $Date: $
+ * <p/>
+ * $Log: $
*/
public class AutoUpdateDataTable extends HtmlDataTable implements AjaxComponent{
private String _frequency;
+ /**
+ * @param context FacesContext
+ * @param state Object
+ */
public void processRestoreState(FacesContext context, Object state)
{
super.processRestoreState(context, state);
}
+ /**
+ * @param context FacesContext
+ * @return Object
+ */
public Object processSaveState(FacesContext context)
{
return super.processSaveState(context);
}
-
+ /**
+ * @param context FacesContext
+ * @return the values Object[]
+ */
public Object saveState(FacesContext context)
{
Object[] values = new Object[2];
@@ -39,6 +65,10 @@
return values;
}
+ /**
+ * @param context FacesContext
+ * @param state Object
+ */
public void restoreState(FacesContext context, Object state)
{
Object values[] = (Object[])state;
@@ -46,18 +76,34 @@
_frequency = (String) values[1];
}
+ /**
+ * @return the _frequency String
+ */
public String getFrequency() {
return _frequency;
}
+ /**
+ * @param _frequency String
+ */
public void setFrequency(String _frequency) {
this._frequency = _frequency;
}
+ /**
+ * @param context FacesContext
+ * @throws java.io.IOException
+ */
public void encodeAjax(FacesContext context) throws IOException {
if (context == null) throw new NullPointerException("context");
if (!isRendered()) return;
Renderer renderer = getRenderer(context);
+
+ if (isValidChildren())
+ {
+ setPreservedDataModel(null);
+ }
+
if (renderer != null && renderer instanceof AjaxRenderer)
{