MCPcopy Index your code
hub / github.com/apache/tomcat / isAbsoluteUrl

Method isAbsoluteUrl

java/org/apache/jasper/tagplugins/jstl/Util.java:101–118  ·  view source on GitHub ↗

Returns true if our current URL is absolute, false otherwise. taken from org.apache.taglibs.standard.tag.common.core.ImportSupport @param url The URL @return true if the URL is absolute

(String url)

Source from the content-addressed store, hash-verified

99 * @return <code>true</code> if the URL is absolute
100 */
101 public static boolean isAbsoluteUrl(String url) {
102 if (url == null) {
103 return false;
104 }
105
106 int colonPos = url.indexOf(':');
107 if (colonPos == -1) {
108 return false;
109 }
110
111 for (int i = 0; i < colonPos; i++) {
112 if (VALID_SCHEME_CHAR.indexOf(url.charAt(i)) == -1) {
113 return false;
114 }
115 }
116
117 return true;
118 }
119
120 /**
121 * Get the value associated with a content-type attribute. Syntax defined in RFC 2045, section 5.1. taken from

Callers 1

resolveUrlMethod · 0.95

Calls 2

charAtMethod · 0.80
indexOfMethod · 0.45

Tested by

no test coverage detected