use of com.xpn.xwiki.internal.store.hibernate.HibernateDeletedAttachmentContent in project xwiki-platform by xwiki.
the class HibernateAttachmentRecycleBinStore method createDeletedAttachment.
private DeletedAttachment createDeletedAttachment(XWikiAttachment attachment, String deleter, Date date, AttachmentRecycleBinContentStore contentStore) throws XWikiException {
DeletedAttachment trashdoc;
String storeType = null;
DeletedAttachmentContent deletedDocumentContent = null;
if (contentStore != null) {
storeType = contentStore.getHint();
} else {
deletedDocumentContent = new HibernateDeletedAttachmentContent(attachment);
}
trashdoc = new DeletedAttachment(attachment.getDocId(), attachment.getDoc().getFullName(), attachment.getFilename(), storeType, deleter, date, deletedDocumentContent);
return trashdoc;
}
Aggregations