~paulliu/ubuntu/quantal/freerdp/fixext

« back to all changes in this revision

Viewing changes to include/freerdp/chanman.h

  • Committer: Package Import Robot
  • Author(s): Martin Pitt
  • Date: 2012-01-31 10:02:14 UTC
  • mto: This revision was merged to the branch mainline in revision 11.
  • Revision ID: package-import@ubuntu.com-20120131100214-zvig71djj2sqgq22
Tags: upstream-1.0.0
ImportĀ upstreamĀ versionĀ 1.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
   Copyright (c) 2009-2010 Jay Sorg
3
 
   Copyright (c) 2010 Vic Lee
4
 
 
5
 
   Permission is hereby granted, free of charge, to any person obtaining a
6
 
   copy of this software and associated documentation files (the "Software"),
7
 
   to deal in the Software without restriction, including without limitation
8
 
   the rights to use, copy, modify, merge, publish, distribute, sublicense,
9
 
   and/or sell copies of the Software, and to permit persons to whom the
10
 
   Software is furnished to do so, subject to the following conditions:
11
 
 
12
 
   The above copyright notice and this permission notice shall be included
13
 
   in all copies or substantial portions of the Software.
14
 
 
15
 
   THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
16
 
   OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
 
   FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
 
   AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
 
   LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20
 
   FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21
 
   DEALINGS IN THE SOFTWARE.
22
 
*/
23
 
 
24
 
#ifndef __FREERDP_CHANMAN_H
25
 
#define __FREERDP_CHANMAN_H
26
 
 
27
 
#include <freerdp/freerdp.h>
28
 
 
29
 
#if defined _WIN32 || defined __CYGWIN__
30
 
  #ifdef FREERDP_CHANMAN_EXPORTS
31
 
    #ifdef __GNUC__
32
 
      #define FREERDP_CHANMAN_API __attribute__((dllexport))
33
 
    #else
34
 
      #define FREERDP_CHANMAN_API __declspec(dllexport)
35
 
    #endif
36
 
  #else
37
 
    #ifdef __GNUC__
38
 
      #define FREERDP_CHANMAN_API __attribute__((dllimport))
39
 
    #else
40
 
      #define FREERDP_CHANMAN_API __declspec(dllimport)
41
 
    #endif
42
 
  #endif
43
 
#else
44
 
  #if __GNUC__ >= 4
45
 
    #define FREERDP_CHANMAN_API   __attribute__ ((visibility("default")))
46
 
  #else
47
 
    #define FREERDP_CHANMAN_API
48
 
  #endif
49
 
#endif
50
 
 
51
 
#ifdef __cplusplus
52
 
extern "C" {
53
 
#endif
54
 
 
55
 
#ifdef _WIN32
56
 
#define CHR TCHAR
57
 
#else
58
 
#define CHR char
59
 
#endif
60
 
 
61
 
typedef struct rdp_chan_man rdpChanMan;
62
 
 
63
 
FREERDP_CHANMAN_API int
64
 
freerdp_chanman_init(void);
65
 
FREERDP_CHANMAN_API int
66
 
freerdp_chanman_uninit(void);
67
 
FREERDP_CHANMAN_API rdpChanMan *
68
 
freerdp_chanman_new(void);
69
 
FREERDP_CHANMAN_API void
70
 
freerdp_chanman_free(rdpChanMan * chan_man);
71
 
FREERDP_CHANMAN_API int
72
 
freerdp_chanman_load_plugin(rdpChanMan * chan_man, rdpSet * settings,
73
 
        const CHR * filename, void * data);
74
 
FREERDP_CHANMAN_API int
75
 
freerdp_chanman_pre_connect(rdpChanMan * chan_man, rdpInst * inst);
76
 
FREERDP_CHANMAN_API int
77
 
freerdp_chanman_post_connect(rdpChanMan * chan_man, rdpInst * inst);
78
 
FREERDP_CHANMAN_API int
79
 
freerdp_chanman_data(rdpInst * inst, int chan_id, char * data, int data_size,
80
 
        int flags, int total_size);
81
 
FREERDP_CHANMAN_API int
82
 
freerdp_chanman_get_fds(rdpChanMan * chan_man, rdpInst * inst, void ** read_fds,
83
 
        int * read_count, void ** write_fds, int * write_count);
84
 
FREERDP_CHANMAN_API int
85
 
freerdp_chanman_check_fds(rdpChanMan * chan_man, rdpInst * inst);
86
 
FREERDP_CHANMAN_API void
87
 
freerdp_chanman_close(rdpChanMan * chan_man, rdpInst * inst);
88
 
 
89
 
#ifdef __cplusplus
90
 
}
91
 
#endif
92
 
 
93
 
#endif