public final class Algorithmia
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static Algorithm |
algo(java.lang.String algoUri)
Initialize an Algorithm object using the default client
|
static AlgorithmiaClient |
client()
Returns the default Algorithmia client which will
look for ALGORITHMIA_API_KEY environment variable or java property
If no key is found, then requests will be unauthenticated which only works
when making requests from an algorithm running within the Algorithmia cluster
|
static AlgorithmiaClient |
client(int maxConnections)
Returns the default Algorithmia client which will
look for ALGORITHMIA_API_KEY environment variable or java property
If no key is found, then requests will be unauthenticated which only works
when making requests from an algorithm running within the Algorithmia cluster
|
static AlgorithmiaClient |
client(java.lang.String simpleKey)
Builds an Algorithmia client that makes all requests with your API key
If API key is null, the default client is returned, which will
look for ALGORITHMIA_API_KEY environment variable or java property
If no key is found, then requests will be unauthenticated which only works
when making requests from an algorithm running within the Algorithmia cluster
|
static AlgorithmiaClient |
client(java.lang.String simpleKey,
int maxConnections)
Builds an Algorithmia client that makes all requests with your API key
If API key is null, the default client is returned, which will
look for ALGORITHMIA_API_KEY environment variable or java property
If no key is found, then requests will be unauthenticated which only works
when making requests from an algorithm running within the Algorithmia cluster
|
static DataDirectory |
dir(java.lang.String path)
Initialize a DataDirectory object using the default client
|
static DataFile |
file(java.lang.String path)
Initialize an DataFile object using the default client
|
public static AlgorithmiaClient client()
public static AlgorithmiaClient client(int maxConnections)
maxConnections
- max number of concurrent connections to hold open to Algorithmiapublic static AlgorithmiaClient client(java.lang.String simpleKey)
simpleKey
- API Key for simple authentication (prefixed with "sim")public static AlgorithmiaClient client(java.lang.String simpleKey, int maxConnections)
simpleKey
- API Key for simple authentication (prefixed with "sim")maxConnections
- max number of concurrent connections to hold open to Algorithmiapublic static Algorithm algo(java.lang.String algoUri)
algoUri
- the algorithm's URI, e.g., algo://user/algonamepublic static DataDirectory dir(java.lang.String path)
path
- to a data directory, e.g., data://.my/foopublic static DataFile file(java.lang.String path)
path
- to a data file, e.g., data://.my/foo/bar.txt