Apply smack patch
[framework/appfw/shortcut.git] / include / secom_socket.h
1 /*
2  * Copyright 2012  Samsung Electronics Co., Ltd
3  *
4  * Licensed under the Flora License, Version 1.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.tizenopensource.org/license
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 /*
18  * Create client connection
19  */
20 extern int secom_create_client(const char *peer);
21
22 /*
23  * Create server connection
24  */
25 extern int secom_create_server(const char *peer);
26
27 /*
28  * Get the raw handle to use it for non-blocking mode.
29  */
30 extern int secom_get_connection_handle(int server_handle);
31 extern int secom_put_connection_handle(int conn_handle);
32
33 /*
34  * Send data to the connected peer.
35  */
36 extern int secom_send(int conn, const char *buffer, int size);
37
38 /*
39  * Recv data from the connected peer. and its PID value
40  */
41 extern int secom_recv(int conn, char *buffer, int size, int *sender_pid);
42
43 /*
44  * Destroy a connection
45  */
46 extern int secom_destroy(int conn);
47
48 /* End of a file */