public GatewayServer get(List<GatewayServer> list) {
        if (list.size() == 0) {
            throw new IllegalArgumentException("list must not be zero size");
        }

        if (list.size() == 1) {
            return list.get(0);
        }

        if (this.method == METHOD.RANDOM) {
            return random(list);
        }

        return roundrobin(list);
    }
public GatewayServer get(List<GatewayServer> list) {
        if (list.size() == 0) {
            throw new IllegalArgumentException("list must not be zero size");
        }

        if (list.size() == 1) {
            return list.get(0);
        }

        if (this.method == METHOD.RANDOM) {
            return random(list);
        }

        return roundrobin(list);
    }
public GatewayServer get ( List < GatewayServer > list ) { if ( list . size ( ) == 0 ) { throw new IllegalArgumentException ( "list must not be zero size" ) ; } if ( list . size ( ) == 1 ) { return list . get ( 0 ) ; } if ( this . method == METHOD . RANDOM ) { return random ( list ) ; } return roundrobin ( list ) ; }
Gets the.

@param list the list
@return the gateway server
Gets the .