public class JdbcDaoImpl extends org.springframework.jdbc.core.support.JdbcDaoSupport implements BasicAclDao
A default database structure is assumed. This may be overridden by setting the default query strings to use.
If this does not provide enough flexibility, another strategy would be to subclass this class and override the
MappingSqlQuery instance used, via the initMappingSqlQueries() extension point.
| Modifier and Type | Class and Description |
|---|---|
protected class |
JdbcDaoImpl.AclDetailsHolder
Deprecated.
Used to hold details of a domain object instance's properties, or an individual ACL entry.
|
protected class |
JdbcDaoImpl.AclsByObjectIdentityMapping
Deprecated.
Query object to look up individual ACL entries.
|
protected class |
JdbcDaoImpl.ObjectPropertiesMapping
Deprecated.
Query object to look up properties for an object identity.
|
| Modifier and Type | Field and Description |
|---|---|
protected org.springframework.jdbc.object.MappingSqlQuery |
aclsByObjectIdentity
Deprecated.
|
static java.lang.String |
DEF_ACLS_BY_OBJECT_IDENTITY_QUERY
Deprecated.
|
static java.lang.String |
DEF_OBJECT_PROPERTIES_QUERY
Deprecated.
|
protected org.springframework.jdbc.object.MappingSqlQuery |
objectProperties
Deprecated.
|
static java.lang.String |
RECIPIENT_USED_FOR_INHERITENCE_MARKER
Deprecated.
|
| Constructor and Description |
|---|
JdbcDaoImpl()
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
protected java.lang.String |
convertAclObjectIdentityToString(AclObjectIdentity aclObjectIdentity)
Deprecated.
Responsible for covering a
AclObjectIdentity to a String that can be located
in the RDBMS. |
BasicAclEntry[] |
getAcls(AclObjectIdentity aclObjectIdentity)
Deprecated.
Returns the ACLs associated with the requested
AclObjectIdentity. |
org.springframework.jdbc.object.MappingSqlQuery |
getAclsByObjectIdentity()
Deprecated.
|
java.lang.String |
getAclsByObjectIdentityQuery()
Deprecated.
|
java.lang.String |
getObjectPropertiesQuery()
Deprecated.
|
protected void |
initDao()
Deprecated.
|
protected void |
initMappingSqlQueries()
Deprecated.
Extension point to allow other MappingSqlQuery objects to be substituted in a subclass
|
void |
setAclsByObjectIdentity(org.springframework.jdbc.object.MappingSqlQuery aclsByObjectIdentityQuery)
Deprecated.
|
void |
setAclsByObjectIdentityQuery(java.lang.String queryString)
Deprecated.
Allows the default query string used to retrieve ACLs based on object identity to be overriden, if
default table or column names need to be changed.
|
void |
setObjectProperties(org.springframework.jdbc.object.MappingSqlQuery objectPropertiesQuery)
Deprecated.
|
void |
setObjectPropertiesQuery(java.lang.String queryString)
Deprecated.
|
public static final java.lang.String RECIPIENT_USED_FOR_INHERITENCE_MARKER
public static final java.lang.String DEF_ACLS_BY_OBJECT_IDENTITY_QUERY
public static final java.lang.String DEF_OBJECT_PROPERTIES_QUERY
protected org.springframework.jdbc.object.MappingSqlQuery aclsByObjectIdentity
protected org.springframework.jdbc.object.MappingSqlQuery objectProperties
protected java.lang.String convertAclObjectIdentityToString(AclObjectIdentity aclObjectIdentity)
AclObjectIdentity to a String that can be located
in the RDBMS.aclObjectIdentity - to locateStringpublic BasicAclEntry[] getAcls(AclObjectIdentity aclObjectIdentity)
AclObjectIdentity.The BasicAclEntrys returned by this method will have String-based recipients. This will not be a
problem if you are using the GrantedAuthorityEffectiveAclsResolver, which is the default
configured against BasicAclProvider.
This method will only return ACLs for requests where the AclObjectIdentity is of type
NamedEntityObjectIdentity. Of course, you can subclass or replace this class and support your own
custom AclObjectIdentity types.
getAcls in interface BasicAclDaoaclObjectIdentity - for which ACL information is required (cannot be null and must be an
instance of NamedEntityObjectIdentity)nulls inside the array), or null if not found
or if an incompatible AclObjectIdentity was requestedpublic org.springframework.jdbc.object.MappingSqlQuery getAclsByObjectIdentity()
public java.lang.String getAclsByObjectIdentityQuery()
public java.lang.String getObjectPropertiesQuery()
protected void initDao()
throws org.springframework.context.ApplicationContextException
initDao in class org.springframework.dao.support.DaoSupportorg.springframework.context.ApplicationContextExceptionprotected void initMappingSqlQueries()
public void setAclsByObjectIdentity(org.springframework.jdbc.object.MappingSqlQuery aclsByObjectIdentityQuery)
public void setAclsByObjectIdentityQuery(java.lang.String queryString)
DEF_ACLS_BY_OBJECT_IDENTITY_QUERY; when modifying this query, ensure that all returned columns are mapped
back to the same column names as in the default query.queryString - The query string to setpublic void setObjectProperties(org.springframework.jdbc.object.MappingSqlQuery objectPropertiesQuery)
public void setObjectPropertiesQuery(java.lang.String queryString)