com.basho.riak.client.raw.http
Class HTTPRiakClientFactory

java.lang.Object
  extended by com.basho.riak.client.raw.http.HTTPRiakClientFactory
All Implemented Interfaces:
RiakClientFactory

public class HTTPRiakClientFactory
extends Object
implements RiakClientFactory

Factory for creating HTTPClientAdapter instances configured by the given HTTPClientConfig. Converts an HTTPClientConfig to a RiakConfig

Author:
russell

Method Summary
 boolean accepts(Class<? extends Configuration> configClass)
          Is the concrete factory able to create RawClients with configClass Configurations? Call before newClient.
static HTTPRiakClientFactory getInstance()
           
 RawClient newClient(Configuration conf)
          Create a new RawClient instance configured by config
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static HTTPRiakClientFactory getInstance()

accepts

public boolean accepts(Class<? extends Configuration> configClass)
Description copied from interface: RiakClientFactory
Is the concrete factory able to create RawClients with configClass Configurations? Call before newClient.

Specified by:
accepts in interface RiakClientFactory
Parameters:
configClass - the Configuration implementation
Returns:
true if this factory can create a RawClient for the configClass false otherwise

newClient

public RawClient newClient(Configuration conf)
Description copied from interface: RiakClientFactory
Create a new RawClient instance configured by config

Specified by:
newClient in interface RiakClientFactory
Parameters:
conf - a specific implementation of Configuration
Returns:
the configured RawClient


Copyright © 2012. All Rights Reserved.