MCPcopy Index your code
hub / github.com/HtmlUnit/htmlunit / isSupported

Method isSupported

src/main/java/org/htmlunit/html/HtmlInput.java:1180–1215  ·  view source on GitHub ↗

Returns whether the specified type is supported or not. @param type the input type @param browserVersion the browser version @return whether the specified type is supported or not

(final String type, final BrowserVersion browserVersion)

Source from the content-addressed store, hash-verified

1178 * @return whether the specified type is supported or not
1179 */
1180 private static boolean isSupported(final String type, final BrowserVersion browserVersion) {
1181 boolean supported = false;
1182 switch (type) {
1183 case "month":
1184 supported = browserVersion.hasFeature(HTMLINPUT_TYPE_MONTH_SUPPORTED);
1185 break;
1186 case "week":
1187 supported = browserVersion.hasFeature(HTMLINPUT_TYPE_WEEK_SUPPORTED);
1188 break;
1189 case "color":
1190 case "date":
1191 case "datetime-local":
1192 case "time":
1193 case "email":
1194 case "text":
1195 case "submit":
1196 case "checkbox":
1197 case "radio":
1198 case "hidden":
1199 case "password":
1200 case "image":
1201 case "reset":
1202 case "button":
1203 case "file":
1204 case "number":
1205 case "range":
1206 case "search":
1207 case "tel":
1208 case "url":
1209 supported = true;
1210 break;
1211
1212 default:
1213 }
1214 return supported;
1215 }
1216
1217 protected void unmarkValueDirty() {
1218 isValueDirty_ = false;

Callers 2

getTypeMethod · 0.95
changeTypeMethod · 0.95

Calls 1

hasFeatureMethod · 0.45

Tested by

no test coverage detected