blackboard.admin.persist.course
Interface StaffAssignmentPersister

All Superinterfaces:
Persister, blackboard.admin.snapshot.persist.SnapshotPersister<StaffAssignment>

public interface StaffAssignmentPersister
extends Persister, blackboard.admin.snapshot.persist.SnapshotPersister<StaffAssignment>

This interface describes the set of methods that all persisters for StaffAssignment objects must implement.

A persister allows an object to be stored (either inserted or updated) within the CMS system or to be deleted from the CMS system. Persisting methods are named according to the type of persistence that is performed.

Since:
Bb 6.0
See Also:
StaffAssignmentLoader, StaffAssignment

Nested Class Summary
static class StaffAssignmentPersister.Default
          A utility class that provides quick access to the Persister instance associated with the default instance of the database BbPersistenceManager.
 
Field Summary
static java.lang.String TYPE
          Type used to obtain an instance of the class configured to provide the implementation for this interface.
 
Method Summary
 void insert(StaffAssignment objToSave)
          Inserts the supplied StaffAssignment.
 void remove(StaffAssignment obj)
          Removes the supplied StaffAssignment.
 void save(StaffAssignment objToSave)
          Inserts or updates the supplied StaffAssignment.
 void save(StaffAssignment objToSave, java.lang.String strSessionId)
          Inserts or updates the supplied StaffAssignment.
 void update(StaffAssignment objToSave)
          Updates the supplied StaffAssignment.
 
Methods inherited from interface blackboard.persist.Persister
getAppVersion, init
 
Methods inherited from interface blackboard.admin.snapshot.persist.SnapshotPersister
closeSession, createSession, createSession, remove, save, save
 

Field Detail

TYPE

static final java.lang.String TYPE
Type used to obtain an instance of the class configured to provide the implementation for this interface.

See Also:
Constant Field Values
Method Detail

save

void save(StaffAssignment objToSave)
          throws PersistenceException,
                 blackboard.db.ConstraintViolationException,
                 ValidationException
Inserts or updates the supplied StaffAssignment.

Parameters:
objToSave - StaffAssignment object to be persisted.
Throws:
PersistenceException - Thrown if a failure occurs while saving object.
blackboard.db.ConstraintViolationException - Thrown if a StaffAssignment object exists with provided course name.
ValidationException - Thrown if target does not contain required indentifying information.

save

void save(StaffAssignment objToSave,
          java.lang.String strSessionId)
          throws PersistenceException,
                 ValidationException
Inserts or updates the supplied StaffAssignment.
Method used for persistence within the scope of a Snapshot Session. And should be bracketed by method calls SnapshotPersister.createSession(String) for initialization of the Snapshot process and SnapshotPersister.closeSession(String) for finalization. Failure to do this appropriately will result in a PersistenceException

Parameters:
objToSave - StaffAssignment object to be persisted.
strSessionId - Unique id associated with the Session targeted for the operation.
Throws:
PersistenceException - Thrown if a failure occurs while saving object.
ValidationException - Thrown if target does not contain required indentifying information.

insert

void insert(StaffAssignment objToSave)
            throws PersistenceException,
                   blackboard.db.ConstraintViolationException,
                   ValidationException
Inserts the supplied StaffAssignment.

Parameters:
objToSave - StaffAssignment object to be inserted.
Throws:
PersistenceException - Thrown if a failure occurs while inserting object.
blackboard.db.ConstraintViolationException - Thrown if a StaffAssignment object exists with provided batch uid, or course name.
ValidationException - Thrown if target StaffAssignment does not contain required indentifying information.

update

void update(StaffAssignment objToSave)
            throws PersistenceException,
                   blackboard.db.ConstraintViolationException,
                   KeyNotFoundException,
                   ValidationException
Updates the supplied StaffAssignment.

Parameters:
objToSave - StaffAssignment object to be updated.
Throws:
KeyNotFoundException - Thrown if StaffAssignment object could not be found with provided batch uid.
PersistenceException - Thrown if a failure occurs while updating object.
blackboard.db.ConstraintViolationException - Thrown if a StaffAssignment object exists with provided course name.
ValidationException - Thrown if target StaffAssignment does not contain required indentifying information.

remove

void remove(StaffAssignment obj)
            throws ValidationException,
                   KeyNotFoundException,
                   PersistenceException
Removes the supplied StaffAssignment.

Parameters:
obj - StaffAssignment object to be removed.
Throws:
KeyNotFoundException - Thrown if StaffAssignment object could not be found with provided batch uid.
ValidationException - Not thrown - validation not required for removal operation.
PersistenceException - Thrown if a failure occurs while removing object.


Copyright © 2012 Blackboard, Inc. All Rights Reserved.