當前位置: 首頁>>代碼示例>>Java>>正文


Java SharePointClient類代碼示例

本文整理匯總了Java中com.microsoft.fileservices.odata.SharePointClient的典型用法代碼示例。如果您正苦於以下問題:Java SharePointClient類的具體用法?Java SharePointClient怎麽用?Java SharePointClient使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


SharePointClient類屬於com.microsoft.fileservices.odata包,在下文中一共展示了SharePointClient類的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getFileFolderServiceResource

import com.microsoft.fileservices.odata.SharePointClient; //導入依賴的package包/類
private void getFileFolderServiceResource() {
    final SettableFuture<ServiceInfo> serviceDiscovered;


    serviceDiscovered = DiscoveryController
            .getInstance()
            .getServiceInfo(Constants.MYFILES_CAPABILITY);

    Futures.addCallback(
            serviceDiscovered,
            new FutureCallback<ServiceInfo>() {
                @Override
                public void onSuccess(ServiceInfo serviceInfo) {
                    Log.i(TAG, "onConnect - My files service discovered");
                    showDiscoverSuccessUI();

                    mMyFilesServiceResourceId =
                            serviceInfo.getserviceResourceId();

                    mMyFilesServiceEndpointUri =
                            serviceInfo.getserviceEndpointUri();

                    AuthenticationController.getInstance()
                            .setResourceId(mMyFilesServiceResourceId);
                    ADALDependencyResolver dependencyResolver = (ADALDependencyResolver) AuthenticationController
                            .getInstance()
                            .getDependencyResolver();

                    mMyFilesClient = new SharePointClient(
                            mMyFilesServiceEndpointUri,
                            dependencyResolver
                    );

                    //User is connected, SharePoint client endpoint is found
                    // Enable list item selection on main activity
                    enableListClick();
                    runOnUiThread(
                            new Runnable() {
                                @Override
                                public void run() {
                                    mSignIn.setEnabled(false);
                                    mSignOut.setEnabled(true);
                                }
                            }
                    );

                }

                @Override
                public void onFailure(final Throwable t) {
                    Log.e(TAG, "onConnect - " + t.getMessage());
                    showDiscoverErrorUI();
                }
            }
    );
}
 
開發者ID:OfficeDev,項目名稱:O365-Android-Snippets,代碼行數:57,代碼來源:OperationListActivity.java

示例2: postNewFileToServer

import com.microsoft.fileservices.odata.SharePointClient; //導入依賴的package包/類
public void postNewFileToServer(
        final O365APIsStart_Application application,
        final Activity currentActivity, String fileName,
        final String fileContents, final SharePointClient fileClient) {

    //Convert string to byte array and call the other overload of
    //postNewFileToServer
    postNewFileToServer(
            application
            , currentActivity
            , fileName
            , fileContents.getBytes()
            , fileClient);
}
 
開發者ID:mirontoli,項目名稱:andpoint,代碼行數:15,代碼來源:O365FileListModel.java

示例3: getO365MyFilesClient

import com.microsoft.fileservices.odata.SharePointClient; //導入依賴的package包/類
public SharePointClient getO365MyFilesClient() {
    return mO365MyFilesClient;
}
 
開發者ID:OfficeDev,項目名稱:O365-Android-Snippets,代碼行數:4,代碼來源:BaseUserStory.java

示例4: setO365MyFilesClient

import com.microsoft.fileservices.odata.SharePointClient; //導入依賴的package包/類
public void setO365MyFilesClient(SharePointClient client) {
    mO365MyFilesClient = client;
}
 
開發者ID:OfficeDev,項目名稱:O365-Android-Snippets,代碼行數:4,代碼來源:BaseUserStory.java

示例5: getO365MyFilesClient

import com.microsoft.fileservices.odata.SharePointClient; //導入依賴的package包/類
@Override
public SharePointClient getO365MyFilesClient() {
    return mMyFilesClient;
}
 
開發者ID:OfficeDev,項目名稱:O365-Android-Snippets,代碼行數:5,代碼來源:OperationListActivity.java

示例6: FileFolderSnippets

import com.microsoft.fileservices.odata.SharePointClient; //導入依賴的package包/類
public FileFolderSnippets(SharePointClient sharePointClient) {
    mSharePointClient = sharePointClient;
}
 
開發者ID:OfficeDev,項目名稱:O365-Android-Snippets,代碼行數:4,代碼來源:FileFolderSnippets.java

示例7: getO365MyFilesClient

import com.microsoft.fileservices.odata.SharePointClient; //導入依賴的package包/類
public SharePointClient getO365MyFilesClient(); 
開發者ID:OfficeDev,項目名稱:O365-Android-Snippets,代碼行數:2,代碼來源:O365Operations.java


注:本文中的com.microsoft.fileservices.odata.SharePointClient類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。