|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
java.lang.Objectjava.lang.Enum<ForceConnectionProperty>
com.force.sdk.connector.ForceConnectionProperty
public enum ForceConnectionProperty
Property that can be used for in a Force.com connection URL.
These enum values represent available Force.com connection URL properties. Each value contains two parts:
A Force.com connection URL is written using the property key name in key=value pairs which are separated by a semi-colon (';') delimiter. The exception is the Force.com endpoint property which is interpreted as the string which immediately follows the force:// protocol. For example, a Force.com connection URL with a username and password would look like this:
force://<endpoint value>;user=<username value>;password=<password value>
The validation regular expression allows for the validation of
property values within a Force.com connection URL.
Enum Constant Summary | |
---|---|
CLIENTID
The API client id to be used in a Force.com connection. |
|
ENDPOINT
The Force.com connection endpoint. |
|
OAUTH_KEY
The OAuth key to be used in a Force.com OAuth handshake. |
|
OAUTH_SECRET
The OAuth secret to be used in a Force.com OAuth handshake. |
|
PASSWORD
The password to be used in a Force.com connection. |
|
TIMEOUT
The timeout to be used in a Force.com connection. |
|
USER
The username to be used in a Force.com connection. |
Method Summary | |
---|---|
static ForceConnectionProperty |
fromPropertyName(String propertyName)
Load the ForceConnectionProperty enum value from a connection property name. |
String |
getPropertyName()
Returns the connection property name. |
Pattern |
getValidationRegex()
Returns the connection property validation regular expression |
void |
validateValue(String propertyValue)
Validations a connection property value. |
void |
validateValue(String propertyValue,
String customErrorMessage)
Validations a connection property value. |
static ForceConnectionProperty |
valueOf(String name)
Returns the enum constant of this type with the specified name. |
static ForceConnectionProperty[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared. |
Methods inherited from class java.lang.Enum |
---|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Enum Constant Detail |
---|
public static final ForceConnectionProperty ENDPOINT
public static final ForceConnectionProperty USER
public static final ForceConnectionProperty PASSWORD
public static final ForceConnectionProperty OAUTH_KEY
public static final ForceConnectionProperty OAUTH_SECRET
public static final ForceConnectionProperty CLIENTID
public static final ForceConnectionProperty TIMEOUT
Method Detail |
---|
public static ForceConnectionProperty[] values()
for (ForceConnectionProperty c : ForceConnectionProperty.values()) System.out.println(c);
public static ForceConnectionProperty valueOf(String name)
name
- the name of the enum constant to be returned.
IllegalArgumentException
- if this enum type has no constant
with the specified name
NullPointerException
- if the argument is nullpublic String getPropertyName()
The property name (with the exception of the endpoint property) is used as the key in a key=value pair within a Force.com connection URL.
public Pattern getValidationRegex()
The validation regular expression is used to valid a property value that is set in a key=value pair within a Force.com connection URL.
public void validateValue(String propertyValue)
Ensures that the connection property value is not null, has a length greater than zero and matches the validation regular expression.
propertyValue
- the connection property value
IllegalArgumentException
- if the given propertyValue is null or zero length or
does not match the validation regular expressionpublic void validateValue(String propertyValue, String customErrorMessage)
Ensures that the connection property value is not null, has a length greater than zero and matches the validation regular expression.
propertyValue
- the connection property valuecustomErrorMessage
- an error message to be included in the thrown exception message
should validation fail
IllegalArgumentException
- if the given propertyValue is null or zero length or
does not match the validation regular expressionpublic static ForceConnectionProperty fromPropertyName(String propertyName)
propertyName
- A connection property name
null
if no such value exists
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |