Documentation fixes and revamp user guide
[ric-plt/lib/rmr.git] / docs / rmr_wh_state.3.rst
1  
2  
3 .. This work is licensed under a Creative Commons Attribution 4.0 International License. 
4 .. SPDX-License-Identifier: CC-BY-4.0 
5 .. CAUTION: this document is generated from source in doc/src/rtd. 
6 .. To make changes edit the source and recompile the document. 
7 .. Do NOT make changes directly to .rst or .md files. 
8  
9  
10 ============================================================================================ 
11 Man Page: rmr_wh_state 
12 ============================================================================================ 
13  
14 RMR Library Functions 
15 ============================================================================================ 
16  
17  
18 NAME 
19 -------------------------------------------------------------------------------------------- 
20  
21 rmr_wh_state 
22  
23 SYNOPSIS 
24 -------------------------------------------------------------------------------------------- 
25  
26  
27 :: 
28   
29  #include <rmr/rmr.h>
30  int rmr_wh_state( void* vctx, rmr_whid_t whid )
31  
32  
33  
34 DESCRIPTION 
35 -------------------------------------------------------------------------------------------- 
36  
37 The rmr_wh_state function will return the current state of 
38 the connection associated with the given wormhole (whid). The 
39 return value indicates whether the connection is open 
40 (RMR_OK), or closed (any other return value). 
41  
42 When using some transport mechanisms (e.g. NNG), it may not 
43 be possible for RMR to know the actual state and the 
44 connection may always be reported as "open." 
45  
46 RETURN 
47 -------------------------------------------------------------------------------------------- 
48  
49 The following values are potential return values. 
50  
51  
52  
53 RMR_OK 
54    
55   The wormhole ID is valid and the connection is "open." 
56    
57  
58 RMR_ERR_WHID 
59    
60   THe wormhole ID passed into the function was not valid. 
61    
62  
63 RMR_ERR_NOENDPT 
64    
65   The wormhole is not open (not connected). 
66    
67  
68 RMR_ERR_BADARG 
69    
70   The context passed to the function was nil or invalid. 
71    
72  
73 RMR_ERR_NOWHOPEN 
74    
75   Wormholes have not been initialised (no wormhole open call 
76   has been made). 
77    
78  
79  
80 SEE ALSO 
81 -------------------------------------------------------------------------------------------- 
82  
83 rmr_wh_open(3), rmr_wh_send_msg(3), rmr_wh_close(3)