org.shredzone.flattr4j.model
Class Category

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

public class Category
extends Resource
implements CategoryId

A single Category that is available for Things. Two Category 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
Category(FlattrObject data)
           
 
Method Summary
 boolean equals(Object obj)
           
 String getCategoryId()
          Category id to be used with Flattr.
 String getName()
          Category name to be used for humans.
 int hashCode()
           
static CategoryId withId(String id)
          Returns a CategoryId for the given Category 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

Category

public Category(FlattrObject data)
Method Detail

withId

public static CategoryId withId(String id)
Returns a CategoryId for the given Category id.

Parameters:
id - Category id
Returns:
A CategoryId object for this id

getCategoryId

public String getCategoryId()
Category id to be used with Flattr.

Specified by:
getCategoryId in interface CategoryId
Returns:
Category id

getName

public String getName()
Category name to be used for humans.


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.