public final class FacebookFactory
extends java.lang.Object
implements java.io.Serializable
| Modifier and Type | Field and Description |
|---|---|
private Configuration |
conf |
(package private) static Authorization |
DEFAULT_AUTHORIZATION |
private static java.lang.reflect.Constructor<Facebook> |
FACEBOOK_CONSTRUCTOR |
private static long |
serialVersionUID |
private static Facebook |
SINGLETON |
| Constructor and Description |
|---|
FacebookFactory()
Creates a FacebookFactory with the root configuration.
|
FacebookFactory(Configuration conf)
Creates a FacebookFactory with the given configuration.
|
FacebookFactory(java.lang.String configTreePath)
Creates a FacebookFactory with a specified config tree
|
| Modifier and Type | Method and Description |
|---|---|
Facebook |
getInstance()
Returns a instance associated with the configuration bound to this factory.
|
Facebook |
getInstance(AccessToken accessToken)
Returns a OAuth Authenticated instance.
app Id and app Secret must be provided by facebook4j.properties, or system properties. Unlike OAuthSupport.setOAuthAccessToken(facebook4j.auth.AccessToken), this factory method potentially returns a cached instance. |
Facebook |
getInstance(Authorization auth) |
static Facebook |
getSingleton()
Returns default singleton Facebook instance.
|
private static final java.lang.reflect.Constructor<Facebook> FACEBOOK_CONSTRUCTOR
static final Authorization DEFAULT_AUTHORIZATION
private static final Facebook SINGLETON
private static final long serialVersionUID
private final Configuration conf
public FacebookFactory()
public FacebookFactory(Configuration conf)
conf - the configuration to usepublic FacebookFactory(java.lang.String configTreePath)
configTreePath - the pathpublic Facebook getInstance()
public Facebook getInstance(AccessToken accessToken)
OAuthSupport.setOAuthAccessToken(facebook4j.auth.AccessToken), this factory method potentially returns a cached instance.accessToken - access tokenpublic Facebook getInstance(Authorization auth)
public static Facebook getSingleton()