bitfinex client

@param config - config
@return {@link SimpleBitfinexApiBroker} client
556250
public static BitfinexWebsocketClient newSimpleClient(final BitfinexWebsocketConfiguration config) {
        final BitfinexApiCallbackRegistry callbackRegistry = new BitfinexApiCallbackRegistry();
		final SequenceNumberAuditor sequenceNumberAuditor = new SequenceNumberAuditor();
		
		sequenceNumberAuditor.setErrorPolicy(config.getErrorPolicy());
		
		return new SimpleBitfinexApiBroker(config, callbackRegistry, sequenceNumberAuditor, false);
    }
710624
public static BitfinexFundingSymbol funding(final String bitfinexCurrency) {
		
        final String currencyNonNull = Objects.requireNonNull(bitfinexCurrency).toUpperCase();
        final BitfinexFundingCurrency currency = new BitfinexFundingCurrency(currencyNonNull);
        
		return funding(currency);
	}
651460
public FutureOperation subscribeCandles(final BitfinexCandlestickSymbol symbol) throws BitfinexClientException {
		
		final FutureOperation future = new FutureOperation(symbol);
		pendingSubscribes.registerFuture(future);
		
		final SubscribeCandlesCommand command = new SubscribeCandlesCommand(symbol);
		client.sendCommand(command);
		
		return future;
	}
356581
public TDClientConfig buildConfig()
    {
        return new TDClientConfig(
                endpoint,
                port,
                useSSL,
                apiKey,
                user,
                password,
                proxy,
                retryLimit,
                retryInitialIntervalMillis,
                retryMaxIntervalMillis,
                retryMultiplier,
                connectTimeoutMillis,
                readTimeoutMillis,
                connectionPoolSize,
                headers);
    }
529391
public static RedissonRxClient createRx(Config config) {
        RedissonRx react = new RedissonRx(config);
        if (config.isReferenceEnabled()) {
            react.enableRedissonReferenceSupport();
        }
        return react;
    }
329224
public static function factory($config = array())
	{
		$client = new self($config['baseURL'], $config);
		$client->setDefaultOption('headers/Content-Type', 'application/json');
		$client->setDefaultOption('X-Kinvey-API-Version', 2);
		$client->setAuthMode($config['defaultAuthMode']);

		$client = self::registerPlugins($client);

		return $client;
	}
391539
public static RedissonClient create(Config config) {
        Redisson redisson = new Redisson(config);
        if (config.isReferenceEnabled()) {
            redisson.enableRedissonReferenceSupport();
        }
        return redisson;
    }
762276
function CryptoKittiesClient(config) {
  const ethClient = new EthereumClient(config);
  const coreContract = ethClient.createContractWrapper(config.ckCoreAddress, ckCoreAbi);

  function getEvents(eventName, fromBlock, toBlock) {
    let res = null;
    switch (eventName) {
      case 'Birth':
      case 'Transfer':
      case 'Pregnant':
        res = ethClient.getEvents(coreContract, eventName, fromBlock, toBlock);
        break;
      default:
        break;
    }
    return res;
  }

  function getCurrentBlockNumber() {
    return ethClient.getCurrentBlockNumber();
  }

  this.getEvents = getEvents;
  this.getCurrentBlockNumber = getCurrentBlockNumber;
}
1083103
private static DbxClientV2 createClient(DbxAuthInfo auth, StandardHttpRequestor.Config config) {
        String clientUserAgentId = "examples-longpoll";
        StandardHttpRequestor requestor = new StandardHttpRequestor(config);
        DbxRequestConfig requestConfig = DbxRequestConfig.newBuilder(clientUserAgentId)
            .withHttpRequestor(requestor)
            .build();

        return new DbxClientV2(requestConfig, auth.getAccessToken(), auth.getHost());
    }
1118088
function Client(config = {}) {
  this.config = config;
  this.logger = new Logger(config);

  //Client is a required field, so throw error if it's not supplied.
  //If 'this.dialect' is set, then this is a 'super()' call, in which case
  //'client' does not have to be set as it's already assigned on the client prototype.

  if (this.dialect && !this.config.client) {
    this.logger.warn(
      `Using 'this.dialect' to identify the client is deprecated and support for it will be removed in the future. Please use configuration option 'client' instead.`
    );
  }
  const dbClient = this.config.client || this.dialect;
  if (!dbClient) {
    throw new Error(`knex: Required configuration option 'client' is missing.`);
  }

  if (config.version) {
    this.version = config.version;
  }

  this.connectionSettings = cloneDeep(config.connection || {});
  if (this.driverName && config.connection) {
    this.initializeDriver();
    if (!config.pool || (config.pool && config.pool.max !== 0)) {
      this.initializePool(config);
    }
  }
  this.valueForUndefined = this.raw('DEFAULT');
  if (config.useNullAsDefault) {
    this.valueForUndefined = null;
  }
}
442572
public static SSLContext buildSSLContext(HttpClientConfig config) throws IOException, GeneralSecurityException {

    KeyManagerFactory kmf = null;
    if (isSslKeyManagerEnabled(config)) {
      kmf = getKeyManagerFactory(config.getKeyStorePath(),
          new StoreProperties(config.getKeyStorePassword(), config.getKeyManagerType(),
              config.getKeyStoreType(), config.getKeyStoreProvider()));
    }
    TrustManagerFactory tmf = null;
    if (isSslTrustStoreEnbaled(config)) {
      tmf = getTrustManagerFactory(config.getTrustStorePath(), new StoreProperties(config.getTrustStorePassword(),
          config.getTrustManagerType(), config.getTrustStoreType(), config.getTrustStoreProvider()));
    }

    SSLContext sslContext = SSLContext.getInstance(config.getSslContextType());
    sslContext.init(kmf != null ? kmf.getKeyManagers() : null,
        tmf != null ? tmf.getTrustManagers() : null,
        null);

    return sslContext;
  }
1364520
public FutureOperation subscribeExecutedTrades(final BitfinexExecutedTradeSymbol tradeSymbol) {

		final FutureOperation future = new FutureOperation(tradeSymbol);
		pendingSubscribes.registerFuture(future);
		
		final SubscribeTradesCommand subscribeOrderbookCommand
			= new SubscribeTradesCommand(tradeSymbol);
		
		client.sendCommand(subscribeOrderbookCommand);
		
		return future;
	}
842935
public static Exchange createExchangeFromJsonConfiguration() throws IOException {

    ExchangeSpecification exSpec = new ExchangeSpecification(BitcoindeExchange.class);
    ObjectMapper mapper = new ObjectMapper();
    InputStream is =
        ExchangeUtils.class
            .getClassLoader()
            .getResourceAsStream("bitcoinde/exchangeConfiguration.json");
    if (is == null) {
      // logger.warn("No bitcoinde/exchangeConfiguration.json file found. Returning null
      // exchange.");
      return null;
    }
    try {
      ExchangeConfiguration conf = mapper.readValue(is, ExchangeConfiguration.class);
      //   logger.debug(conf.toString());

      if (conf.apiKey != null) exSpec.setApiKey(conf.apiKey);
      if (conf.secretKey != null) exSpec.setSecretKey(conf.secretKey);
    } catch (Exception e) {
      //  logger.warn("An exception occured while loading the bitcoinde/exchangeConfiguration.json
      // file from the classpath. " + "Returning null exchange.", e);
      return null;
    }

    Exchange exchange = ExchangeFactory.INSTANCE.createExchange(exSpec);
    exchange.remoteInit();
    return exchange;
  }
370496
public static SystemMain getInstance(Properties config) {
        return Guice.createInjector(new SystemInitializer(config)).getInstance(SystemMain.class);
    }
277919
public static Bitmap grayToBitmap( GrayU8 input , Bitmap.Config config ) {
		Bitmap output = Bitmap.createBitmap(input.width, input.height, config);
		
		grayToBitmap(input,output,null);
		
		return output;
	}
234313
public SimpleConfiguration getClientConfiguration() {
    SimpleConfiguration clientConfig = new SimpleConfiguration();
    Iterator<String> iter = getKeys();
    while (iter.hasNext()) {
      String key = iter.next();
      if (key.startsWith(CONNECTION_PREFIX) || key.startsWith(ACCUMULO_PREFIX)
          || key.startsWith(CLIENT_PREFIX)) {
        clientConfig.setProperty(key, getRawString(key));
      }
    }
    return clientConfig;
  }
772017
public static Client using(final Configuration configuration, final ClientConsumerType type, final int poolSize) throws Exception {
    return new Client(configuration, type, poolSize);
  }