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 2006/11/16 17:31:23 UTC

svn commit: r475800 - in /myfaces/tobago/trunk: core/src/main/java/org/apache/myfaces/tobago/ example/sandbox/src/main/webapp/ sandbox/src/main/java/org/apache/myfaces/tobago/component/ sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/sca...

Author: lofwyr
Date: Thu Nov 16 08:31:22 2006
New Revision: 475800

URL: http://svn.apache.org/viewvc?view=rev&rev=475800
Log:
working on TOBAGO-18: encoding of the UITreeNode

Modified:
    myfaces/tobago/trunk/core/src/main/java/org/apache/myfaces/tobago/TobagoConstants.java
    myfaces/tobago/trunk/example/sandbox/src/main/webapp/tree.jsp
    myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNode.java
    myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNodes.java
    myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRenderer.java
    myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodesRenderer.java
    myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTag.java
    myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTagDeclaration.java

Modified: myfaces/tobago/trunk/core/src/main/java/org/apache/myfaces/tobago/TobagoConstants.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/core/src/main/java/org/apache/myfaces/tobago/TobagoConstants.java?view=diff&rev=475800&r1=475799&r2=475800
==============================================================================
--- myfaces/tobago/trunk/core/src/main/java/org/apache/myfaces/tobago/TobagoConstants.java (original)
+++ myfaces/tobago/trunk/core/src/main/java/org/apache/myfaces/tobago/TobagoConstants.java Thu Nov 16 08:31:22 2006
@@ -41,6 +41,7 @@
   public static final String ATTR_DEFAULT_COMMAND = "defaultCommand";
   public static final String ATTR_DIRECT_LINK_COUNT = "directLinkCount";
   public static final String ATTR_DISABLED = "disabled";
+  @Deprecated
   public static final String ATTR_DISABLED_REFERENCE = "disabledReference";
   public static final String ATTR_DOCTYPE = "doctype";
   public static final String ATTR_ENCTYPE = "enctype";
@@ -59,6 +60,7 @@
   public static final String ATTR_HOVER = "hover";
   public static final String ATTR_I18N = "i18n";
   public static final String ATTR_ICON_SIZE = "iconSize";
+  @Deprecated
   public static final String ATTR_ID_REFERENCE = "idReference";
   public static final String ATTR_IMMEDIATE = "immediate";
   public static final String ATTR_IMAGE = "image";
@@ -89,6 +91,7 @@
   public static final String ATTR_MODE = "mode";
   public static final String ATTR_MUTABLE = "mutable";
   public static final String ATTR_NAME = "name";
+  @Deprecated
   public static final String ATTR_NAME_REFERENCE = "nameReference";
   public static final String ATTR_NAVIGATE = "navigate";
   public static final String ATTR_NUMBER_STYLE = "numberStyle";

Modified: myfaces/tobago/trunk/example/sandbox/src/main/webapp/tree.jsp
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/example/sandbox/src/main/webapp/tree.jsp?view=diff&rev=475800&r1=475799&r2=475800
==============================================================================
--- myfaces/tobago/trunk/example/sandbox/src/main/webapp/tree.jsp (original)
+++ myfaces/tobago/trunk/example/sandbox/src/main/webapp/tree.jsp Thu Nov 16 08:31:22 2006
@@ -54,21 +54,38 @@
 <f:view>
   <tc:loadBundle basename="demo" var="bundle"/>
 
-  <tc:page label="Screenshot" id="page"
-           width="750px" height="800px">
+  <tc:page label="Sandbox - Tree" id="page"
+           width="500px" height="800px">
     <f:facet name="layout">
-      <tc:gridLayout margin="10px" rows="300px;*"/>
+      <tc:gridLayout margin="10px" rows="300px;300px;*"/>
     </f:facet>
 
