public abstract class UnlockUserSecurityCodeDaoBase extends org.springframework.orm.hibernate3.support.HibernateDaoSupport implements UnlockUserSecurityCodeDao
Base Spring DAO Class: is able to create, update, remove, load, and find objects of type
com.communote.server.persistence.user.security.UnlockUserSecurityCode
.
UnlockUserSecurityCode
TRANSFORM_NONE
Constructor and Description |
---|
UnlockUserSecurityCodeDaoBase() |
Modifier and Type | Method and Description |
---|---|
Collection<UnlockUserSecurityCode> |
create(Collection<UnlockUserSecurityCode> entities)
Creates a new instance of
com.communote.server.persistence.user.security.UnlockUserSecurityCode and adds from the
passed in
entities collection |
Collection<UnlockUserSecurityCode> |
create(int transform,
Collection<UnlockUserSecurityCode> entities)
Does the same thing as
UnlockUserSecurityCodeDao.create(com.communote.server.model.user.security.UnlockUserSecurityCode) with an
additional flag called transform . |
Object |
create(int transform,
UnlockUserSecurityCode unlockUserSecurityCode)
Does the same thing as
UnlockUserSecurityCodeDao.create(com.communote.server.model.user.security.UnlockUserSecurityCode) with an
additional flag called transform . |
UnlockUserSecurityCode |
create(UnlockUserSecurityCode unlockUserSecurityCode)
Creates an instance of com.communote.server.persistence.user.security.UnlockUserSecurityCode
and adds it to the persistent store.
|
UnlockUserSecurityCode |
createCode(User user,
ChannelType channel)
Creates an user security code
|
void |
evict(UnlockUserSecurityCode entity)
Evicts (removes) the entity from the hibernate cache
|
UnlockUserSecurityCode |
findBySecurityCode(String code)
Finds the SecurityCode by the code.
|
UnlockUserSecurityCode |
findByUserAndChannel(Long userId,
ChannelType channel)
Find an existing unlock security for a given user and channel type.
|
protected abstract UnlockUserSecurityCode |
handleCreateCode(User user,
ChannelType channel)
Performs the core logic for
createCode(com.communote.server.model.user.User, com.communote.server.model.security.ChannelType) |
protected abstract UnlockUserSecurityCode |
handleFindBySecurityCode(String code)
Performs the core logic for
findBySecurityCode(String) |
protected abstract UnlockUserSecurityCode |
handleFindByUserAndChannel(Long userId,
ChannelType channel)
Performs the core logic for
findByUserAndChannel(Long, com.communote.server.model.security.ChannelType) |
Object |
load(int transform,
Long id)
Does the same thing as
UnlockUserSecurityCodeDao.load(Long) with an additional flag called
transform . |
UnlockUserSecurityCode |
load(Long id)
Loads an instance of com.communote.server.persistence.user.security.UnlockUserSecurityCode
from the persistent store.
|
Collection<UnlockUserSecurityCode> |
loadAll()
Loads all entities of type
UnlockUserSecurityCode . |
Collection<?> |
loadAll(int transform)
Does the same thing as
UnlockUserSecurityCodeDao.loadAll() with an additional flag called
transform . |
void |
remove(Collection<UnlockUserSecurityCode> entities)
Removes all entities in the given
entities |
void |
remove(Long id)
Removes the instance of com.communote.server.persistence.user.security.UnlockUserSecurityCode
having the given
identifier from the persistent store. |
void |
remove(UnlockUserSecurityCode unlockUserSecurityCode)
Removes the instance of com.communote.server.persistence.user.security.UnlockUserSecurityCode
from the persistent store.
|
protected void |
transformEntities(int transform,
Collection<?> entities)
Transforms a collection of entities using the
transformEntity(int,com.communote.server.model.user.security.UnlockUserSecurityCode)
method. |
protected Object |
transformEntity(int transform,
UnlockUserSecurityCode entity)
Allows transformation of entities into value objects (or something else for that matter),
when the
transform flag is set to one of the constants defined in
com.communote.server.persistence.user.security.UnlockUserSecurityCodeDao , please
note that the UnlockUserSecurityCodeDao.TRANSFORM_NONE constant denotes no transformation, so the entity
itself will be returned. |
void |
update(Collection<UnlockUserSecurityCode> entities)
Updates all instances in the
entities collection in the persistent store. |
void |
update(UnlockUserSecurityCode unlockUserSecurityCode)
Updates the
unlockUserSecurityCode instance in the persistent store. |
public UnlockUserSecurityCode create(UnlockUserSecurityCode unlockUserSecurityCode)
UnlockUserSecurityCodeDao
create
in interface UnlockUserSecurityCodeDao
UnlockUserSecurityCodeDao.create(com.communote.server.model.user.security.UnlockUserSecurityCode)
public Object create(int transform, UnlockUserSecurityCode unlockUserSecurityCode)
UnlockUserSecurityCodeDao
Does the same thing as
UnlockUserSecurityCodeDao.create(com.communote.server.model.user.security.UnlockUserSecurityCode)
with an
additional flag called transform
. If this flag is set to
TRANSFORM_NONE
then the returned entity will NOT be
transformed. If this flag is any of the other constants defined here then the result
WILL BE passed through an operation which can optionally transform the
entity (into a value object for example). By default, transformation does not occur.
create
in interface UnlockUserSecurityCodeDao
com.communote.server.persistence.user.security.UnlockUserSecurityCodeDao#create(int
transform, com.communote.server.persistence.user.security.UnlockUserSecurityCode)
public Collection<UnlockUserSecurityCode> create(int transform, Collection<UnlockUserSecurityCode> entities)
UnlockUserSecurityCodeDao
Does the same thing as
UnlockUserSecurityCodeDao.create(com.communote.server.model.user.security.UnlockUserSecurityCode)
with an
additional flag called transform
. If this flag is set to
TRANSFORM_NONE
then the returned entity will NOT be
transformed. If this flag is any of the other constants defined here then the result
WILL BE passed through an operation which can optionally transform the
entities (into value objects for example). By default, transformation does not occur.
create
in interface UnlockUserSecurityCodeDao
com.communote.server.persistence.user.security.UnlockUserSecurityCodeDao#create(int,
java
.util.Collection)
public Collection<UnlockUserSecurityCode> create(Collection<UnlockUserSecurityCode> entities)
UnlockUserSecurityCodeDao
entities
collectioncreate
in interface UnlockUserSecurityCodeDao
entities
- the collection of
com.communote.server.persistence.user.security.UnlockUserSecurityCode instances to
create.com.communote.server.persistence.user.security.UnlockUserSecurityCodeDao#create(java.util
.Collection)
public UnlockUserSecurityCode createCode(User user, ChannelType channel)
UnlockUserSecurityCodeDao
Creates an user security code
public void evict(UnlockUserSecurityCode entity)
evict
in interface UnlockUserSecurityCodeDao
entity
- the entity to evictpublic UnlockUserSecurityCode findBySecurityCode(String code)
UnlockUserSecurityCodeDao
Finds the SecurityCode by the code.
findBySecurityCode
in interface UnlockUserSecurityCodeDao
UnlockUserSecurityCodeDao.findBySecurityCode(String)
public UnlockUserSecurityCode findByUserAndChannel(Long userId, ChannelType channel)
UnlockUserSecurityCodeDao
Find an existing unlock security for a given user and channel type.
findByUserAndChannel
in interface UnlockUserSecurityCodeDao
UnlockUserSecurityCodeDao.findByUserAndChannel(Long,
com.communote.server.model.security.ChannelType)
protected abstract UnlockUserSecurityCode handleCreateCode(User user, ChannelType channel)
createCode(com.communote.server.model.user.User, com.communote.server.model.security.ChannelType)
protected abstract UnlockUserSecurityCode handleFindBySecurityCode(String code)
findBySecurityCode(String)
protected abstract UnlockUserSecurityCode handleFindByUserAndChannel(Long userId, ChannelType channel)
findByUserAndChannel(Long, com.communote.server.model.security.ChannelType)
public Object load(int transform, Long id)
UnlockUserSecurityCodeDao
Does the same thing as UnlockUserSecurityCodeDao.load(Long)
with an additional flag called
transform
. If this flag is set to TRANSFORM_NONE
then the returned
entity will NOT be transformed. If this flag is any of the other constants
defined in this class then the result WILL BE passed through an operation
which can optionally transform the entity (into a value object for example). By default,
transformation does not occur.
load
in interface UnlockUserSecurityCodeDao
id
- the identifier of the entity to load.UnlockUserSecurityCodeDao.load(int, Long)
public UnlockUserSecurityCode load(Long id)
UnlockUserSecurityCodeDao
load
in interface UnlockUserSecurityCodeDao
UnlockUserSecurityCodeDao.load(Long)
public Collection<UnlockUserSecurityCode> loadAll()
UnlockUserSecurityCodeDao
UnlockUserSecurityCode
.loadAll
in interface UnlockUserSecurityCodeDao
UnlockUserSecurityCodeDao.loadAll()
public Collection<?> loadAll(int transform)
UnlockUserSecurityCodeDao
Does the same thing as UnlockUserSecurityCodeDao.loadAll()
with an additional flag called
transform
. If this flag is set to TRANSFORM_NONE
then the returned
entity will NOT be transformed. If this flag is any of the other constants
defined here then the result WILL BE passed through an operation which can
optionally transform the entity (into a value object for example). By default, transformation
does not occur.
loadAll
in interface UnlockUserSecurityCodeDao
transform
- the flag indicating what transformation to use.UnlockUserSecurityCodeDao.loadAll(int)
public void remove(UnlockUserSecurityCode unlockUserSecurityCode)
UnlockUserSecurityCodeDao
remove
in interface UnlockUserSecurityCodeDao
UnlockUserSecurityCodeDao.remove(com.communote.server.model.user.security.UnlockUserSecurityCode)
public void remove(Collection<UnlockUserSecurityCode> entities)
UnlockUserSecurityCodeDao
entities collection.
remove
in interface UnlockUserSecurityCodeDao
com.communote.server.persistence.user.security.UnlockUserSecurityCodeDao#remove(java.util
.Collection)
public void remove(Long id)
UnlockUserSecurityCodeDao
identifier
from the persistent store.remove
in interface UnlockUserSecurityCodeDao
UnlockUserSecurityCodeDao.remove(Long)
protected void transformEntities(int transform, Collection<?> entities)
transformEntity(int,com.communote.server.model.user.security.UnlockUserSecurityCode)
method. This method does not instantiate a new collection.
This method is to be used internally only.transform
- one of the constants declared in
com.communote.server.persistence.user.security.UnlockUserSecurityCodeDao
entities
- the collection of entities to transformtransformEntity(int,com.communote.server.model.user.security.UnlockUserSecurityCode)
protected Object transformEntity(int transform, UnlockUserSecurityCode entity)
transform
flag is set to one of the constants defined in
com.communote.server.persistence.user.security.UnlockUserSecurityCodeDao
, please
note that the UnlockUserSecurityCodeDao.TRANSFORM_NONE
constant denotes no transformation, so the entity
itself will be returned.
If the integer argument value is unknown UnlockUserSecurityCodeDao.TRANSFORM_NONE
is assumed.transform
- one of the constants declared in
UnlockUserSecurityCodeDao
entity
- an entity that was foundtransformEntities(int,java.util.Collection)
public void update(UnlockUserSecurityCode unlockUserSecurityCode)
UnlockUserSecurityCodeDao
unlockUserSecurityCode
instance in the persistent store.update
in interface UnlockUserSecurityCodeDao
UnlockUserSecurityCodeDao.update(com.communote.server.model.user.security.UnlockUserSecurityCode)
public void update(Collection<UnlockUserSecurityCode> entities)
UnlockUserSecurityCodeDao
entities
collection in the persistent store.update
in interface UnlockUserSecurityCodeDao
com.communote.server.persistence.user.security.UnlockUserSecurityCodeDao#update(java.util
.Collection)
Copyright © 2019 Communote team. All rights reserved.