|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectibrokerkit.ibrokerstore.store.impl.db.DatabaseStore
public class DatabaseStore
Hibernate-based implementation of the Store interface.
| Constructor Summary | |
|---|---|
DatabaseStore(java.util.Properties properties)
|
|
| Method Summary | |
|---|---|
User |
checkUserPassword(java.lang.String identifier,
java.lang.String pass)
Check if the user's hashed password is correct. |
void |
close()
Closes the Store. |
User |
createOrUpdateUser(java.lang.String identifier,
java.lang.String pass,
java.lang.String recovery,
java.lang.String name,
java.lang.String email,
java.lang.Boolean openid)
|
Private |
createPrivate()
|
PrivateAuthorization |
createPrivateAuthorization()
|
PrivateSelector |
createPrivateSelector()
|
void |
deleteObject(java.lang.Object object)
Deletes an object from the database. |
boolean |
existsUser(java.lang.String identifier,
java.lang.String name)
Check if a user with a given identifier or name exists already. |
Private |
findPrivate(java.lang.String qxri)
|
Private |
findPrivateBySelector(java.lang.String selector)
|
Private[] |
findPrivates(java.lang.String qxri)
|
User |
findUser(java.lang.String identifier)
Find a user by a given identifier. |
User |
findUserByRecovery(java.lang.String recovery)
Find all users with a given recovery code. |
User[] |
findUsersByEmail(java.lang.String email)
Find all users with a given email address. |
Private |
getPrivate(java.lang.Long id)
|
org.hibernate.SessionFactory |
getSessionFactory()
Checks if the database connection is still alive; if not, try to reconnect, then throw exception. |
void |
init()
Initializes the Store. |
boolean |
isClosed()
True, if the Store has been initialized. |
boolean |
isInitialized()
True, if the Store has been initialized. |
Private[] |
listPrivates()
|
Private[] |
listPrivatesByIndex(java.lang.String indx)
|
User[] |
listUsers()
List all users in the Store. |
void |
setSessionFactory(org.hibernate.SessionFactory sessionFactory)
Allow the connection to be changed externally. |
void |
updateObject(java.lang.Object object)
Updates an object in the database after modifications have been made. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DatabaseStore(java.util.Properties properties)
| Method Detail |
|---|
public void init()
throws StoreException
Store
init in interface StoreStoreExceptionpublic boolean isInitialized()
Store
isInitialized in interface Storepublic void close()
Store
close in interface Storepublic boolean isClosed()
Store
isClosed in interface Store
public org.hibernate.SessionFactory getSessionFactory()
throws StoreException
StoreExceptionpublic void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
sessionFactory -
public void updateObject(java.lang.Object object)
throws StoreException
Store
updateObject in interface StoreStoreException
public void deleteObject(java.lang.Object object)
throws StoreException
Store
deleteObject in interface StoreStoreException
public User createOrUpdateUser(java.lang.String identifier,
java.lang.String pass,
java.lang.String recovery,
java.lang.String name,
java.lang.String email,
java.lang.Boolean openid)
throws StoreException
createOrUpdateUser in interface StoreStoreException
public User[] listUsers()
throws StoreException
Store
listUsers in interface StoreStoreException
public User findUser(java.lang.String identifier)
throws StoreException
Store
findUser in interface StoreStoreException
public User[] findUsersByEmail(java.lang.String email)
throws StoreException
Store
findUsersByEmail in interface StoreStoreException
public User findUserByRecovery(java.lang.String recovery)
throws StoreException
Store
findUserByRecovery in interface StoreStoreException
public boolean existsUser(java.lang.String identifier,
java.lang.String name)
throws StoreException
Store
existsUser in interface StoreStoreException
public User checkUserPassword(java.lang.String identifier,
java.lang.String pass)
throws StoreException
Store
checkUserPassword in interface StoreStoreException
public Private createPrivate()
throws StoreException
createPrivate in interface StoreStoreException
public Private getPrivate(java.lang.Long id)
throws StoreException
getPrivate in interface StoreStoreException
public Private[] listPrivates()
throws StoreException
listPrivates in interface StoreStoreException
public Private[] listPrivatesByIndex(java.lang.String indx)
throws StoreException
listPrivatesByIndex in interface StoreStoreException
public Private findPrivate(java.lang.String qxri)
throws StoreException
findPrivate in interface StoreStoreException
public Private[] findPrivates(java.lang.String qxri)
throws StoreException
findPrivates in interface StoreStoreException
public Private findPrivateBySelector(java.lang.String selector)
throws StoreException
findPrivateBySelector in interface StoreStoreException
public PrivateSelector createPrivateSelector()
throws StoreException
createPrivateSelector in interface StoreStoreException
public PrivateAuthorization createPrivateAuthorization()
throws StoreException
createPrivateAuthorization in interface StoreStoreException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||