AllJoynSession.GetFromServiceInfoAsync 方法

定义

重载

GetFromServiceInfoAsync(AllJoynServiceInfo)

重要

Windows.Devices.AllJoyn 命名空间中的类型已弃用,将来的 Windows 版本中可能不可用。 AllJoyn(由 AllSeen Alliance 赞助)是一种开源发现和通信协议,适用于物联网 (IoT) 方案,例如开灯和关灯以及读取温度。 有关替代项(如 IoTivity LiteIoTivity),请参阅 iotivity.org 网站。

根据指定的服务信息获取与生成者的会话。

GetFromServiceInfoAsync(AllJoynServiceInfo, AllJoynBusAttachment)

重要

Windows.Devices.AllJoyn 命名空间中的类型已弃用,将来的 Windows 版本中可能不可用。 AllJoyn(由 AllSeen Alliance 赞助)是一种开源发现和通信协议,适用于物联网 (IoT) 方案,例如开灯和关灯以及读取温度。 有关替代项(如 IoTivity LiteIoTivity),请参阅 iotivity.org 网站。

根据指定的服务信息和总线附件获取与生成者的会话。

GetFromServiceInfoAsync(AllJoynServiceInfo)

重要

Windows.Devices.AllJoyn 命名空间中的类型已弃用,将来的 Windows 版本中可能不可用。 AllJoyn(由 AllSeen Alliance 赞助)是一种开源发现和通信协议,适用于物联网 (IoT) 方案,例如开灯和关灯以及读取温度。 有关替代项(如 IoTivity LiteIoTivity),请参阅 iotivity.org 网站。

根据指定的服务信息获取与生成者的会话。

public:
 static IAsyncOperation<AllJoynSession ^> ^ GetFromServiceInfoAsync(AllJoynServiceInfo ^ serviceInfo);
/// [Windows.Foundation.Metadata.Overload("GetFromServiceInfoAsync")]
/// [Windows.Foundation.Metadata.RemoteAsync]
 static IAsyncOperation<AllJoynSession> GetFromServiceInfoAsync(AllJoynServiceInfo const& serviceInfo);
/// [Windows.Foundation.Metadata.Overload("GetFromServiceInfoAsync")]
/// [Windows.Foundation.Metadata.RemoteAsync]
/// [Windows.Foundation.Metadata.Deprecated("AllJoynSession has been deprecated.  For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 786432, "Windows.Foundation.UniversalApiContract")]
 static IAsyncOperation<AllJoynSession> GetFromServiceInfoAsync(AllJoynServiceInfo const& serviceInfo);
[Windows.Foundation.Metadata.Overload("GetFromServiceInfoAsync")]
[Windows.Foundation.Metadata.RemoteAsync]
public static IAsyncOperation<AllJoynSession> GetFromServiceInfoAsync(AllJoynServiceInfo serviceInfo);
[Windows.Foundation.Metadata.Overload("GetFromServiceInfoAsync")]
[Windows.Foundation.Metadata.RemoteAsync]
[Windows.Foundation.Metadata.Deprecated("AllJoynSession has been deprecated.  For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 786432, "Windows.Foundation.UniversalApiContract")]
public static IAsyncOperation<AllJoynSession> GetFromServiceInfoAsync(AllJoynServiceInfo serviceInfo);
function getFromServiceInfoAsync(serviceInfo)
Public Shared Function GetFromServiceInfoAsync (serviceInfo As AllJoynServiceInfo) As IAsyncOperation(Of AllJoynSession)

参数

serviceInfo
AllJoynServiceInfo

用于获取正确会话的服务信息。

返回

基于服务信息的 AllJoyn 会话的 AllJoyn 对象。

属性

Windows 要求

应用功能
allJoyn

另请参阅

适用于

GetFromServiceInfoAsync(AllJoynServiceInfo, AllJoynBusAttachment)

重要

Windows.Devices.AllJoyn 命名空间中的类型已弃用,将来的 Windows 版本中可能不可用。 AllJoyn(由 AllSeen Alliance 赞助)是一种开源发现和通信协议,适用于物联网 (IoT) 方案,例如开灯和关灯以及读取温度。 有关替代项(如 IoTivity LiteIoTivity),请参阅 iotivity.org 网站。

根据指定的服务信息和总线附件获取与生成者的会话。

public:
 static IAsyncOperation<AllJoynSession ^> ^ GetFromServiceInfoAsync(AllJoynServiceInfo ^ serviceInfo, AllJoynBusAttachment ^ busAttachment);
/// [Windows.Foundation.Metadata.Overload("GetFromServiceInfoAndBusAttachmentAsync")]
/// [Windows.Foundation.Metadata.RemoteAsync]
 static IAsyncOperation<AllJoynSession> GetFromServiceInfoAsync(AllJoynServiceInfo const& serviceInfo, AllJoynBusAttachment const& busAttachment);
/// [Windows.Foundation.Metadata.Overload("GetFromServiceInfoAndBusAttachmentAsync")]
/// [Windows.Foundation.Metadata.RemoteAsync]
/// [Windows.Foundation.Metadata.Deprecated("AllJoynSession has been deprecated.  For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 786432, "Windows.Foundation.UniversalApiContract")]
 static IAsyncOperation<AllJoynSession> GetFromServiceInfoAsync(AllJoynServiceInfo const& serviceInfo, AllJoynBusAttachment const& busAttachment);
[Windows.Foundation.Metadata.Overload("GetFromServiceInfoAndBusAttachmentAsync")]
[Windows.Foundation.Metadata.RemoteAsync]
public static IAsyncOperation<AllJoynSession> GetFromServiceInfoAsync(AllJoynServiceInfo serviceInfo, AllJoynBusAttachment busAttachment);
[Windows.Foundation.Metadata.Overload("GetFromServiceInfoAndBusAttachmentAsync")]
[Windows.Foundation.Metadata.RemoteAsync]
[Windows.Foundation.Metadata.Deprecated("AllJoynSession has been deprecated.  For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 786432, "Windows.Foundation.UniversalApiContract")]
public static IAsyncOperation<AllJoynSession> GetFromServiceInfoAsync(AllJoynServiceInfo serviceInfo, AllJoynBusAttachment busAttachment);
function getFromServiceInfoAsync(serviceInfo, busAttachment)
Public Shared Function GetFromServiceInfoAsync (serviceInfo As AllJoynServiceInfo, busAttachment As AllJoynBusAttachment) As IAsyncOperation(Of AllJoynSession)

参数

serviceInfo
AllJoynServiceInfo

用于获取正确会话的服务信息。

busAttachment
AllJoynBusAttachment

用于标识 AllJoyn 会话的总线附件。 如果未指定,则将其设置为 AllJoynBusAttachment.GetDefault 的结果。

返回

基于服务信息的 AllJoyn 会话的 AllJoyn 对象。

属性

Windows 要求

应用功能
allJoyn

另请参阅

适用于