Author: akazakov
Date: 2011-08-05 15:05:34 -0400 (Fri, 05 Aug 2011)
New Revision: 33634
Modified:
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELSegment.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELSegmentImpl.java
Log:
https://issues.jboss.org/browse/JBIDE-9288
Modified:
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELSegment.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELSegment.java 2011-08-05
15:32:17 UTC (rev 33633)
+++
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELSegment.java 2011-08-05
19:05:34 UTC (rev 33634)
@@ -54,4 +54,10 @@
* @return underlying variables.
*/
List<IVariable> getVariables();
+
+ /**
+ * Returns false if EL validator should ignore this segment and don't mark it as a
problem even if the segemtn is not resolved.
+ * @return
+ */
+ boolean isValidatable();
}
\ No newline at end of file
Modified:
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELSegmentImpl.java
===================================================================
---
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELSegmentImpl.java 2011-08-05
15:32:17 UTC (rev 33633)
+++
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELSegmentImpl.java 2011-08-05
19:05:34 UTC (rev 33634)
@@ -26,6 +26,7 @@
protected ITextSourceReference sourceReference;
protected LexicalToken token;
protected boolean resolved = false;
+ protected boolean validatable = true;
protected List<IVariable> variables = new ArrayList<IVariable>();
public ELSegmentImpl(LexicalToken token) {
@@ -131,4 +132,20 @@
public String toString() {
return token!=null?token.getText() + "(" + resolved + ")":
super.toString(); //$NON-NLS-1$ //$NON-NLS-2$
}
+
+ /*
+ * (non-Javadoc)
+ * @see org.jboss.tools.common.el.core.resolver.ELSegment#isValidatable()
+ */
+ @Override
+ public boolean isValidatable() {
+ return validatable;
+ }
+
+ /**
+ * @param validatable the validatable to set
+ */
+ public void setValidatable(boolean validatable) {
+ this.validatable = validatable;
+ }
}
\ No newline at end of file