public class Session extends Object
Session
instance is passed to all methods requiring previous authentication.Authenticator
Modifier and Type | Method and Description |
---|---|
static Session |
createSession(String apiKey,
String secret,
String sessionKey)
Restores a Session instance with the given session key.
|
static Session |
createSession(String apiKey,
String secret,
String sessionKey,
String username,
boolean subscriber)
Restores a Session instance with the given session key.
|
String |
getApiKey() |
String |
getKey() |
String |
getSecret() |
String |
getUsername() |
boolean |
isSubscriber() |
public static Session createSession(String apiKey, String secret, String sessionKey)
apiKey
- An api keysecret
- A secretsessionKey
- The previously obtained session keypublic static Session createSession(String apiKey, String secret, String sessionKey, String username, boolean subscriber)
apiKey
- An api keysecret
- A secretsessionKey
- The previously obtained session keyusername
- A Last.fm usernamesubscriber
- Subscriber statuspublic String getSecret()
public String getApiKey()
public String getKey()
public boolean isSubscriber()
public String getUsername()