[Cion] Add new APIs for Advanced Companion Framework (#3472)
[platform/core/csapi/tizenfx.git] / src / Tizen.Applications.Cion / Interop / Interop.CionPeerInfo.cs
1 /*
2  * Copyright (c) 2021 Samsung Electronics Co., Ltd All Rights Reserved
3  *
4  * Licensed under the Apache License, Version 2.0 (the License);
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an AS IS BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 using System;
18 using System.Runtime.InteropServices;
19 using Tizen.Applications;
20
21 using ErrorCode = Interop.Cion.ErrorCode;
22
23 internal static partial class Interop
24 {
25     internal static partial class CionPeerInfo
26     {
27         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_clone")]
28         internal static extern ErrorCode CionPeerInfoClone(IntPtr peerInfo, out PeerInfoSafeHandle peerInfoClone);
29
30         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_destroy")]
31         internal static extern ErrorCode CionPeerInfoDestroy(IntPtr peerInfo);
32
33         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_get_device_id")]
34         internal static extern ErrorCode CionPeerInfoGetDeviceId(PeerInfoSafeHandle peerInfo, out string deviceId);
35
36         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_get_device_name")]
37         internal static extern ErrorCode CionPeerInfoGetDeviceName(PeerInfoSafeHandle peerInfo, out string deviceName);
38
39         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_get_device_platform")]
40         internal static extern ErrorCode CionPeerInfoGetDevicePlatform(PeerInfoSafeHandle peerInfo, out string devicePlatform);
41
42         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_get_device_platform_version")]
43         internal static extern ErrorCode CionPeerInfoGetDevicePlatformVersion(PeerInfoSafeHandle peerInfo, out string devicePlatformVersion);
44
45         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_get_device_type")]
46         internal static extern ErrorCode CionPeerInfoGetDeviceType(PeerInfoSafeHandle peerInfo, out string deviceType);
47
48         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_get_app_id")]
49         internal static extern ErrorCode CionPeerInfoGetAppId(PeerInfoSafeHandle peerInfo, out string appId);
50
51         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_get_app_version")]
52         internal static extern ErrorCode CionPeerInfoGetAppVersion(PeerInfoSafeHandle peerInfo, out string appVersion);
53
54         [DllImport(Libraries.Cion, EntryPoint = "cion_peer_info_get_uuid")]
55         internal static extern ErrorCode CionPeerInfoGetUuid(PeerInfoSafeHandle peerInfo, out string uuid);
56     }
57 }