• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * coap_forward_decls.h -- Forward declarations of structures that are
3  * opaque to application programming that use libcoap.
4  *
5  * Copyright (C) 2019-2023 Jon Shallow <supjps-libcoap@jpshallow.com>
6  *
7  * SPDX-License-Identifier: BSD-2-Clause
8  *
9  * This file is part of the CoAP library libcoap. Please see README for terms
10  * of use.
11  */
12 
13 /**
14  * @file coap_forward_decls.h
15  * @brief CoAP forward definitions
16  */
17 
18 #ifndef COAP_FORWARD_DECLS_H_
19 #define COAP_FORWARD_DECLS_H_
20 
21 /*
22  * Define the forward declations for the structures (even non-opaque)
23  * so that applications (using coap.h) as well as libcoap builds
24  * can reference them (and makes .h file dependencies a lot simpler).
25  */
26 struct coap_address_t;
27 struct coap_bin_const_t;
28 struct coap_dtls_pki_t;
29 struct coap_str_const_t;
30 struct coap_string_t;
31 
32 typedef struct coap_address_t coap_address_t;
33 
34 /*
35  * typedef all the opaque structures that are defined in coap_*_internal.h
36  */
37 
38 /* ************* coap_async_internal.h ***************** */
39 
40 /**
41  * Async Entry information.
42  */
43 typedef struct coap_async_t coap_async_t;
44 
45 /* ************* coap_block_internal.h ***************** */
46 
47 /*
48  * Block handling information.
49  */
50 typedef struct coap_lg_xmit_t coap_lg_xmit_t;
51 typedef struct coap_lg_crcv_t coap_lg_crcv_t;
52 typedef struct coap_lg_srcv_t coap_lg_srcv_t;
53 
54 /* ************* coap_cache_internal.h ***************** */
55 
56 /*
57  * Cache Entry information.
58  */
59 typedef struct coap_cache_entry_t coap_cache_entry_t;
60 typedef struct coap_cache_key_t coap_cache_key_t;
61 
62 /* ************* coap_io_internal.h ***************** */
63 
64 /**
65  * coap_socket_t and coap_packet_t information.
66  */
67 typedef struct coap_packet_t coap_packet_t;
68 typedef struct coap_socket_t coap_socket_t;
69 
70 /* ************* coap_net_internal.h ***************** */
71 
72 /*
73  * Net information.
74  */
75 typedef struct coap_context_t coap_context_t;
76 typedef struct coap_queue_t coap_queue_t;
77 
78 /* ************* coap_oscore_internal.h ***************** */
79 
80 /*
81  * OSCORE information.
82  */
83 typedef struct coap_oscore_conf_t coap_oscore_conf_t;
84 
85 /* ************* coap_pdu_internal.h ***************** */
86 
87 /**
88  * PDU information.
89  */
90 typedef struct coap_pdu_t coap_pdu_t;
91 
92 /* ************* coap_resource_internal.h ***************** */
93 
94 /*
95  * Resource information.
96  */
97 typedef struct coap_attr_t coap_attr_t;
98 typedef struct coap_resource_t coap_resource_t;
99 
100 /* ************* coap_session_internal.h ***************** */
101 
102 /*
103  * Session information.
104  */
105 typedef struct coap_addr_hash_t coap_addr_hash_t;
106 typedef struct coap_endpoint_t coap_endpoint_t;
107 typedef struct coap_session_t coap_session_t;
108 
109 /* ************* coap_subscribe_internal.h ***************** */
110 
111 /*
112  * Observe subscriber information.
113  */
114 typedef struct coap_subscription_t coap_subscription_t;
115 
116 #endif /* COAP_FORWARD_DECLS_H_ */
117