if (!e_a.getExpression().equals(e_b.getExpression()) ||
!e_a.getLanguage().equals(e_b.getLanguage())) {
return false;
}
XPathExpression xp_a = null;
XPathExpression xp_b = null;
if (e_a instanceof XPathExpression) {
xp_a = (XPathExpression)e_a;
xp_b = null;
if (e_b instanceof XPathExpression) {
xp_b = (XPathExpression)e_b;
} else {
try {
Field f_original = e_b.getClass().getDeclaredField("original");
f_original.setAccessible(true);
xp_b = (XPathExpression)f_original.get(e_b);
} catch (Exception ex) {
Activator.getLogger().error(ex);
}
}
if (xp_a.getResultTypeName() != xp_b.getResultTypeName()) {
return false;
}
} else if (e_b instanceof XPathExpression) {
xp_a = null;
xp_b = (XPathExpression)e_b;
if (e_a instanceof XPathExpression) {
xp_a = (XPathExpression)e_a;
} else {
try {
Field f_original = e_a.getClass().getDeclaredField("original");
f_original.setAccessible(true);
xp_a = (XPathExpression)f_original.get(e_a);
} catch (Exception ex) {
Activator.getLogger().error(ex);
}
}
if (xp_a.getResultTypeName() != xp_b.getResultTypeName()) {
return false;
}
}
return true;
}