public class OneDriveOperation extends Object
OAuthPreconditionException
が発生します。 コンストラクタと説明 |
---|
OneDriveOperation(String userCd,
String providerId)
コンストラクタ
|
OneDriveOperation(String userCd,
String providerId,
String sitePath)
コンストラクタ
|
OneDriveOperation(String userCd,
String providerId,
String sitePath,
String driveId)
コンストラクタ
|
修飾子とタイプ | メソッドと説明 |
---|---|
Item |
copyById(String id,
CopyToItemProperty properties)
IDを指定してアイテムをコピーします。
|
Item |
copyByPath(String path,
CopyToItemProperty properties)
パスを指定してアイテムをコピーします。
|
Item |
createFile(String name)
ファイルを作成します。
|
Item |
createFolderById(String folderName,
String parentId)
親フォルダIDとフォルダ名を指定してフォルダを作成します。
|
Item |
createFolderByPath(String folderName,
String folderPath)
パスを指定してフォルダを作成します。
|
void |
deleteById(String id,
String eTag)
IDを指定してアイテムを削除します。
|
void |
deleteByPath(String path,
String eTag)
パスを指定してアイテムを削除します。
|
void |
downloadById(String id,
OutputStream stream)
IDを指定してファイルの内容をダウンロードします。
|
void |
downloadByPath(String path,
OutputStream stream)
パスを指定してファイルの内容をダウンロードします。
|
void |
downloadByPath(String path,
String format,
OutputStream stream)
パスを指定してファイルの内容を指定した形式でダウンロードします。
|
Collection<DriveItem> |
getDrives()
ドライブの一覧を取得します。
|
Map<String,Object> |
getListItemFieldsById(String id,
String listId)
IDを指定してアイテム関連するリストアイテムのフィールド情報を取得します。
|
Item |
getPropertiesById(String id,
boolean withChildren)
IDを指定してアイテムのプロパティ情報を取得します。
|
Item |
getPropertiesByPath(String path,
boolean withChildren)
パスを指定してアイテムのプロパティ情報を取得します。
|
Item |
largeItemUploadByParentId(UploadItemProperty property,
String parentId,
InputStream stream)
親アイテムのIDを指定して大容量ファイルの内容をアップロードします。
|
Item |
largeItemUploadByPath(UploadItemProperty property,
String filePath,
InputStream stream)
パスを指定して大容量ファイルの内容をアップロードします。
|
Item[] |
listContentsById(String id,
boolean descending)
IDを指定して保持する子のアイテム一覧を取得します。
|
Item[] |
listContentsByPath(String path,
boolean descending)
パスを指定して保持する子のアイテム一覧を取得します。
|
void |
resumableItemUploadById(UploadItemProperty property,
String parentId,
InputStream stream)
非推奨です。
アップロードしたファイル情報が確認可能である
largeItemUploadByParentId(UploadItemProperty, String, InputStream) を利用してください。 |
void |
resumableItemUploadByPath(UploadItemProperty property,
String filePath,
InputStream stream)
非推奨です。
アップロードしたファイル情報が確認可能である
largeItemUploadByPath(UploadItemProperty, String, InputStream) を利用してください。 |
void |
simpleItemUploadById(String name,
String parentId,
InputStream stream)
IDを指定してファイルの内容をアップロードします。
|
void |
simpleItemUploadByPath(String filePath,
InputStream stream)
パスを指定してファイルの内容をアップロードします。
|
Map<String,Object> |
updateListItemFieldsById(String id,
String listId,
Map<String,Object> fields)
IDを指定してアイテムに対するリストアイテムのフィールド情報を更新します。
|
Item |
updatePropertiesById(String id,
String eTag,
UpdateItemProperty properties)
IDを指定してアイテムのメタ情報を更新します。
|
Item |
updatePropertiesByPath(String path,
String eTag,
UpdateItemProperty properties)
パスを指定してアイテムのメタ情報を更新します。
|
public OneDriveOperation(String userCd, String providerId) throws ProviderSettingException
userCd
- ユーザコードproviderId
- プロバイダIDProviderSettingException
- プロバイダ設定が不正であった場合に発生します。public OneDriveOperation(String userCd, String providerId, String sitePath) throws ProviderSettingException
userCd
- ユーザコードproviderId
- プロバイダIDsitePath
- サイトパス。トップサイトの場合はnullを指定します。ProviderSettingException
- プロバイダ設定が不正であった場合に発生します。public OneDriveOperation(String userCd, String providerId, String sitePath, String driveId) throws ProviderSettingException
userCd
- ユーザコードproviderId
- プロバイダIDsitePath
- サイトパス。トップサイトの場合はnullを指定します。driveId
- ドライブIDProviderSettingException
- プロバイダ設定が不正であった場合に発生します。public Item copyById(String id, CopyToItemProperty properties) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
id
- IDproperties
- 変更を行うプロパティHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item copyByPath(String path, CopyToItemProperty properties) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
path
- パスproperties
- 変更を行うプロパティHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item createFile(String name) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
name
- ファイル名HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item createFolderById(String folderName, String parentId) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
folderName
- フォルダ名parentId
- 親IDHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item createFolderByPath(String folderName, String folderPath) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
folderName
- フォルダ名folderPath
- 親フォルダパスHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic void deleteById(String id, String eTag) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
id
- IDeTag
- ETagHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic void deleteByPath(String path, String eTag) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
path
- パスeTag
- ETagHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic void downloadById(String id, OutputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
id
- IDstream
- ファイルの内容を書き込むストリームHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生しますpublic void downloadByPath(String path, OutputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
path
- パスstream
- ファイルの内容を書き込むストリームHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生しますpublic void downloadByPath(String path, String format, OutputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
path
- パスformat
- フォーマットstream
- ファイルの内容を書き込むストリームHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生しますpublic Collection<DriveItem> getDrives() throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
HttpRequestException
- HTTP通信に失敗した場合HttpResponseException
- HTTP通信に失敗した場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Map<String,Object> getListItemFieldsById(String id, String listId) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
id
- アイテムIDlistId
- リストIDfields
- 更新対象のフィールド情報HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item getPropertiesById(String id, boolean withChildren) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
id
- IDwithChildren
- 内包するアイテム情報を取得するかHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item getPropertiesByPath(String path, boolean withChildren) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
path
- パスwithChildren
- 内包するアイテム情報を取得するかHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item largeItemUploadByParentId(UploadItemProperty property, String parentId, InputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
property
- アップロードするファイルのプロパティparentId
- アップロード先ディレクトリのIDstream
- ファイルの内容HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生しますpublic Item largeItemUploadByPath(UploadItemProperty property, String filePath, InputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
property
- アップロードするファイルのプロパティ。filePath
- アップロード先のファイルパスstream
- ファイルの内容HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生しますpublic Item[] listContentsById(String id, boolean descending) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
id
- IDdescending
- 降順でソートするかHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item[] listContentsByPath(String path, boolean descending) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
path
- パスdescending
- 降順でソートするかHttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生します@Deprecated public void resumableItemUploadById(UploadItemProperty property, String parentId, InputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
largeItemUploadByParentId(UploadItemProperty, String, InputStream)
を利用してください。property
- アップロードするファイルのプロパティparentId
- アップロード先ディレクトリのIDstream
- ファイルの内容HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生します@Deprecated public void resumableItemUploadByPath(UploadItemProperty property, String filePath, InputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
largeItemUploadByPath(UploadItemProperty, String, InputStream)
を利用してください。property
- アップロードするファイルのプロパティfilePath
- アップロード先のファイルパスstream
- ファイルの内容HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生しますpublic void simpleItemUploadById(String name, String parentId, InputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
largeItemUploadByParentId(UploadItemProperty, String, InputStream)
を利用してください。name
- アップロードファイル名parentId
- アップロード先ディレクトリのIDstream
- ファイルの内容HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生しますpublic void simpleItemUploadByPath(String filePath, InputStream stream) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException, IOException
largeItemUploadByPath(UploadItemProperty, String, InputStream)
を利用してください。filePath
- アップロード先のファイルパスstream
- ファイルの内容HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますIOException
- ストリーム処理に失敗した場合に発生しますpublic Map<String,Object> updateListItemFieldsById(String id, String listId, Map<String,Object> fields) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
id
- アイテムIDlistId
- 親リストIDfields
- 更新対象のフィールド情報HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item updatePropertiesById(String id, String eTag, UpdateItemProperty properties) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
id
- IDeTag
- ETagproperties
- メタ情報HttpRequestException
- HTTP通信に失敗した場合に発生します。HttpResponseException
- HTTP通信のレスポンスが不正だった場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますpublic Item updatePropertiesByPath(String path, String eTag, UpdateItemProperty properties) throws HttpRequestException, HttpResponseException, Office365APIResponseException, OAuthClientException
path
- パスeTag
- ETagproperties
- メタ情報HttpRequestException
- HTTP通信に失敗した場合HttpResponseException
- HTTP通信に失敗した場合に発生しますOffice365APIResponseException
- 操作の失敗を表すOffice365レスポンスが返った場合に発生しますOAuthClientException
- OAuth関連の処理に失敗した場合に発生しますCopyright © 2012 NTT DATA INTRAMART CORPORATION