/** * Compare two URLs, excluding the "ref" fields. Returns <code>true</code> * if this <code>URL</code> and the <code>other</code> argument both refer * to the same resource. The two <code>URLs</code> might not both contain * the same anchor. */ public boolean sameFile(URL other) { if (!compare(protocol, other.getProtocol())) return (false); if (!compare(host, other.getHost())) return (false); if (port != other.getPort()) return (false); if (!compare(file, other.getFile())) return (false); return (true); }
/** * Compare two URLs, excluding the "ref" fields. Returns <code>true</code> * if this <code>URL</code> and the <code>other</code> argument both refer * to the same resource. The two <code>URLs</code> might not both contain * the same anchor. */ public boolean sameFile(URL other) { if (!compare(protocol, other.getProtocol())) return (false); if (!compare(host, other.getHost())) return (false); if (port != other.getPort()) return (false); if (!compare(file, other.getFile())) return (false); return (true); }
/** * Compare two URLs, excluding the "ref" fields. Returns <code>true</code> * if this <code>URL</code> and the <code>other</code> argument both refer * to the same resource. The two <code>URLs</code> might not both contain * the same anchor. */ public boolean sameFile(URL other) { if (!compare(protocol, other.getProtocol())) return (false); if (!compare(host, other.getHost())) return (false); if (port != other.getPort()) return (false); if (!compare(file, other.getFile())) return (false); return (true); }
/** * Compare two URLs, excluding the "ref" fields. Returns <code>true</code> * if this <code>URL</code> and the <code>other</code> argument both refer * to the same resource. The two <code>URLs</code> might not both contain * the same anchor. */ public boolean sameFile(URL other) { if (!compare(protocol, other.getProtocol())) return (false); if (!compare(host, other.getHost())) return (false); if (port != other.getPort()) return (false); if (!compare(file, other.getFile())) return (false); return (true); }
/** * Compare two URLs, excluding the "ref" fields. Returns <code>true</code> * if this <code>URL</code> and the <code>other</code> argument both refer * to the same resource. The two <code>URLs</code> might not both contain * the same anchor. */ public boolean sameFile(URL other) { if (!compare(protocol, other.getProtocol())) return (false); if (!compare(host, other.getHost())) return (false); if (port != other.getPort()) return (false); if (!compare(file, other.getFile())) return (false); return (true); }
/** * Compare two URLs, excluding the "ref" fields. Returns <code>true</code> * if this <code>URL</code> and the <code>other</code> argument both refer * to the same resource. The two <code>URLs</code> might not both contain * the same anchor. */ public boolean sameFile(URL other) { if (!compare(protocol, other.getProtocol())) return (false); if (!compare(host, other.getHost())) return (false); if (port != other.getPort()) return (false); if (!compare(file, other.getFile())) return (false); return (true); }
/** * Compare two URLs, excluding the "ref" fields. Returns <code>true</code> * if this <code>URL</code> and the <code>other</code> argument both refer * to the same resource. The two <code>URLs</code> might not both contain * the same anchor. */ public boolean sameFile(URL other) { if (!compare(protocol, other.getProtocol())) return (false); if (!compare(host, other.getHost())) return (false); if (port != other.getPort()) return (false); if (!compare(file, other.getFile())) return (false); return (true); }
/** * Compare two URLs for equality. The result is <code>true</code> if and * only if the argument is not null, and is a <code>URL</code> object * that represents the same <code>URL</code> as this object. Two * <code>URLs</code> are equal if they have the same protocol and * reference the same host, the same port number on the host, * and the same file and anchor on the host. * * @param obj The URL to compare against */ @Override public boolean equals(Object obj) { if (!(obj instanceof URL)) return (false); URL other = (URL) obj; if (!sameFile(other)) return (false); return (compare(ref, other.getRef())); }
/** * Compare two URLs for equality. The result is <code>true</code> if and * only if the argument is not null, and is a <code>URL</code> object * that represents the same <code>URL</code> as this object. Two * <code>URLs</code> are equal if they have the same protocol and * reference the same host, the same port number on the host, * and the same file and anchor on the host. * * @param obj The URL to compare against */ @Override public boolean equals(Object obj) { if (!(obj instanceof URL)) return (false); URL other = (URL) obj; if (!sameFile(other)) return (false); return (compare(ref, other.getRef())); }
/** * Compare two URLs for equality. The result is <code>true</code> if and * only if the argument is not null, and is a <code>URL</code> object * that represents the same <code>URL</code> as this object. Two * <code>URLs</code> are equal if they have the same protocol and * reference the same host, the same port number on the host, * and the same file and anchor on the host. * * @param obj The URL to compare against */ public boolean equals(Object obj) { if (obj == null) return (false); if (!(obj instanceof URL)) return (false); URL other = (URL) obj; if (!sameFile(other)) return (false); return (compare(ref, other.getRef())); }
/** * Compare two URLs for equality. The result is <code>true</code> if and * only if the argument is not null, and is a <code>URL</code> object * that represents the same <code>URL</code> as this object. Two * <code>URLs</code> are equal if they have the same protocol and * reference the same host, the same port number on the host, * and the same file and anchor on the host. * * @param obj The URL to compare against */ @Override public boolean equals(Object obj) { if (!(obj instanceof URL)) return (false); URL other = (URL) obj; if (!sameFile(other)) return (false); return (compare(ref, other.getRef())); }
/** * Compare two URLs for equality. The result is <code>true</code> if and * only if the argument is not null, and is a <code>URL</code> object * that represents the same <code>URL</code> as this object. Two * <code>URLs</code> are equal if they have the same protocol and * reference the same host, the same port number on the host, * and the same file and anchor on the host. * * @param obj The URL to compare against */ @Override public boolean equals(Object obj) { if (!(obj instanceof URL)) return (false); URL other = (URL) obj; if (!sameFile(other)) return (false); return (compare(ref, other.getRef())); }
/** * Compare two URLs for equality. The result is <code>true</code> if and * only if the argument is not null, and is a <code>URL</code> object * that represents the same <code>URL</code> as this object. Two * <code>URLs</code> are equal if they have the same protocol and * reference the same host, the same port number on the host, * and the same file and anchor on the host. * * @param obj The URL to compare against */ public boolean equals(Object obj) { if (obj == null) return (false); if (!(obj instanceof URL)) return (false); URL other = (URL) obj; if (!sameFile(other)) return (false); return (compare(ref, other.getRef())); }
/** * Compare two URLs for equality. The result is <code>true</code> if and * only if the argument is not null, and is a <code>URL</code> object * that represents the same <code>URL</code> as this object. Two * <code>URLs</code> are equal if they have the same protocol and * reference the same host, the same port number on the host, * and the same file and anchor on the host. * * @param obj The URL to compare against */ public boolean equals(Object obj) { if (obj == null) return (false); if (!(obj instanceof URL)) return (false); URL other = (URL) obj; if (!sameFile(other)) return (false); return (compare(ref, other.getRef())); }