public class FileManager extends Object
| Constructor and Description |
|---|
FileManager(Configuration configuration,
AuthenticatedHTTPClient authenticatedHttpClient,
FileUploader fileUploader) |
| Modifier and Type | Method and Description |
|---|---|
FileDescriptor |
createFile(CreateFileRequest createFileRequest) |
void |
deleteFileById(String fileId) |
void |
deleteFileByPath(String path) |
FileDescriptor |
getFile(String path) |
FileMetadata |
getFileMetadataById(String fileId) |
GetUploadUrlResponse |
getUploadUrl() |
GetUploadUrlResponse |
getUploadUrl(UploadUrlRequest uploadUrlRequest) |
Job |
importFile(ImportFileRequest importFileRequest) |
ListFilesResponse |
listFiles(String path,
ListFilesRequest listFilesRequest) |
FileDescriptor[] |
uploadFile(String path,
String mimeType,
String fileName,
File source,
String acl) |
FileDescriptor[] |
uploadFile(String path,
String mimeType,
String fileName,
InputStream source) |
FileDescriptor[] |
uploadFile(String path,
String mimeType,
String fileName,
InputStream source,
String acl) |
public FileManager(Configuration configuration, AuthenticatedHTTPClient authenticatedHttpClient, FileUploader fileUploader)
public GetUploadUrlResponse getUploadUrl() throws UnauthorizedException, IOException, URISyntaxException
public GetUploadUrlResponse getUploadUrl(UploadUrlRequest uploadUrlRequest) throws UnauthorizedException, IOException, URISyntaxException
public FileDescriptor[] uploadFile(String path, String mimeType, String fileName, InputStream source) throws UnauthorizedException, IOException, URISyntaxException
public FileDescriptor[] uploadFile(String path, String mimeType, String fileName, InputStream source, String acl) throws UnauthorizedException, IOException, URISyntaxException
public FileDescriptor[] uploadFile(String path, String mimeType, String fileName, File source, String acl) throws UnauthorizedException, IOException, URISyntaxException
public Job importFile(ImportFileRequest importFileRequest) throws UnauthorizedException, IOException, URISyntaxException
public FileDescriptor createFile(CreateFileRequest createFileRequest) throws UnauthorizedException, IOException, URISyntaxException
@Nullable public FileDescriptor getFile(String path) throws UnauthorizedException, IOException, URISyntaxException
@Nullable public FileMetadata getFileMetadataById(String fileId) throws UnauthorizedException, IOException, URISyntaxException
public ListFilesResponse listFiles(String path, @Nullable ListFilesRequest listFilesRequest) throws UnauthorizedException, IOException, URISyntaxException
public void deleteFileByPath(String path) throws UnauthorizedException, IOException, URISyntaxException
public void deleteFileById(String fileId) throws UnauthorizedException, IOException, URISyntaxException
Copyright © 2017 Media Cloud. All rights reserved.