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

Method getProtocol

src/main/java/org/htmlunit/javascript/host/URL.java:376–383  ·  view source on GitHub ↗

@return the protocol scheme of the URL, including the final ':'.

()

Source from the content-addressed store, hash-verified

374 * @return the protocol scheme of the URL, including the final ':'.
375 */
376 @JsxGetter
377 public String getProtocol() {
378 if (url_ == null) {
379 return null;
380 }
381 final String protocol = url_.getProtocol();
382 return protocol.isEmpty() ? "" : (protocol + ":");
383 }
384
385 /**
386 * Sets the {@code protocol} property.

Callers 15

originMethod · 0.95
documentOriginMethod · 0.95
getResponseMethod · 0.95
buildCookieOriginMethod · 0.95
jsConstructorMethod · 0.95
getSearchMethod · 0.95
postMessageMethod · 0.95
postMessageMethod · 0.95
generateBlobUrlMethod · 0.95
getHostMethod · 0.95

Calls 1

isEmptyMethod · 0.65

Tested by 2

originMethod · 0.76
documentOriginMethod · 0.76