Class Session

java.lang.Object
de.umass.lastfm.Session

public class Session extends Object
Contains Session data relevant for making API calls which require authentication. A Session instance is passed to all methods requiring previous authentication.
Author:
Janni Kovacs
See Also:
  • Method Details

    • createSession

      public static Session createSession(String apiKey, String secret, String sessionKey)
      Restores a Session instance with the given session key.
      Parameters:
      apiKey - An api key
      secret - A secret
      sessionKey - The previously obtained session key
      Returns:
      a Session instance
    • createSession

      public static Session createSession(String apiKey, String secret, String sessionKey, String username, boolean subscriber)
      Restores a Session instance with the given session key.
      Parameters:
      apiKey - An api key
      secret - A secret
      sessionKey - The previously obtained session key
      username - A Last.fm username
      subscriber - Subscriber status
      Returns:
      a Session instance
    • getSecret

      public String getSecret()
    • getApiKey

      public String getApiKey()
    • getKey

      public String getKey()
    • isSubscriber

      public boolean isSubscriber()
    • getUsername

      public String getUsername()