org.apache.aries.samples.blog.api
Interface BlogAuthorManager


public interface BlogAuthorManager


Method Summary
 void createAuthor(String email, String dob, String name, String displayName, String bio)
          Create an author.
 List<? extends BlogAuthor> getAllAuthors()
          Get all authors from the database.
 BlogAuthor getAuthor(String emailAddress)
          Get an individual author.
 void removeAuthor(String emailAddress)
          Delete an author from the database.
 void updateAuthor(String email, String dob, String name, String displayName, String bio)
          Update a specific author.
 

Method Detail

createAuthor

void createAuthor(String email,
                  String dob,
                  String name,
                  String displayName,
                  String bio)
                  throws ParseException
Create an author.

Parameters:
email - the author's email address, this is used as the key in the database
dob - the author's date of birth
name - the author's full name
displayName - the author's display name
bio - the author's biography
Throws:
ParseException

getAllAuthors

List<? extends BlogAuthor> getAllAuthors()
Get all authors from the database.

Returns:
a List of all authors in the database

getAuthor

BlogAuthor getAuthor(String emailAddress)
Get an individual author.

Parameters:
emailAddress - - the email address of the author to retrieve
Returns:
the author

removeAuthor

void removeAuthor(String emailAddress)
Delete an author from the database.

Parameters:
emailAddress - the email address of the author to delete

updateAuthor

void updateAuthor(String email,
                  String dob,
                  String name,
                  String displayName,
                  String bio)
                  throws ParseException
Update a specific author.

Parameters:
email - the email address of the author being updated.
dob - the new date of birth (as a string)
name - the new full name
displayName - the new display name
bio - the new biography
Throws:
ParseException


Copyright © 2009-2012 The Apache Software Foundation. All Rights Reserved.