1 package ch.odi.justblog.api;
2
3 import javax.security.auth.callback.CallbackHandler;
4
5
6 /***
7 *
8 *
9 * @author oglueck
10 */
11 public interface Blog {
12
13 /***
14 * Authenticates a user to this blog. After a successful call,
15 * the user can perform privileged actions on the blog.
16 *
17 * @param authHandler Provides the implementation with a callback handler to
18 * be used JAAS like to retrieve authentication data from
19 * the user.The handler will be set by Justblog before any
20 * other method is called.
21
22 */
23 void authenticate(CallbackHandler authHandler) throws AuthenticationFailedException;
24
25 /***
26 * Posts a entry to this blog.
27 *
28 * @param entry either a new or an existing entry
29 * @throws ApiException
30 */
31 void post(Entry entry) throws ApiException;
32 }