Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcbateman2007-01-22 07:47:16 +0000
committercbateman2007-01-22 07:47:16 +0000
commit8d87d4d4c2dd73fa26821c785b3bc366ac396f6e (patch)
treeeb356ed1c0fb3bd052112686fefe6a5e903b1dd3 /jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter
parent3a64d631f733c6585a6d95210b10f048c16e2d2a (diff)
downloadwebtools.jsf-8d87d4d4c2dd73fa26821c785b3bc366ac396f6e.tar.gz
webtools.jsf-8d87d4d4c2dd73fa26821c785b3bc366ac396f6e.tar.xz
webtools.jsf-8d87d4d4c2dd73fa26821c785b3bc366ac396f6e.zip
Prototype for non-visual child element decorators. Currently only applies to h:commandButton. Can be expanded to any ITagConverter implementation in future.
Diffstat (limited to 'jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter')
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/AbstractTagConverter.java9
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter.java4
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter2.java2
-rw-r--r--jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/ITagConverter.java6
4 files changed, 20 insertions, 1 deletions
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/AbstractTagConverter.java b/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/AbstractTagConverter.java
index 5f7e65151..0f5f01d76 100644
--- a/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/AbstractTagConverter.java
+++ b/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/AbstractTagConverter.java
@@ -133,7 +133,14 @@ public abstract class AbstractTagConverter implements ITagConverter,
return _childNodes;
}
- /**
+
+ public List getNonVisualChildren()
+ {
+ // by default, no non-visual children
+ return Collections.EMPTY_LIST;
+ }
+
+ /**
* child class should call this method.
*
* @param childNode
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter.java b/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter.java
index 122afec79..fe9eb3245 100644
--- a/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter.java
+++ b/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter.java
@@ -153,4 +153,8 @@ public class HiddenTagConverter implements ITagConverter {
public int getMode() {
return _mode;
}
+
+ public List getNonVisualChildren() {
+ return Collections.EMPTY_LIST;
+ }
}
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter2.java b/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter2.java
index c374d21c0..cd09809a9 100644
--- a/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter2.java
+++ b/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/HiddenTagConverter2.java
@@ -24,6 +24,8 @@ import org.w3c.dom.Element;
* document.</li>
* </ol>
*
+ * TODO: this the wrong way to do this. This should sub-class HiddenTagConverter
+ *
* @author mengbo
* @version 1.5
*/
diff --git a/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/ITagConverter.java b/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/ITagConverter.java
index 3b504b4ef..761e7d2ea 100644
--- a/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/ITagConverter.java
+++ b/jsf/plugins/org.eclipse.jst.pagedesigner/src/org/eclipse/jst/pagedesigner/converter/ITagConverter.java
@@ -83,6 +83,12 @@ public interface ITagConverter {
* @return
*/
public List getChildModeList();
+
+ /**
+ * @return a list of Element tags that map to non-visual children
+ * Type should be always be Element.
+ */
+ public List getNonVisualChildren();
/**
* For child nodes that need further convert, return their position in the

Back to the top