@Override
    public void register(Client client) throws RegistrationException, NotAuthorizedException {
        if (client.getApiKey() == null) {
            throw new RegistrationException("Cannot Register Client: Missing API Key"); //$NON-NLS-1$
        }

        final Set<Throwable> errorHolder = new HashSet<>();
        final CountDownLatch latch = new CountDownLatch(1);
        // Register client; latch until result returned and evaluated
        getEngine().getRegistry().registerClient(client, latchedResultHandler(latch, errorHolder));
        awaitOnLatch(latch, errorHolder);
    }
@ Override public void register ( Client client ) throws RegistrationException , NotAuthorizedException { if ( client . getApiKey ( ) == null ) { throw new RegistrationException ( "Cannot Register Client: Missing API Key" ) ; } final Set < Throwable > errorHolder = new HashSet < > ( ) ; final CountDownLatch latch = new CountDownLatch ( 1 ) ; getEngine ( ) . getRegistry ( ) . registerClient ( client , latchedResultHandler ( latch , errorHolder ) ) ; awaitOnLatch ( latch , errorHolder ) ; }
@see io.apiman.gateway.api.rest.contract.IClientResource#register(io.apiman.gateway.engine.beans.Client)