public abstract class DbFilesHandlerImpl extends DbHandlerImpl implements DbFilesHandler
Modifier | Constructor and Description |
---|---|
protected |
DbFilesHandlerImpl() |
protected |
DbFilesHandlerImpl(String schema) |
Modifier and Type | Method and Description |
---|---|
protected DbFile |
createFile() |
abstract boolean |
downloadContent(Connection c,
long fileId,
OutputStream output) |
abstract boolean |
downloadPreview(Connection c,
long fileId,
OutputStream output) |
DbFile |
getFile(Connection c,
long id) |
DbFile |
getFile(Connection c,
String hash) |
long[] |
getFileIds(Connection c) |
abstract long[] |
getFileIds(Connection c,
long objectId,
Boolean published,
String mimeType) |
DbFile[] |
getFiles(Connection c) |
abstract DbFile[] |
getFiles(Connection c,
long[] ids) |
abstract DbFile[] |
getFiles(Connection c,
long objectId,
Boolean published,
String mimeType) |
abstract DbFile[] |
getFiles(Connection c,
String[] hashes) |
void |
loadFileTranslations(Connection c,
DbFile[] files,
DbLanguagesHandler languageHandler) |
abstract void |
loadFileTranslations(Connection c,
DbFile[] files,
Map<Long,String> languages) |
void |
loadFileTranslations(Connection c,
DbFile file,
DbLanguagesHandler languageHandler) |
void |
loadFileTranslations(Connection c,
DbFile file,
Map<Long,String> languages) |
void |
removeFile(Connection c,
long id) |
abstract void |
removeFiles(Connection c,
long[] ids) |
void |
saveFile(Connection c,
DbFile file,
File content) |
void |
saveFile(Connection c,
DbFile file,
File content,
File preview,
DbLanguagesHandler languageHandler) |
abstract void |
saveFile(Connection c,
DbFile file,
File content,
File preview,
Map<Long,String> languageMap) |
abstract void |
setFileContent(Connection c,
long fileId,
File content,
File preview) |
getSchema, getSchemaPath, setSchema
protected DbFilesHandlerImpl()
protected DbFilesHandlerImpl(String schema)
protected DbFile createFile()
public abstract boolean downloadContent(Connection c, long fileId, OutputStream output) throws SQLException, IOException
downloadContent
in interface DbFilesHandler
SQLException
IOException
public abstract boolean downloadPreview(Connection c, long fileId, OutputStream output) throws SQLException, IOException
downloadPreview
in interface DbFilesHandler
SQLException
IOException
public final DbFile getFile(Connection c, long id) throws SQLException
getFile
in interface DbFilesHandler
SQLException
public final DbFile getFile(Connection c, String hash) throws SQLException
getFile
in interface DbFilesHandler
SQLException
public final DbFile[] getFiles(Connection c) throws SQLException
getFiles
in interface DbFilesHandler
SQLException
public abstract DbFile[] getFiles(Connection c, long[] ids) throws SQLException
getFiles
in interface DbFilesHandler
SQLException
public abstract DbFile[] getFiles(Connection c, String[] hashes) throws SQLException
getFiles
in interface DbFilesHandler
SQLException
public abstract DbFile[] getFiles(Connection c, long objectId, Boolean published, String mimeType) throws SQLException
getFiles
in interface DbFilesHandler
SQLException
public final long[] getFileIds(Connection c) throws SQLException
getFileIds
in interface DbFilesHandler
SQLException
public abstract long[] getFileIds(Connection c, long objectId, Boolean published, String mimeType) throws SQLException
getFileIds
in interface DbFilesHandler
SQLException
public final void loadFileTranslations(Connection c, DbFile file, DbLanguagesHandler languageHandler) throws SQLException
loadFileTranslations
in interface DbFilesHandler
SQLException
public final void loadFileTranslations(Connection c, DbFile file, Map<Long,String> languages) throws SQLException
loadFileTranslations
in interface DbFilesHandler
SQLException
public final void loadFileTranslations(Connection c, DbFile[] files, DbLanguagesHandler languageHandler) throws SQLException
loadFileTranslations
in interface DbFilesHandler
SQLException
public abstract void loadFileTranslations(Connection c, DbFile[] files, Map<Long,String> languages) throws SQLException
loadFileTranslations
in interface DbFilesHandler
SQLException
public final void removeFile(Connection c, long id) throws SQLException
removeFile
in interface DbFilesHandler
SQLException
public abstract void removeFiles(Connection c, long[] ids) throws SQLException
removeFiles
in interface DbFilesHandler
SQLException
public final void saveFile(Connection c, DbFile file, File content) throws SQLException, IOException
saveFile
in interface DbFilesHandler
SQLException
IOException
public final void saveFile(Connection c, DbFile file, File content, File preview, DbLanguagesHandler languageHandler) throws SQLException, IOException
saveFile
in interface DbFilesHandler
SQLException
IOException
public abstract void saveFile(Connection c, DbFile file, File content, File preview, Map<Long,String> languageMap) throws SQLException, IOException
saveFile
in interface DbFilesHandler
SQLException
IOException
public abstract void setFileContent(Connection c, long fileId, File content, File preview) throws SQLException, IOException
setFileContent
in interface DbFilesHandler
SQLException
IOException
Copyright © 2019 OpenEstate. All rights reserved.