Search in sources :

Example 1 with FetchRemoteFileTask

use of com.owncloud.android.ui.asynctasks.FetchRemoteFileTask in project android by nextcloud.

the class FileDisplayActivity method openFile.

private void openFile(User user, String fileId) {
    setUser(user);
    if (fileId == null) {
        dismissLoadingDialog();
        DisplayUtils.showSnackMessage(this, getString(R.string.error_retrieving_file));
        return;
    }
    FileDataStorageManager storageManager = getStorageManager();
    if (storageManager == null) {
        storageManager = new FileDataStorageManager(user, getContentResolver());
    }
    FetchRemoteFileTask fetchRemoteFileTask = new FetchRemoteFileTask(user, fileId, storageManager, this);
    fetchRemoteFileTask.execute();
}
Also used : FileDataStorageManager(com.owncloud.android.datamodel.FileDataStorageManager) FetchRemoteFileTask(com.owncloud.android.ui.asynctasks.FetchRemoteFileTask)

Aggregations

FileDataStorageManager (com.owncloud.android.datamodel.FileDataStorageManager)1 FetchRemoteFileTask (com.owncloud.android.ui.asynctasks.FetchRemoteFileTask)1