Visual C++ 中的云和 Web 编程Cloud and Web Programming in Visual C++

C++ 中有多种选项可使你连接到 Web 和云。In C++, you have several options for connecting to the web and the cloud.

Microsoft Azure SDK 和 REST 服务Microsoft Azure SDKs and REST services

  • 用于 C++ 的 Microsoft Azure 存储客户端库Microsoft Azure Storage Client Library for C++

    用于 C++ 的 Azure 存储客户端库提供了一个用于处理 Azure 存储的综合 API,此 API 包括但不限于以下功能:The Azure Storage Client Library for C++ provides a comprehensive API for working with Azure storage, including but not limited to the following abilities:

    • 创建、读取、删除和列出 Blob 容器、表和队列。Create, read, delete, and list blob containers, tables, and queues.
    • 创建、读取、删除、列出和复制 Blob,以及读取和写入 Blob 范围。Create, read, delete, list and copy blobs plus read and write blob ranges.
    • 在 Azure 表中插入、删除、替换、合并和查询实体。Insert, delete, replace, merge, and query entities in an Azure table.
    • 在 Azure 队列中对消息进行排队和取消排队。Enqueue and dequeue messages in an Azure queue.
    • 延迟列出容器、Blob、表和队列,并延迟查询实体Lazily list containers, blobs, tables, and queues, and lazily query entities
  • 用于物联网的 ANSI C99 Azure IoT 中心 SDK 使 IoT 应用程序能够在设备或后端运行。The ANSI C99 Azure IoT Hub SDKs for Internet of Things enable IoT applications to run on the device or on the backend.

  • Microsoft Graph 中的 OneDrive 和 SharePointOneDrive and SharePoint in Microsoft Graph

    OneDrive API 提供了一组 HTTP 服务,用于将应用程序连接到 Office 365 和 SharePoint Server 2016 中的文件和文件夹。The OneDrive API provides a set of HTTP services to connect your application to files and folders in Office 365 and SharePoint Server 2016.

Windows 和跨平台网络 APIWindows and cross-platform networking APIs

  • C++ REST SDK(代码名称“Casablanca”)C++ REST SDK (Code name "Casablanca")

    提供现代的跨平台异步 API,用于与 REST 服务进行交互。Provides a modern, cross-platform, asynchronous API for interacting with REST services.

    • 对任何 HTTP 服务器执行 REST 调用,内置有对 JSON 文档分析和序列化的支持Perform REST calls against any HTTP server, with built-in support for JSON document parsing and serialization
    • 支持 OAuth 1 和 2,包括本地重定向侦听器Supports OAuth 1 and 2, including a local redirect listener
    • 使 Websocket 连接到远程服务Make WebSockets connections against remote services
    • 基于 PPL 的完全异步任务 API,包含内置线程池A fully asynchronous task API based on PPL, including a built-in thread pool

    支持 Windows 桌面 (7+)、Windows Server (2012+)、通用 Windows 平台、Linux、OSX、Android 和 iOS。Supports Windows Desktop (7+), Windows Server (2012+), Universal Windows Platform, Linux, OSX, Android, and iOS.

  • Windows::Web::Http::HttpClientWindows::Web::Http::HttpClient

    Windows 运行时 HTTP 客户端类在 .NET Framework 类上建模,后者在 System.Web 命名空间中具有相同的名称。A Windows Runtime HTTP client class modeled on the .NET Framework class of the same name in the System.Web namespace. HttpClient 完全支持通过 HTTP 异步上载和下载,还完全支持可将自定义 HTTP 处理程序插入到管道中的管道筛选器。HttpClient fully supports asynchronous upload and download over HTTP, and pipeline filters that enable the insertion of custom HTTP handlers into the pipeline. Windows SDK 包括用于按流量计费的网络和 OAuth 身份验证等的样本筛选器。The Windows SDK includes sample filters for metered networks, OAuth authentication, and more. 对于仅面向通用 Windows 平台的应用,我们建议使用 Windows::Web:HttpClient 类。For apps that target only Universal Windows Platform, we recommend that you use the Windows::Web:HttpClient class.

  • IXMLHTTPRequest2 接口IXMLHTTPRequest2 interface

    提供可在 Windows 运行时应用或 Windows 桌面应用中使用的本机 COM 接口,用于通过 HTTP 连接到 Internet,并发布 GET、PUT 和其他 HTTP 命令。Provides a native COM interface that you can use in Windows Runtime apps or Windows desktop apps to connect to the Internet over HTTP and issue GET, PUT, and other HTTP commands. 有关详细信息,请参见演练:使用任务和 XML HTTP 请求进行连接For more information, see Walkthrough: Connecting Using Tasks and XML HTTP Requests.

  • Windows Internet (WinInet)Windows Internet (WinInet)

    可以在 Windows 桌面应用中使用以连接到 Internet 的 Windows API。Windows API that you can use in Windows desktop apps to connect to the Internet.

请参阅See also

Visual Studio 中的 C++C++ in Visual Studio
Microsoft Azure C 和 C++ 开发人员中心Microsoft Azure C and C++ Developer Center
网络和 Web 服务 (UWP)Networks and web services (UWP)