com.tumblr.jumblr.types
Class Blog

java.lang.Object
  extended by com.tumblr.jumblr.types.Resource
      extended by com.tumblr.jumblr.types.Blog

public class Blog
extends Resource

This class represents an individual Tumbelog

Author:
jc

Field Summary
 
Fields inherited from class com.tumblr.jumblr.types.Resource
client
 
Constructor Summary
Blog()
           
 
Method Summary
 String avatar()
           
 String avatar(Integer size)
          Get the avatar for this blog (of a given size
 boolean canAsk()
          Can we ask questions on this blog?
 boolean canAskAnonymously()
          Can we ask questions on this blog anonymously?
 List<Post> draftPosts()
           
 List<Post> draftPosts(Map<String,?> options)
          Get the draft posts for this blog
 void follow()
          Follow this blog
 List<User> followers()
           
 List<User> followers(Map<String,?> options)
          Get followers for this blog
 String getDescription()
          Get the description of this blog
 Integer getLikeCount()
          Get the number of likes for this blog
 String getName()
          Get the name of this blog
 Post getPost(Long postId)
          Get an individual post by id
 Integer getPostCount()
          Get the number of posts for this blog
 String getTitle()
          Get the title of this blog
 Long getUpdated()
          Get the time of the most recent post (in seconds since epoch)
 List<Post> likedPosts()
           
 List<Post> likedPosts(Map<String,?> options)
          Get likes posts for this blog
<T extends Post>
T
newPost(Class<T> klass)
          Create a new post of a given type for this blog
 List<Post> posts()
           
 List<Post> posts(Map<String,?> options)
          Get the posts for this blog
 List<Post> queuedPosts()
           
 List<Post> queuedPosts(Map<String,?> options)
          Get the queued posts for this blog
 void setName(String name)
          Set the name of this blog
 List<Post> submissions()
           
 List<Post> submissions(Map<String,?> options)
          Get the submissions for this blog
 void unfollow()
          Unfollow this blog
 
Methods inherited from class com.tumblr.jumblr.types.Resource
getClient, setClient
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Blog

public Blog()
Method Detail

getDescription

public String getDescription()
Get the description of this blog

Returns:
String description

canAsk

public boolean canAsk()
Can we ask questions on this blog?

Returns:
boolean

canAskAnonymously

public boolean canAskAnonymously()
Can we ask questions on this blog anonymously?

Returns:
boolean

getPostCount

public Integer getPostCount()
Get the number of posts for this blog

Returns:
int the number of posts

getLikeCount

public Integer getLikeCount()
Get the number of likes for this blog

Returns:
int the number of likes

getUpdated

public Long getUpdated()
Get the time of the most recent post (in seconds since epoch)

Returns:
Long of time

getTitle

public String getTitle()
Get the title of this blog

Returns:
The title of the blog

getName

public String getName()
Get the name of this blog

Returns:
The name of the blog

avatar

public String avatar(Integer size)
Get the avatar for this blog (of a given size

Parameters:
size - the size to get the avatar for
Returns:
A string URL for the avatar

avatar

public String avatar()

followers

public List<User> followers(Map<String,?> options)
Get followers for this blog

Parameters:
options - a map of options (or null)
Returns:
A List of users

followers

public List<User> followers()

posts

public List<Post> posts(Map<String,?> options)
Get the posts for this blog

Parameters:
options - a map of options (or null)
Returns:
A List of posts

posts

public List<Post> posts()

getPost

public Post getPost(Long postId)
Get an individual post by id

Parameters:
postId - the id of the post to retrieve
Returns:
the post (or null)

likedPosts

public List<Post> likedPosts(Map<String,?> options)
Get likes posts for this blog

Parameters:
options - a map of options (or null)
Returns:
A List of posts

likedPosts

public List<Post> likedPosts()

follow

public void follow()
Follow this blog


unfollow

public void unfollow()
Unfollow this blog


queuedPosts

public List<Post> queuedPosts(Map<String,?> options)
Get the queued posts for this blog

Parameters:
options - the options (or null)
Returns:
a List of posts

queuedPosts

public List<Post> queuedPosts()

draftPosts

public List<Post> draftPosts(Map<String,?> options)
Get the draft posts for this blog

Parameters:
options - the options (or null)
Returns:
a List of posts

draftPosts

public List<Post> draftPosts()

submissions

public List<Post> submissions(Map<String,?> options)
Get the submissions for this blog

Parameters:
options - the options (or null)
Returns:
a List of posts

submissions

public List<Post> submissions()

newPost

public <T extends Post> T newPost(Class<T> klass)
                       throws IllegalAccessException,
                              InstantiationException
Create a new post of a given type for this blog

Parameters:
klass - the class of the post to make
Returns:
new post
Throws:
IllegalAccessException
InstantiationException

setName

public void setName(String name)
Set the name of this blog

Parameters:
name - the name to set


Copyright © 2013. All Rights Reserved.