public class DbProfileService extends AbstractProfileService<DbProfile>
Modifier and Type | Field and Description |
---|---|
protected org.skife.jdbi.v2.DBI |
dbi |
attributeNames, ID, LINKEDID, logger, SERIALIZED_PROFILE
Constructor and Description |
---|
DbProfileService() |
DbProfileService(DataSource dataSource) |
DbProfileService(DataSource dataSource,
PasswordEncoder passwordEncoder) |
DbProfileService(DataSource dataSource,
String attributes) |
DbProfileService(DataSource dataSource,
String attributes,
PasswordEncoder passwordEncoder) |
Modifier and Type | Method and Description |
---|---|
protected String |
buildAttributesList(List<String> names) |
protected void |
deleteById(String id)
Delete a profile by its identifier in the storage.
|
protected void |
execute(String query,
Object... args) |
DataSource |
getDataSource() |
org.skife.jdbi.v2.DBI |
getDbi() |
String |
getUsersTable() |
protected void |
insert(Map<String,Object> attributes)
Insert the attributes in the storage.
|
protected void |
internalInit(WebContext context)
Internal initialization of the object.
|
protected List<Map<String,Object>> |
query(String query,
String key,
String value) |
protected List<Map<String,Object>> |
read(List<String> names,
String key,
String value)
Read the list of defined attributes in the storage for key=value query.
|
void |
setDataSource(DataSource dataSource) |
void |
setUsersTable(String usersTable) |
String |
toString() |
protected void |
update(Map<String,Object> attributes)
Update the attributes in the storage.
|
convertAttributesToProfile, convertProfileAndPasswordToAttributes, create, defineAttributesToRead, findById, findByLinkedId, getAttributes, getIdAttribute, getJavaSerializationHelper, getPasswordAttribute, getPasswordEncoder, getUsernameAttribute, isLegacyMode, remove, removeById, setAttributes, setIdAttribute, setJavaSerializationHelper, setPasswordAttribute, setPasswordEncoder, setUsernameAttribute, update, validate
defaultProfileDefinition, getProfileDefinition, setProfileDefinition
init, reinit
public DbProfileService()
public DbProfileService(DataSource dataSource)
public DbProfileService(DataSource dataSource, String attributes)
public DbProfileService(DataSource dataSource, String attributes, PasswordEncoder passwordEncoder)
public DbProfileService(DataSource dataSource, PasswordEncoder passwordEncoder)
protected void internalInit(WebContext context)
InitializableWebObject
internalInit
in class AbstractProfileService<DbProfile>
context
- the web contextprotected void insert(Map<String,Object> attributes)
AbstractProfileService
insert
in class AbstractProfileService<DbProfile>
attributes
- the attributesprotected void update(Map<String,Object> attributes)
AbstractProfileService
update
in class AbstractProfileService<DbProfile>
attributes
- the attributesprotected void deleteById(String id)
AbstractProfileService
deleteById
in class AbstractProfileService<DbProfile>
id
- the identifierprotected List<Map<String,Object>> read(List<String> names, String key, String value)
AbstractProfileService
read
in class AbstractProfileService<DbProfile>
names
- the attribute names to readkey
- the key for the queryvalue
- the value for the querypublic DataSource getDataSource()
public void setDataSource(DataSource dataSource)
public String getUsersTable()
public void setUsersTable(String usersTable)
public org.skife.jdbi.v2.DBI getDbi()
Copyright © 2017. All rights reserved.