Commit 4e6e946d authored by yihua.huang's avatar yihua.huang

more friendly exception message in PlainText #144

parent ebb931e0
...@@ -29,27 +29,27 @@ public class PlainText extends AbstractSelectable { ...@@ -29,27 +29,27 @@ public class PlainText extends AbstractSelectable {
@Override @Override
public Selectable xpath(String xpath) { public Selectable xpath(String xpath) {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException("XPath can not apply to plain text. Please check whether you use a previous xpath with attribute select (/@href etc).");
} }
@Override @Override
public Selectable $(String selector) { public Selectable $(String selector) {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException("$ can not apply to plain text. Please check whether you use a previous xpath with attribute select (/@href etc).");
} }
@Override @Override
public Selectable $(String selector, String attrName) { public Selectable $(String selector, String attrName) {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException("$ can not apply to plain text. Please check whether you use a previous xpath with attribute select (/@href etc).");
} }
@Override @Override
public Selectable smartContent() { public Selectable smartContent() {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException("Smart content can not apply to plain text. Please check whether you use a previous xpath with attribute select (/@href etc).");
} }
@Override @Override
public Selectable links() { public Selectable links() {
throw new UnsupportedOperationException(); throw new UnsupportedOperationException("Links can not apply to plain text. Please check whether you use a previous xpath with attribute select (/@href etc).");
} }
@Override @Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment