MCPcopy Create free account
hub / github.com/HtmlUnit/htmlunit / isDisabled

Method isDisabled

src/main/java/org/htmlunit/html/HtmlButton.java:111–127  ·  view source on GitHub ↗

{@inheritDoc}

()

Source from the content-addressed store, hash-verified

109 * {@inheritDoc}
110 */
111 @Override
112 public final boolean isDisabled() {
113 if (hasAttribute(ATTRIBUTE_DISABLED)) {
114 return true;
115 }
116
117 Node node = getParentNode();
118 while (node != null) {
119 if (node instanceof DisabledElement element
120 && element.isDisabled()) {
121 return true;
122 }
123 node = node.getParentNode();
124 }
125
126 return false;
127 }
128
129 /**
130 * Returns {@code true} if this element is read only.

Callers 2

doClickStateUpdateMethod · 0.95
willValidateMethod · 0.95

Calls 4

getParentNodeMethod · 0.95
isDisabledMethod · 0.65
hasAttributeMethod · 0.45
getParentNodeMethod · 0.45

Tested by

no test coverage detected