|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.alfresco.repo.domain.contentdata.AbstractContentDataDAOImpl
org.alfresco.repo.domain.contentdata.ibatis.ContentDataDAOImpl
public class ContentDataDAOImpl
iBatis-specific implementation of the ContentData DAO.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.alfresco.repo.domain.contentdata.AbstractContentDataDAOImpl |
---|
AbstractContentDataDAOImpl.ContentUrlDeleteTransactionListener |
Nested classes/interfaces inherited from interface org.alfresco.repo.domain.contentdata.ContentDataDAO |
---|
ContentDataDAO.ContentUrlHandler |
Constructor Summary | |
---|---|
ContentDataDAOImpl()
|
Method Summary | |
---|---|
protected ContentDataEntity |
createContentDataEntity(java.lang.Long contentUrlId,
java.lang.Long mimetypeId,
java.lang.Long encodingId,
java.lang.Long localeId)
Create the row for the alf_content_data |
protected ContentUrlEntity |
createContentUrlEntity(java.lang.String contentUrl,
long size,
boolean isReferenced)
|
org.alfresco.util.Pair |
createContentUrlOrphaned(java.lang.String contentUrl)
Creates an immediately-orphaned content URL, if possible |
protected int |
deleteContentDataEntity(java.lang.Long id)
Delete the entity with the given ID |
void |
deleteContentDataForNode(java.lang.Long nodeId,
java.util.Set qnameIds)
Deletes all alf_content_data rows that are referenced by the given node |
int |
deleteContentUrls(java.util.List ids)
Delete a batch of content URL entities. |
protected ContentDataEntity |
getContentDataEntity(java.lang.Long id)
|
protected ContentUrlEntity |
getContentUrlEntity(java.lang.Long id)
|
protected ContentUrlEntity |
getContentUrlEntity(java.lang.String contentUrl)
|
protected ContentUrlEntity |
getContentUrlEntityUnreferenced(java.lang.String contentUrl)
|
void |
getContentUrlsOrphaned(ContentDataDAO.ContentUrlHandler contentUrlHandler,
long maxOrphanTime)
Enumerate all available content URLs that were orphaned on or before the given time |
void |
getContentUrlsOrphaned(ContentDataDAO.ContentUrlHandler contentUrlHandler,
long maxOrphanTime,
int maxResults)
Enumerate all available content URLs that were orphaned on or before the given time |
void |
setSqlMapClientTemplate(org.springframework.orm.ibatis.SqlMapClientTemplate sqlMapClientTemplate)
|
protected int |
updateContentDataEntity(ContentDataEntity entity)
Update an existing alf_content_data entity |
int |
updateContentUrlOrphanTime(java.lang.Long id,
java.lang.Long orphanTime)
Update a content URL with the given orphan time |
Methods inherited from class org.alfresco.repo.domain.contentdata.AbstractContentDataDAOImpl |
---|
createContentData, deleteContentData, getContentData, registerDereferencedContentUrl, registerNewContentUrl, setContentDataCache, setContentStoreCleaner, setEncodingDAO, setLocaleDAO, setMimetypeDAO, updateContentData |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ContentDataDAOImpl()
Method Detail |
---|
public void setSqlMapClientTemplate(org.springframework.orm.ibatis.SqlMapClientTemplate sqlMapClientTemplate)
public org.alfresco.util.Pair createContentUrlOrphaned(java.lang.String contentUrl)
ContentDataDAO
contentUrl
- the URL to create if it doesn't exist
protected ContentUrlEntity createContentUrlEntity(java.lang.String contentUrl, long size, boolean isReferenced)
createContentUrlEntity
in class AbstractContentDataDAOImpl
contentUrl
- the content URL to create or search forisReferenced
- if true
we won't worry about eagerly deleting the content on transaction rollbackprotected ContentUrlEntity getContentUrlEntity(java.lang.Long id)
getContentUrlEntity
in class AbstractContentDataDAOImpl
id
- the ID of the content url entity
protected ContentUrlEntity getContentUrlEntity(java.lang.String contentUrl)
getContentUrlEntity
in class AbstractContentDataDAOImpl
contentUrl
- the URL of the content url entity
public void getContentUrlsOrphaned(ContentDataDAO.ContentUrlHandler contentUrlHandler, long maxOrphanTime)
ContentDataDAO
contentUrlHandler
- the callback object to process the rowsmaxOrphanTime
- the maximum orphan timepublic void getContentUrlsOrphaned(ContentDataDAO.ContentUrlHandler contentUrlHandler, long maxOrphanTime, int maxResults)
ContentDataDAO
contentUrlHandler
- the callback object to process the rowsmaxOrphanTime
- the maximum orphan timemaxResults
- the maximum number of results (1 or greater)public int updateContentUrlOrphanTime(java.lang.Long id, java.lang.Long orphanTime)
AbstractContentDataDAOImpl
updateContentUrlOrphanTime
in class AbstractContentDataDAOImpl
id
- the unique ID of the entityorphanTime
- the time (ms since epoch) that the entity was orphaned
public int deleteContentUrls(java.util.List ids)
protected ContentUrlEntity getContentUrlEntityUnreferenced(java.lang.String contentUrl)
getContentUrlEntityUnreferenced
in class AbstractContentDataDAOImpl
contentUrl
- the URL of the content url entity
protected ContentDataEntity createContentDataEntity(java.lang.Long contentUrlId, java.lang.Long mimetypeId, java.lang.Long encodingId, java.lang.Long localeId)
AbstractContentDataDAOImpl
createContentDataEntity
in class AbstractContentDataDAOImpl
protected ContentDataEntity getContentDataEntity(java.lang.Long id)
getContentDataEntity
in class AbstractContentDataDAOImpl
id
- the entity ID
protected int updateContentDataEntity(ContentDataEntity entity)
AbstractContentDataDAOImpl
updateContentDataEntity
in class AbstractContentDataDAOImpl
entity
- the existing entity that will be updated
protected int deleteContentDataEntity(java.lang.Long id)
AbstractContentDataDAOImpl
deleteContentDataEntity
in class AbstractContentDataDAOImpl
public void deleteContentDataForNode(java.lang.Long nodeId, java.util.Set qnameIds)
ContentDataDAO
nodeId
- the node IDqnameIds
- the content properties to target
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |