blackboard.cms.bookmark
Class BookmarkManager

java.lang.Object
  extended byblackboard.cms.bookmark.BookmarkManager

public class BookmarkManager
extends java.lang.Object

The BookmarkManager class provides a representation of a BookmarkManager within the Blackboard application. This object provides load, save and delete methods for managing a single or multiple Bookmarks.


Since:
Bb CS 1.0
Version:
$Revision: $

Constructor Summary
BookmarkManager()
           
 
Method Summary
static void deleteById(blackboard.persist.Id id)
          Deletes the Bookmark identified by the Id using default connection.
static void deleteById(blackboard.persist.Id id, java.sql.Connection con)
          Deletes the Bookmark identified by the Id using supplied connection.
static void deleteByUserId(blackboard.persist.Id id)
          Deletes the Bookmark identified by the given user Id using default connection.
static void deleteByUserId(blackboard.persist.Id id, java.sql.Connection con)
          Deletes the Bookmark identified by the given user Id using supplied connection.
static Bookmark loadById(blackboard.persist.Id id)
          Loads a Bookmark identified by the given Id using the default connection.
static Bookmark loadById(blackboard.persist.Id id, java.sql.Connection con)
          Loads a Bookmark identified by the given Id using the supplied connection.
static java.util.List loadByParentId(blackboard.persist.Id id)
          Loads and returns a List of Bookmark items identified by the given parent Id using the supplied connection.
static java.util.List loadByParentId(blackboard.persist.Id id, java.sql.Connection con)
          Loads and returns a List of Bookmark items identified by the given parent Id using the supplied connection.
static java.util.List loadTopLevelByUserId(blackboard.persist.Id id)
          Loads and returns a List of Bookmark items identified the by the user Id using the default connection.
static java.util.List loadTopLevelByUserId(blackboard.persist.Id id, java.sql.Connection con)
          Loads and returns a List of Bookmark items identified the by the user Id using the supplied connection.
static void save(Bookmark bookmark)
          Inserts or updates the Bookmark using the default connection.
static void save(Bookmark bookmark, java.sql.Connection con)
          Inserts or updates the Bookmark using the supplied connection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BookmarkManager

public BookmarkManager()
Method Detail

save

public static void save(Bookmark bookmark,
                        java.sql.Connection con)
                 throws blackboard.persist.PersistenceException
Inserts or updates the Bookmark using the supplied connection.

Parameters:
bookmark - a Bookmark to be saved.
con - a Connection to be used to save this Bookmark.
Throws:
blackboard.persist.PersistenceException

save

public static void save(Bookmark bookmark)
                 throws blackboard.persist.PersistenceException
Inserts or updates the Bookmark using the default connection.

Parameters:
bookmark - the Bookmark to be saved.
Throws:
blackboard.persist.PersistenceException

deleteById

public static void deleteById(blackboard.persist.Id id)
                       throws blackboard.persist.PersistenceException
Deletes the Bookmark identified by the Id using default connection.

Parameters:
id - the Id of the Bookmark to be deleted using default connection.
Throws:
blackboard.persist.PersistenceException

deleteById

public static void deleteById(blackboard.persist.Id id,
                              java.sql.Connection con)
                       throws blackboard.persist.PersistenceException
Deletes the Bookmark identified by the Id using supplied connection.

Parameters:
id - the Id of the Bookmark to be deleted using supplied connection.
con - a Connection to be used.
Throws:
blackboard.persist.PersistenceException

deleteByUserId

public static void deleteByUserId(blackboard.persist.Id id)
                           throws blackboard.persist.PersistenceException
Deletes the Bookmark identified by the given user Id using default connection.

Parameters:
id - the Id of the Bookmark to be deleted using default connection.
Throws:
blackboard.persist.PersistenceException

deleteByUserId

public static void deleteByUserId(blackboard.persist.Id id,
                                  java.sql.Connection con)
                           throws blackboard.persist.PersistenceException
Deletes the Bookmark identified by the given user Id using supplied connection.

Parameters:
id - the Id of the Bookmark to be deleted using supplied connection.
con - a Connection to be used.
Throws:
blackboard.persist.PersistenceException

loadById

public static Bookmark loadById(blackboard.persist.Id id,
                                java.sql.Connection con)
                         throws blackboard.persist.PersistenceException
Loads a Bookmark identified by the given Id using the supplied connection.

Parameters:
id - the Id of the Bookmark to be loaded using the supplied connection.
con - a Connection to be used.
Returns:
a Bookmark that is identified by the given Id. Returns null (instead of KeyNotFoundException) if the Bookmark is not found.
Throws:
blackboard.persist.PersistenceException

loadById

public static Bookmark loadById(blackboard.persist.Id id)
                         throws blackboard.persist.PersistenceException
Loads a Bookmark identified by the given Id using the default connection.

Parameters:
id - the Id of the Bookmark to be loaded using the default connection.
Returns:
a Bookmark that is identified by the given Id. Returns null (instead of KeyNotFoundException) if the Bookmark is not found.
Throws:
blackboard.persist.PersistenceException

loadByParentId

public static java.util.List loadByParentId(blackboard.persist.Id id,
                                            java.sql.Connection con)
                                     throws blackboard.persist.PersistenceException
Loads and returns a List of Bookmark items identified by the given parent Id using the supplied connection.

Parameters:
id - the parent Id of the Bookmark items to be loaded using the supplied connection.
con - a Connection to be used.
Returns:
a List of Bookmark items that are identified by the given parent Id.
Throws:
blackboard.persist.PersistenceException

loadByParentId

public static java.util.List loadByParentId(blackboard.persist.Id id)
                                     throws blackboard.persist.PersistenceException
Loads and returns a List of Bookmark items identified by the given parent Id using the supplied connection.

Parameters:
id - the parent Id of theBookmark items to be loaded using the default connection.
Returns:
a List of Bookmark items that are identified by the given parent Id.
Throws:
blackboard.persist.PersistenceException

loadTopLevelByUserId

public static java.util.List loadTopLevelByUserId(blackboard.persist.Id id,
                                                  java.sql.Connection con)
                                           throws blackboard.persist.PersistenceException
Loads and returns a List of Bookmark items identified the by the user Id using the supplied connection. The top-level consists of Bookmark items that do not have a parent Id.

Parameters:
id - the user Id of the Bookmark items to be loaded using the supplied connection.
con - a Connection to be used.
Returns:
a List of Bookmark items that are identified by the given user Id at the top-level.
Throws:
blackboard.persist.PersistenceException

loadTopLevelByUserId

public static java.util.List loadTopLevelByUserId(blackboard.persist.Id id)
                                           throws blackboard.persist.PersistenceException
Loads and returns a List of Bookmark items identified the by the user Id using the default connection. The top-level consists of Bookmark items that do not have a parent Id.

Parameters:
id - the user Id of the Bookmarkitems to be loaded using the default connection.
Returns:
a List of Bookmark items that are identified by the given user Id at the top-level.
Throws:
blackboard.persist.PersistenceException


Copyright © 2003-2004 Blackboard, Inc. All Rights Reserved.