Package com.logicaldoc.google
Class DriveClient
java.lang.Object
com.logicaldoc.google.GoogleClient
com.logicaldoc.google.DriveClient
Facade for Google Drive.
To handle the API: https://console.developers.google.com
- Since:
- 7.3
- Author:
- Marco Meschieri - LogicalDOC
-
Method Summary
Modifier and TypeMethodDescriptionvoidconvertFile(String fileId, File dest) createFolder(String name) voiddeleteFile(String fileId) voiddownloadFile(String fileId, File dest) static DriveClientcom.google.api.services.drive.model.FileList<com.google.api.services.drive.model.File> uploadFile(com.google.api.client.http.AbstractInputStreamContent mediaContent, String fileName, boolean convert) uploadFile(File file, String fileName, boolean convert) uploadFile(InputStream is, String fileName, boolean convert) Methods inherited from class com.logicaldoc.google.GoogleClient
connect, getAccessToken, getRefreshToken, getUserName, isConnected, loadSettings
-
Method Details
-
get
public static DriveClient get(String name) throws com.logicaldoc.core.PersistenceException, com.logicaldoc.util.security.StringEncrypter.EncryptionException, IOException - Throws:
com.logicaldoc.core.PersistenceExceptioncom.logicaldoc.util.security.StringEncrypter.EncryptionExceptionIOException
-
getFile
- Throws:
IOException
-
uploadFile
- Throws:
IOException
-
uploadFile
- Throws:
IOException
-
uploadFile
public String uploadFile(com.google.api.client.http.AbstractInputStreamContent mediaContent, String fileName, boolean convert) throws IOException - Throws:
IOException
-
create
- Throws:
IOException
-
createFolder
- Throws:
IOException
-
downloadFile
- Throws:
IOException
-
convertFile
- Throws:
IOException
-
deleteFile
- Throws:
IOException
-
search
- Throws:
IOException
-