/** ** Sets the 'port' */ public boolean setPort(int _port) { String uri = this.getURI(); if ((_port > 0) && URIArg.isAbsoluteURL(uri)) { try { URL oldURI = new URL(uri); String proto = oldURI.getProtocol(); String host = oldURI.getHost(); int port = _port; String file = oldURI.getFile(); URL newURI = new URL(proto, host, port, file); this._setURI(newURI.toString()); return true; } catch (MalformedURLException mue) { // error } } return false; }