-    <tcs:tree state="#{treeState}" id="screenshotTree"
-              idReference="userObject"
-              nameReference="userObject"
+    <tcs:tree state="#{treeState}" id="menu"
+              showIcons="false"
+              showJunctions="false"
+              showRootJunction="false"
+              showRoot="true"
+              mode="menu">
+      <tcs:treeNode label="Root">
+        <tcs:treeNodes value="#{tree}" var="node">
+          <tcs:treeNode label="#{node.userObject}"/>
+        </tcs:treeNodes>
+        <tcs:treeNode label="Sub 1"/>
+        <tcs:treeNode label="Sub 2"/>
+        <tcs:treeNode label="Sub 3">
+          <tcs:treeNode label="Sub 3.1"/>
+          <tcs:treeNode label="Sub 3.2"/>
+        </tcs:treeNode>
+        <tcs:treeNode label="Sub 4"/>
+      </tcs:treeNode>
+    </tcs:tree>
+
+    <tcs:tree state="#{treeState}" id="tree"
               showIcons="true"
               showJunctions="true"
               showRootJunction="true"
               showRoot="true"
-              selectable="single"
-              mutable="false">
+              selectable="single">
       <tcs:treeNode label="Root">
         <tcs:treeNodes value="#{tree}" var="node">
           <tcs:treeNode label="#{node.userObject}"/>

Modified: myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNode.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNode.java?view=diff&rev=475800&r1=475799&r2=475800
==============================================================================
--- myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNode.java (original)
+++ myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNode.java Thu Nov 16 08:31:22 2006
@@ -20,21 +20,12 @@
 import org.apache.commons.beanutils.PropertyUtils;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
-import static org.apache.myfaces.tobago.TobagoConstants.ATTR_DISABLED;
-import static org.apache.myfaces.tobago.TobagoConstants.ATTR_DISABLED_REFERENCE;
-import static org.apache.myfaces.tobago.TobagoConstants.ATTR_ID_REFERENCE;
-import static org.apache.myfaces.tobago.TobagoConstants.ATTR_NAME;
-import static org.apache.myfaces.tobago.TobagoConstants.ATTR_NAME_REFERENCE;
-import static org.apache.myfaces.tobago.TobagoConstants.RENDERER_TYPE_TREE_NODE;
 
 import javax.faces.component.UIComponent;
 import javax.faces.component.UIInput;
 import javax.faces.context.FacesContext;
-import javax.faces.el.ValueBinding;
 import javax.swing.tree.DefaultMutableTreeNode;
-import javax.swing.tree.MutableTreeNode;
 import javax.swing.tree.TreeNode;
-import java.util.Map;
 
 public class UITreeNode extends UIInput {
 
@@ -44,32 +35,21 @@
 
   private static final String SUB_REFERENCE_KEY = "subReferenceKey";
 
-  protected UITreeNode(UIComponent parent, int index) {
-    super();
-    if (parent instanceof UITreeNode) {
-      String parentSubReference = ((UITreeNode) parent).getSubReference();
-      if (parentSubReference == null) {
-        getAttributes().put(SUB_REFERENCE_KEY, "childAt[" + index + "]");
-      } else {
-        getAttributes().put(SUB_REFERENCE_KEY, parentSubReference + ".childAt[" + index + "]");
-      }
-    }
-    setRendererType(RENDERER_TYPE_TREE_NODE);
-    parent.getChildren().add(this);
-    initId();
-    initName();
-    initDisabled();
-  }
+  private String nodeId;
 
-  public UITreeNode() {
-  }
+  private String parentNodeId;
+
+  // todo: use an abstraction for DefaultMutableTreeNode like DataModel for UIData
+  private DefaultMutableTreeNode currentNode;
 
 // ///////////////////////////////////////////// code
 
+  @Override
   public boolean getRendersChildren() {
     return true;
   }
 
+  // todo: may be removed
   public String getSubReference() {
     return (String) getAttributes().get(SUB_REFERENCE_KEY);
   }
@@ -78,6 +58,7 @@
     return (DefaultMutableTreeNode) getValue();
   }
 
