Jive Forums API (5.5.20.2-oracle) Developer Javadocs

com.jivesoftware.forum
Interface Watch

All Known Implementing Classes:
DbWatch

public interface Watch

A watch is a way for a user to track updates to an object. Users create watches on individual objects and can specify whether or not they want to be notified by email (or some other way) each time the object is updated.

Three kinds of watch types are available:


Field Summary
static int BATCH_EMAIL_WATCH
          Batch email watch type.
static int EMAIL_WATCH
          Email watch type.
static int NORMAL_WATCH
          Normal watch type.
 
Method Summary
 long getObjectID()
          Returns the object ID of the object being watched.
 int getObjectType()
          Returns the object type of the object being watched.
 User getUser()
          Returns the user who is associated with this watch.
 int getWatchType()
          Returns the type of the watch.
 boolean isExpirable()
          Returns whether this watch is expirable or not.
 void setExpirable(boolean expirable)
          Sets whether this watch is expirable or not.
 void setWatchType(int watchType)
          Sets the watch type.
 

Field Detail

NORMAL_WATCH

static final int NORMAL_WATCH
Normal watch type.

See Also:
Constant Field Values

EMAIL_WATCH

static final int EMAIL_WATCH
Email watch type.

See Also:
Constant Field Values

BATCH_EMAIL_WATCH

static final int BATCH_EMAIL_WATCH
Batch email watch type.

See Also:
Constant Field Values
Method Detail

getUser

User getUser()
Returns the user who is associated with this watch.

Returns:
the user who is associated with this watch.

getObjectID

long getObjectID()
Returns the object ID of the object being watched.

Returns:
the object ID of the object being watched.

getObjectType

int getObjectType()
Returns the object type of the object being watched.

Returns:
the object type of the object being watched.

getWatchType

int getWatchType()
Returns the type of the watch.

Returns:
the handler of the watch.

setWatchType

void setWatchType(int watchType)
Sets the watch type.

Parameters:
watchType - the type of watch this should be.

isExpirable

boolean isExpirable()
Returns whether this watch is expirable or not.

Returns:
true if the watch is expirable, false otherwise.

setExpirable

void setExpirable(boolean expirable)
                  throws UnauthorizedException
Sets whether this watch is expirable or not.

Parameters:
expirable - true if the watch is expirable, false if not.
Throws:
UnauthorizedException - if not a system admin or the user.

Jive Forums Project Page

Copyright © 1999-2006 Jive Software.