Package org.exolab.jms.net.uri

Examples of org.exolab.jms.net.uri.URI


        try {
            result = createSocketProtected(info.getHost(), info.getPort());
            _alternativeURI = info.getAlternativeURI();
        } catch (ResourceException exception) {
            _alternativeURI = info.getURI();
            URI uri = info.getAlternativeURI();
            if (uri == null) {
                throw exception;
            }
            if (_log.isDebugEnabled()) {
                _log.debug("Failed to connect using URI=" + info.getURI()
                           + ", attempting URI=" + uri);
            }
            result = createSocketProtected(uri.getHost(), uri.getPort());
        }
        return result;
    }
View Full Code Here


     * Populates the supplied properties with connection accept properties.
     *
     * @param properties the properties to populate
     */
    protected void populateAcceptProperties(Properties properties) {
        URI uri = getURI(getExportURI());
        TCPSRequestInfo info;
        try {
            info = new TCPSRequestInfo(uri);
        } catch (ResourceException exception) {
            // should never happen
View Full Code Here

//         }
        ObjectRef ref = (ObjectRef) _objectMap.get(object);
        if (ref == null) {
            throw new NoSuchObjectException("Object not exported");
        }
        URI parsed = null;
        if (uri != null) {
            try {
                parsed = URIHelper.parse(uri);
            } catch (InvalidURIException exception) {
                throw new NoSuchObjectException(exception.getMessage());
View Full Code Here

            throws ResourceException {
        ManagedConnection result = null;

        if (info instanceof RMIRequestInfo) {
            RMIRequestInfo requestInfo = (RMIRequestInfo) info;
            URI uri = URIHelper.convertHostToAddress(requestInfo.getURI());

            Iterator iterator = connections.iterator();
            while (iterator.hasNext()) {
                RMIManagedConnection connection =
                        (RMIManagedConnection) iterator.next();
                if (connection.hasPrincipal(principal)
                        && uri.equals(connection.getRemoteURI())) {
                    result = connection;
                    break;
                }
            }
        }
View Full Code Here

            throws ResourceException {
        ManagedConnectionAcceptor result = null;

        if (info instanceof RMIRequestInfo) {
            RMIRequestInfo requestInfo = (RMIRequestInfo) info;
            URI uri = URIHelper.convertHostToAddress(requestInfo.getURI());
            Iterator iterator = acceptors.iterator();
            while (iterator.hasNext()) {
                RMIManagedConnectionAcceptor acceptor =
                        (RMIManagedConnectionAcceptor) iterator.next();
                if (uri.equals(acceptor.getURI())) {
                    result = acceptor;
                    break;
                }
            }
        }
View Full Code Here

        }
        if (uri == null) {
            throw new IllegalArgumentException("Argument 'uri' is null");
        }

        URI parsed = null;
        try {
            parsed = URIHelper.parse(uri);
        } catch (InvalidURIException exception) {
            throw new ExportException(exception.getMessage(), exception);
        }
View Full Code Here

            throw new IllegalArgumentException("Argument 'objID' is null");
        }
        if (uri == null) {
            throw new IllegalArgumentException("Argument 'uri' is null");
        }
        URI parsed = null;
        try {
            parsed = URIHelper.parse(uri);
        } catch (InvalidURIException exception) {
            throw new ExportException(exception.getMessage(), exception);
View Full Code Here

            throw new IllegalArgumentException("Argument 'object' is null");
        }
        if (uri == null) {
            throw new IllegalArgumentException("Argument 'uri' is null");
        }
        URI remoteURI = null;
        URI localURI = null;
        try {
            remoteURI = URIHelper.parse(uri);
        } catch (InvalidURIException exception) {
            throw new ExportException(exception.getMessage(), exception);
        }
View Full Code Here

     * @param uri the URI
     * @return the route address of <code>uri</code>, or <code>uri</code> if it
     *         isn't routed
     */
    private URI getRoute(URI uri) {
        URI result = (URI) _routes.get(uri);
        return (result == null) ? uri : result;
    }
View Full Code Here

     * @param listener the event listener
     * @throws InvalidURIException if <code>uri</code> is invalid
     */
    public void addCallerListener(String uri, CallerListener listener)
        throws InvalidURIException{
        URI parsed = URIHelper.parse(uri);
        parsed = URIHelper.convertHostToAddress(parsed);
        List list = null;
        synchronized (_listeners) {
            list = (List) _listeners.get(parsed);
            if (list == null) {
View Full Code Here

TOP

Related Classes of org.exolab.jms.net.uri.URI

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.