+  @Override
   public Object getValue() {
     TreeNode value = null;
     UITreeNodes root = findTreeNodesRoot();
@@ -111,78 +92,6 @@
     return value;
   }
 
-  protected void createTreeNodes() {
-
-    TreeNode node = (TreeNode) getValue();
-    if (node != null) {
-      int childCount = node.getChildCount();
-      for (int i = 0; i < childCount; i++) {
-        UITreeNode component = new UITreeNode(this, i);
-        component.createTreeNodes();
-      }
-    }
-  }
-
-  private void initName() {
-    TreeNode treeNode = (TreeNode) getValue();
-    if (treeNode != null) {
-      Object name = getReference(treeNode, ATTR_NAME_REFERENCE);
-      if (name == null) {
-        name = toString();
-      }
-      getAttributes().put(ATTR_NAME, name.toString());
-    }
-  }
-
-  private void initDisabled() {
-    TreeNode treeNode = (TreeNode) getValue();
-    if (treeNode != null) {
-      Object disabled = getReference(treeNode, ATTR_DISABLED_REFERENCE);
-      if (!(disabled instanceof Boolean)) {
-        if (disabled instanceof String) {
-          disabled = Boolean.valueOf((String) disabled);
-        } else {
-          disabled = false;
-        }
-      }
-      getAttributes().put(ATTR_DISABLED, disabled);
-    }
-  }
-
-  private void initId() {
-    TreeNode treeNode = (TreeNode) getValue();
-    if (treeNode != null) {
-      Object id = getReference(treeNode, ATTR_ID_REFERENCE);
-      if (!(id instanceof String)) {
-        id = "node" + Integer.toString(System.identityHashCode(treeNode));
-      }
-      setId((String) id);
-    }
-  }
-
-  @SuppressWarnings("unchecked")
-  private Object getReference(TreeNode treeNode, String key) {
-    Object value = null;
-    UITreeNodes root = findTreeNodesRoot();
-    String reference = (String) root.getAttributes().get(key);
-    if (reference != null) {
-      try {
-        FacesContext facesContext = FacesContext.getCurrentInstance();
-        Map requestMap = facesContext.getExternalContext().getRequestMap();
-        String ref = "#{tobagoTreeNode." + reference + "}";
-        ValueBinding vb = facesContext.getApplication().createValueBinding(ref);
-        requestMap.put("tobagoTreeNode", treeNode);
-        value = vb.getValue(facesContext);
-        requestMap.remove("tobagoTreeNode");
-      } catch (Exception e) {
-        LOG.warn(
-            "Can't find " + key + " over ref='" + reference
-                + "' treeNode='" + treeNode + "! " + treeNode.getClass().getName(), e);
-      }
-    }
-    return value;
-  }
-
   public UITree findTreeRoot() {
     UIComponent ancestor = getParent();
     while (ancestor != null
@@ -210,28 +119,36 @@
     // nothig to update for treeNode's
   }
 
-  protected Object checkValue(Object currentValue) {
-
-    if (currentValue == null) {
-      LOG.error("currentValue is null");
-      currentValue = emergencyValue();
+  public boolean isFolder() {
+    if (currentNode != null) {
+      return currentNode.getChildCount() > 0;
+    } else {
+      return getChildCount() > 0;
     }
+  }
 
-    if (!(currentValue instanceof MutableTreeNode)) {
-      LOG.error("currentValue is not valid: '" + currentValue + "'");
-      LOG.error(
-          "currentValue is not of type '"
-          + MutableTreeNode.class.getName() + "': '"
-          + currentValue.getClass().getName() + "'");
-      currentValue = emergencyValue();
-    }
+  public String getNodeId() {
+    return nodeId;
+  }
 
-    return currentValue;
+  public void setNodeId(String nodeId) {
+    this.nodeId = nodeId;
   }
 
-  protected Object emergencyValue() {
-    return new DefaultMutableTreeNode("Default");
+  public String getParentNodeId() {
+    return parentNodeId;
   }
 
+  public void setParentNodeId(String parentNodeId) {
+    this.parentNodeId = parentNodeId;
+  }
+
+  public DefaultMutableTreeNode getCurrentNode() {
+    return currentNode;
+  }
+
+  public void setCurrentNode(DefaultMutableTreeNode currentNode) {
+    this.currentNode = currentNode;
+  }
 }
 

Modified: myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNodes.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNodes.java?view=diff&rev=475800&r1=475799&r2=475800
==============================================================================
--- myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNodes.java (original)
+++ myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/component/UITreeNodes.java Thu Nov 16 08:31:22 2006
@@ -19,12 +19,15 @@
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.myfaces.tobago.renderkit.RenderUtil;
 
 import javax.faces.component.UIComponent;
 import javax.faces.context.FacesContext;
 import javax.swing.tree.TreeNode;
+import javax.swing.tree.DefaultMutableTreeNode;
 import java.io.IOException;
 import java.util.Iterator;
+import java.util.Enumeration;
 
 public class UITreeNodes extends javax.faces.component.UIInput {
 
@@ -83,6 +86,43 @@
 
   public void encodeChildren(FacesContext context)
       throws IOException {
+  }
+
+
+  public void encodeEnd(FacesContext facesContext) throws IOException {
+
+    DefaultMutableTreeNode tree = (DefaultMutableTreeNode) getValue();
+
+    encodeNodes(tree, "", 0, facesContext);
+
+    super.encodeEnd(facesContext);
+  }
+
+  private void encodeNodes(DefaultMutableTreeNode node, String position,
+      int index, FacesContext facesContext) throws IOException {
+
+    if (node == null) { // XXX hotfix
+      LOG.warn("node is null");
+      return;
+    }
+
+    UITreeNode template = getTemplateComponent();
+    template.setParentNodeId(position);
+    position += ":" + index;
+    template.setNodeId(position);
+
+    facesContext.getExternalContext().getRequestMap().put(var, node);
+    template.setCurrentNode(node);
+    RenderUtil.encode(facesContext, template);
+    facesContext.getExternalContext().getRequestMap().remove(var);
+    template.setCurrentNode(null);
+
+    index = 0;
+    for (Enumeration e = node.children(); e.hasMoreElements();) {
+      DefaultMutableTreeNode subNode = (DefaultMutableTreeNode) e.nextElement();
+      encodeNodes(subNode, position, index, facesContext);
+      index++;
+    }
   }
 
   public UITreeNode findUITreeNode(UITreeNode node, TreeNode treeNode) {

Modified: myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRenderer.java?view=diff&rev=475800&r1=475799&r2=475800
==============================================================================
--- myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRenderer.java (original)
+++ myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodeRenderer.java Thu Nov 16 08:31:22 2006
@@ -154,13 +154,21 @@
     UITreeNode treeNode = (UITreeNode) component;
 
     String clientId = treeNode.getClientId(facesContext);
+    String pos = treeNode.getNodeId();
+    clientId += pos != null ? pos : "";
     UIComponent parent = treeNode.getParent();
 
     String parentClientId = null;
     if (parent != null && parent instanceof UITreeNode) { // if not the root node
       parentClientId = treeNode.getParent().getClientId(facesContext);
     } else if (parent != null && parent instanceof UITreeNodes) {
-      parentClientId = treeNode.getParent().getParent().getClientId(facesContext);
+      if (pos.equals(":0")) {
+        UIComponent superParent = treeNode.getParent().getParent();
+        parentClientId = superParent.getClientId(facesContext);
+      } else {
+        parentClientId = treeNode.getClientId(facesContext);
+        parentClientId += treeNode.getParentNodeId();
+      }
     }
 
     UITree root = treeNode.findTreeRoot();
@@ -207,7 +215,7 @@
       writer.writeText("',", null);
 
       // is folder
-      writer.writeText(component.getChildCount() > 0, null);
+      writer.writeText(treeNode.isFolder(), null);
       writer.writeText(",", null);
       writer.writeText(Boolean.toString(!root.isShowIcons()), null);
       writer.writeText(",", null);
@@ -238,9 +246,9 @@
           ATTR_MUTABLE)), null);
       writer.writeText(",'", null);
       writer.writeText(
-          ComponentUtil.findPage(component).getFormId(facesContext), null);
+          ComponentUtil.findPage(treeNode).getFormId(facesContext), null);
       writer.writeText("',", null);
-      if (component.getChildCount() == 0
+      if (treeNode.getChildCount() == 0
           || (selectable != null && !selectable.endsWith("LeafOnly"))) {
         boolean selected = treeState.isSelected(node);
         writer.writeText(Boolean.toString(selected), null);

Modified: myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodesRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodesRenderer.java?view=diff&rev=475800&r1=475799&r2=475800
==============================================================================
--- myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodesRenderer.java (original)
+++ myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/TreeNodesRenderer.java Thu Nov 16 08:31:22 2006
@@ -17,17 +17,13 @@
  * limitations under the License.
  */
 
-import org.apache.myfaces.tobago.renderkit.RendererBase;
-import org.apache.myfaces.tobago.component.UITreeNodes;
-import org.apache.myfaces.tobago.component.UITreeNode;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.apache.myfaces.tobago.renderkit.RendererBase;
 
 import javax.faces.component.UIComponent;
 import javax.faces.context.FacesContext;
-import javax.swing.tree.DefaultMutableTreeNode;
 import java.io.IOException;
-import java.util.Enumeration;
 
 public class TreeNodesRenderer extends RendererBase {
 
@@ -41,25 +37,5 @@
   public void encodeEnd(FacesContext facesContext,
       UIComponent component) throws IOException {
 
-    UITreeNodes nodes = (UITreeNodes) component;
-    String var = nodes.getVar();
-
-    DefaultMutableTreeNode tree = (DefaultMutableTreeNode) nodes.getValue();
-
-    for (Enumeration e = tree.depthFirstEnumeration(); e.hasMoreElements();) {
-      DefaultMutableTreeNode node = (DefaultMutableTreeNode) e.nextElement();
-
-      if (node == null) { // XXX hotfix
-        LOG.warn("node is null");
-        continue;
-      }
-      // todo put into var (request context)
-      facesContext.getExternalContext().getRequestMap().put(var, node);
-      UITreeNode template = nodes.getTemplateComponent();
-      template.encodeBegin(facesContext);
-      template.encodeChildren(facesContext);
-      template.encodeEnd(facesContext);
-      facesContext.getExternalContext().getRequestMap().remove(var);
-    }
   }
 }

Modified: myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTag.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTag.java?view=diff&rev=475800&r1=475799&r2=475800
==============================================================================
--- myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTag.java (original)
+++ myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTag.java Thu Nov 16 08:31:22 2006
@@ -17,11 +17,8 @@
  * limitations under the License.
  */
 
-import static org.apache.myfaces.tobago.TobagoConstants.ATTR_DISABLED_REFERENCE;
-import static org.apache.myfaces.tobago.TobagoConstants.ATTR_ID_REFERENCE;
 import static org.apache.myfaces.tobago.TobagoConstants.ATTR_MODE;
 import static org.apache.myfaces.tobago.TobagoConstants.ATTR_MUTABLE;
-import static org.apache.myfaces.tobago.TobagoConstants.ATTR_NAME_REFERENCE;
 import static org.apache.myfaces.tobago.TobagoConstants.ATTR_REQUIRED;
 import static org.apache.myfaces.tobago.TobagoConstants.ATTR_SELECTABLE;
 import static org.apache.myfaces.tobago.TobagoConstants.ATTR_SHOW_ICONS;
@@ -50,10 +47,6 @@
   private String selectable;
   private String mutable;
 
-  private String idReference;
-  private String nameReference;
-  private String disabledReference;
-
   private String required;
 
   private String actionListener;
@@ -80,9 +73,6 @@
     ComponentUtil.setStringProperty(component, ATTR_SELECTABLE, selectable);
     ComponentUtil.setBooleanProperty(component, ATTR_MUTABLE, mutable);
 
-    ComponentUtil.setStringProperty(component, ATTR_ID_REFERENCE, idReference);
-    ComponentUtil.setStringProperty(component, ATTR_NAME_REFERENCE, nameReference);
-    ComponentUtil.setStringProperty(component, ATTR_DISABLED_REFERENCE, disabledReference);
     ComponentUtil.setBooleanProperty(component, ATTR_REQUIRED, required);
     ComponentUtil.setActionListener((ActionSource) component, actionListener);
     ComponentUtil.setStringProperty(component, ATTR_MODE, mode);
@@ -99,9 +89,6 @@
     showRootJunction = null;
     selectable = null;
     mutable = null;
-    idReference = null;
-    nameReference = null;
-    disabledReference = null;
     required = null;
     actionListener = null;
     mode = null;
@@ -162,14 +149,6 @@
     this.showRootJunction = showRootJunction;
   }
 
-  public String getIdReference() {
-    return idReference;
-  }
-
-  public void setIdReference(String idReference) {
-    this.idReference = idReference;
-  }
-
   public String getSelectable() {
     return selectable;
   }
@@ -184,22 +163,6 @@
 
   public void setMutable(String mutable) {
     this.mutable = mutable;
-  }
-
-  public String getNameReference() {
-    return nameReference;
-  }
-
-  public void setNameReference(String nameReference) {
-    this.nameReference = nameReference;
-  }
-
-  public String getDisabledReference() {
-    return disabledReference;
-  }
-
-  public void setDisabledReference(String disabledReference) {
-    this.disabledReference = disabledReference;
   }
 
   public String getRequired() {

Modified: myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTagDeclaration.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTagDeclaration.java?view=diff&rev=475800&r1=475799&r2=475800
==============================================================================
--- myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTagDeclaration.java (original)
+++ myfaces/tobago/trunk/sandbox/src/main/java/org/apache/myfaces/tobago/taglib/sandbox/TreeTagDeclaration.java Thu Nov 16 08:31:22 2006
@@ -25,8 +25,6 @@
 import org.apache.myfaces.tobago.taglib.component.TobagoTagDeclaration;
 import org.apache.myfaces.tobago.taglib.decl.HasActionListener;
 import org.apache.myfaces.tobago.taglib.decl.HasIdBindingAndRendered;
-import org.apache.myfaces.tobago.taglib.decl.HasIdReference;
-import org.apache.myfaces.tobago.taglib.decl.HasNameReference;
 import org.apache.myfaces.tobago.taglib.decl.HasState;
 import org.apache.myfaces.tobago.taglib.decl.HasTreeNodeValue;
 import org.apache.myfaces.tobago.taglib.decl.IsRequired;
@@ -47,7 +45,7 @@
     rendererType = "Tree")
 public interface TreeTagDeclaration extends TobagoTagDeclaration,
     HasIdBindingAndRendered, HasTreeNodeValue, HasState,
-    HasIdReference, HasActionListener, HasNameReference, IsRequired {
+    HasActionListener, IsRequired {
 
   /**
    * Flag indicating whether or not this component should be render selectable items.
@@ -92,16 +90,6 @@
       defaultValue = "false")
   void setShowRoot(String showRoot);
   
-  /**
-   * Bean property reference to fetch the disabled state for the treeNode's.<br>
-   * Example:<br>
-   *   a disabledReference="userObject.disabled" try's to invoke
-   *   <code>&lt;UITreeNode>.getUserObject().getDisabled()<code> to fetch the state.
-   */
-  @TagAttribute
-  @UIComponentTagAttribute()
-  void setDisabledReference(String id);
-
   /**
    * Display option: Normal tree or menu.
    */