public class DbxAppInfo extends Dumpable implements Serializable
Modifier and Type | Field and Description |
---|---|
DbxHost |
host
This is almost always
DbxHost.Default . |
String |
key
Your Dropbox app key (OAuth calls this the consumer key).
|
static JsonReader<String> |
KeyReader |
static JsonReader<DbxAppInfo> |
Reader |
String |
secret
Your Dropbox app secret (OAuth calls this the consumer secret).
|
static JsonReader<String> |
SecretReader |
static long |
serialVersionUID |
Constructor and Description |
---|
DbxAppInfo(String key,
String secret) |
DbxAppInfo(String key,
String secret,
DbxHost host) |
Modifier and Type | Method and Description |
---|---|
static void |
checkKeyArg(String key) |
static void |
checkSecretArg(String secret) |
protected void |
dumpFields(DumpWriter out) |
static String |
getKeyFormatError(String key)
If they key's format looks correct, return
null . |
static String |
getSecretFormatError(String key)
If they secret's format looks correct, return
null . |
static String |
getTokenPartError(String s) |
getTypeName, toString, toString, toStringMultiline, toStringMultiline
public static final long serialVersionUID
public final String key
public final String secret
Make sure that this is kept a secret. Someone with your app secret can impesonate your application. People sometimes ask for help on the Dropbox API forums and copy/paste their code, which sometimes includes their app secret. Do not do that.
public final DbxHost host
DbxHost.Default
. This is only set differently for testing
purposes.public static final JsonReader<DbxAppInfo> Reader
public static final JsonReader<String> KeyReader
public static final JsonReader<String> SecretReader
protected void dumpFields(DumpWriter out)
dumpFields
in class Dumpable
public static String getKeyFormatError(String key)
null
. Otherwise return
a string that describes what the problem is.
NOTE: This function only performs some cursory checks on the format of the key.
Even if it returns null
(which means "no problem"), it doesn't mean
that what you passed in is an actual valid Dropbox API app key.
public static String getSecretFormatError(String key)
null
. Otherwise return
a string that describes what the problem is.
NOTE: This function only performs some cursory checks on the format. Even if it
returns null
(which means "no problem"), it doesn't mean that what
you passed in is an actual valid Dropbox API app key.
public static void checkKeyArg(String key)
public static void checkSecretArg(String secret)
Copyright © 2014. All rights reserved.