All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.zeroc.Ice.LocatorFinder Maven / Gradle / Ivy

//
// Copyright (c) ZeroC, Inc. All rights reserved.
//
//
// Ice version 3.7.2
//
// 
//
// Generated from file `Locator.ice'
//
// Warning: do not edit this file.
//
// 
//

package com.zeroc.Ice;

/**
 * This inferface should be implemented by services implementing the
 * Ice::Locator interface. It should be advertised through an Ice
 * object with the identity `Ice/LocatorFinder'. This allows clients
 * to retrieve the locator proxy with just the endpoint information of
 * the service.
 **/
public interface LocatorFinder extends Object
{
    /**
     * Get the locator proxy implemented by the process hosting this
     * finder object. The proxy might point to several replicas.
     * @param current The Current object for the invocation.
     * @return The locator proxy.
     **/
    LocatorPrx getLocator(Current current);

    /** @hidden */
    static final String[] _iceIds =
    {
        "::Ice::LocatorFinder",
        "::Ice::Object"
    };

    @Override
    default String[] ice_ids(Current current)
    {
        return _iceIds;
    }

    @Override
    default String ice_id(Current current)
    {
        return ice_staticId();
    }

    static String ice_staticId()
    {
        return "::Ice::LocatorFinder";
    }

    /**
     * @hidden
     * @param obj -
     * @param inS -
     * @param current -
     * @return -
    **/
    static java.util.concurrent.CompletionStage _iceD_getLocator(LocatorFinder obj, final com.zeroc.IceInternal.Incoming inS, Current current)
    {
        Object._iceCheckMode(null, current.mode);
        inS.readEmptyParams();
        LocatorPrx ret = obj.getLocator(current);
        OutputStream ostr = inS.startWriteParams();
        ostr.writeProxy(ret);
        inS.endWriteParams(ostr);
        return inS.setResult(ostr);
    }

    /** @hidden */
    final static String[] _iceOps =
    {
        "getLocator",
        "ice_id",
        "ice_ids",
        "ice_isA",
        "ice_ping"
    };

    /** @hidden */
    @Override
    default java.util.concurrent.CompletionStage _iceDispatch(com.zeroc.IceInternal.Incoming in, Current current)
        throws UserException
    {
        int pos = java.util.Arrays.binarySearch(_iceOps, current.operation);
        if(pos < 0)
        {
            throw new OperationNotExistException(current.id, current.facet, current.operation);
        }

        switch(pos)
        {
            case 0:
            {
                return _iceD_getLocator(this, in, current);
            }
            case 1:
            {
                return Object._iceD_ice_id(this, in, current);
            }
            case 2:
            {
                return Object._iceD_ice_ids(this, in, current);
            }
            case 3:
            {
                return Object._iceD_ice_isA(this, in, current);
            }
            case 4:
            {
                return Object._iceD_ice_ping(this, in, current);
            }
        }

        assert(false);
        throw new OperationNotExistException(current.id, current.facet, current.operation);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy