edu.wisc.my.portlets.bookmarks.dao.hibernate
Class HibernatePreferencesStore

java.lang.Object
  extended by org.springframework.dao.support.DaoSupport
      extended by org.springframework.orm.hibernate3.support.HibernateDaoSupport
          extended by edu.wisc.my.portlets.bookmarks.dao.hibernate.HibernatePreferencesStore
All Implemented Interfaces:
PreferencesStore, org.springframework.beans.factory.InitializingBean

public class HibernatePreferencesStore
extends org.springframework.orm.hibernate3.support.HibernateDaoSupport
implements PreferencesStore

Persists and retrieves Preferences objects via Hibernate.

Version:
$Revision: 12173 $
Author:
Eric Dalquist eric.dalquist@doit.wisc.edu

Field Summary
 
Fields inherited from class org.springframework.dao.support.DaoSupport
logger
 
Constructor Summary
HibernatePreferencesStore()
           
 
Method Summary
 Preferences createPreferences(java.lang.String owner, java.lang.String name)
          Creates Preferences and stores it in the persistent store.
 Preferences getPreferences(java.lang.String owner, java.lang.String name)
          Gets the Preferences for the specified owner and name.
 void removePreferences(java.lang.String owner, java.lang.String name)
          Removes Preferences from the persistent store.
 void storePreferences(Preferences bookmarkSet)
          Stores new Preferences or updates existing Preferences.
 
Methods inherited from class org.springframework.orm.hibernate3.support.HibernateDaoSupport
checkDaoConfig, convertHibernateAccessException, createHibernateTemplate, getHibernateTemplate, getSession, getSession, getSessionFactory, releaseSession, setHibernateTemplate, setSessionFactory
 
Methods inherited from class org.springframework.dao.support.DaoSupport
afterPropertiesSet, initDao
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HibernatePreferencesStore

public HibernatePreferencesStore()
Method Detail

getPreferences

public Preferences getPreferences(java.lang.String owner,
                                  java.lang.String name)
Description copied from interface: PreferencesStore
Gets the Preferences for the specified owner and name. If no Preferences can be found for the owner and name null is retuned.

Specified by:
getPreferences in interface PreferencesStore
Parameters:
owner - The owner of the Preferences to retreive.
name - The name of the Preferences to retrieve.
Returns:
The Preferences for the name and owner, null if one is not found for the owner and name.
See Also:
PreferencesStore.getPreferences(java.lang.String, java.lang.String)

storePreferences

public void storePreferences(Preferences bookmarkSet)
Description copied from interface: PreferencesStore
Stores new Preferences or updates existing Preferences. Preferences are keyed uniquely using the name and owner fields.

Specified by:
storePreferences in interface PreferencesStore
Parameters:
bookmarkSet - The Preferences to persist.
See Also:
PreferencesStore.storePreferences(edu.wisc.my.portlets.bookmarks.domain.Preferences)

removePreferences

public void removePreferences(java.lang.String owner,
                              java.lang.String name)
Description copied from interface: PreferencesStore
Removes Preferences from the persistent store. If a Preferences matching the owner and name cannot be found this is a noop.

Specified by:
removePreferences in interface PreferencesStore
Parameters:
owner - The owner of the Preferences to remove.
name - The name of the Preferences to remove.
See Also:
PreferencesStore.removePreferences(java.lang.String, java.lang.String)

createPreferences

public Preferences createPreferences(java.lang.String owner,
                                     java.lang.String name)
Description copied from interface: PreferencesStore
Creates Preferences and stores it in the persistent store.

Specified by:
createPreferences in interface PreferencesStore
Parameters:
owner - The owner of the Preferences to create.
name - The name of the Preferences to create.
Returns:
The new Preferences.
See Also:
PreferencesStore.createPreferences(java.lang.String, java.lang.String)


Copyright © 1998-2007 Java Architectures Special Interest Group. All Rights Reserved.