org.shredzone.flattr4j.model
Class User

java.lang.Object
  extended by org.shredzone.flattr4j.model.Resource
      extended by org.shredzone.flattr4j.model.User
All Implemented Interfaces:
Serializable, UserId

public class User
extends Resource
implements UserId

A User. Two User are considered equal if they contain the same id.

Author:
Richard "Shred" Körber
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.shredzone.flattr4j.model.Resource
data
 
Constructor Summary
User(FlattrObject data)
           
 
Method Summary
 boolean equals(Object obj)
           
 String getCity()
          City the user lives in.
 String getCountry()
          Country the user lives in.
 String getDescription()
          User's own description.
 String getEmail()
          User's email address.
 String getFirstname()
          User's real first name.
 String getGravatar()
          URL of the user's picture at Gravatar.
 String getLastname()
          User's real last name.
 String getLink()
          Human readable link to this resource at Flattr.
 Date getRegisteredAt()
          Registration date.
 String getResource()
          URL that returns details of this resource as JSON.
 String getUserId()
          User id.
 int hashCode()
           
static UserId withId(String id)
          Returns a UserId for the given User id.
 
Methods inherited from class org.shredzone.flattr4j.model.Resource
toFlattrObject, toJSON
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

User

public User(FlattrObject data)
Method Detail

withId

public static UserId withId(String id)
Returns a UserId for the given User id.

Parameters:
id - User id
Returns:
A UserId object for this id

getUserId

public String getUserId()
User id.

Specified by:
getUserId in interface UserId
Returns:
User id

getResource

public String getResource()
URL that returns details of this resource as JSON.


getLink

public String getLink()
Human readable link to this resource at Flattr.


getFirstname

public String getFirstname()
User's real first name.


getLastname

public String getLastname()
User's real last name.


getCity

public String getCity()
City the user lives in.


getCountry

public String getCountry()
Country the user lives in.


getEmail

@RequiredScope(value=EXTENDEDREAD)
public String getEmail()
User's email address.


getDescription

public String getDescription()
User's own description.


getGravatar

public String getGravatar()
URL of the user's picture at Gravatar.


getRegisteredAt

@RequiredScope(value=EXTENDEDREAD)
public Date getRegisteredAt()
Registration date.

Since:
2.0

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2010-2012. All Rights Reserved.