|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectch.odi.justblog.api.blogger.Blogger
Facade for the Blogger API. First set the credentials, call getUserInfo and getUsersBlogs. Then set the desired Blog. Now call newPost, editPost, getTemplate and setTemplate.
| Field Summary | |
static java.lang.String |
TEMPLATE_TYPE_ARCHIVE
|
static java.lang.String |
TEMPLATE_TYPE_MAIN
|
| Constructor Summary | |
Blogger(java.net.URL url)
|
|
| Method Summary | |
void |
editPost(java.lang.String id,
java.lang.String posting,
boolean publish)
Edits a given post. |
java.lang.String |
getTemplate(java.lang.String type)
Retrieves a template. |
UserInfo |
getUserInfo()
Returns the UserInfo object of the user set by the credentials. |
java.util.Collection |
getUsersBlogs()
Returns information about all the blogs a given user is a member of. |
java.lang.String |
newPost(java.lang.String posting,
boolean publish)
Makes a new post to a designated blog. |
void |
setBlog(BloggerBlog blog)
|
void |
setCredentials(java.lang.String username,
char[] password)
Sets the user credentials. |
void |
setTemplate(java.lang.String type,
java.lang.String template)
Sets a template. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String TEMPLATE_TYPE_MAIN
public static final java.lang.String TEMPLATE_TYPE_ARCHIVE
| Constructor Detail |
public Blogger(java.net.URL url)
url - URL of the XML-RPC2 endpoint.| Method Detail |
public void setBlog(BloggerBlog blog)
public void setCredentials(java.lang.String username,
char[] password)
username - password -
public java.lang.String newPost(java.lang.String posting,
boolean publish)
throws java.io.IOException,
ApiException
posting - The content to publishpublish - if true the content if made publicly available immediately
java.io.IOException
ApiException
public void editPost(java.lang.String id,
java.lang.String posting,
boolean publish)
throws java.io.IOException,
ApiException
id - posting - publish -
java.io.IOException
ApiException
public java.util.Collection getUsersBlogs()
throws java.io.IOException,
ApiException
java.io.IOException
ApiException
public UserInfo getUserInfo()
throws ApiException,
java.io.IOException
ApiException
java.io.IOExceptionpublic java.lang.String getTemplate(java.lang.String type)
type - one of the TEMPLATE_TYPE_* constants
public void setTemplate(java.lang.String type,
java.lang.String template)
type - one of the TEMPLATE_TYPE_* constantstemplate -
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||