/src/Fast-DDS/include/fastdds/rtps/writer/WriterDiscoveryInfo.h
Line | Count | Source (jump to first uncovered line) |
1 | | // Copyright 2018 Proyectos y Sistemas de Mantenimiento SL (eProsima). |
2 | | // |
3 | | // Licensed under the Apache License, Version 2.0 (the "License"); |
4 | | // you may not use this file except in compliance with the License. |
5 | | // You may obtain a copy of the License at |
6 | | // |
7 | | // http://www.apache.org/licenses/LICENSE-2.0 |
8 | | // |
9 | | // Unless required by applicable law or agreed to in writing, software |
10 | | // distributed under the License is distributed on an "AS IS" BASIS, |
11 | | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
12 | | // See the License for the specific language governing permissions and |
13 | | // limitations under the License. |
14 | | |
15 | | /** |
16 | | * @file WriterDiscoveryInfo.h |
17 | | */ |
18 | | #ifndef _RTPS_WRITER_WRITERDISCOVERYINFO_H_ |
19 | | #define _RTPS_WRITER_WRITERDISCOVERYINFO_H_ |
20 | | |
21 | | #include <fastrtps/fastrtps_dll.h> |
22 | | #include <fastdds/rtps/builtin/data/WriterProxyData.h> |
23 | | |
24 | | namespace eprosima { |
25 | | namespace fastrtps { |
26 | | namespace rtps { |
27 | | |
28 | | /** |
29 | | * Class WriterDiscoveryInfo with discovery information of the writer. |
30 | | * @ingroup RTPS_MODULE |
31 | | */ |
32 | | struct WriterDiscoveryInfo |
33 | | { |
34 | | public: |
35 | | |
36 | | //!Enum DISCOVERY_STATUS, four different status for discovered writers. |
37 | | //!@ingroup RTPS_MODULE |
38 | | #if defined(_WIN32) |
39 | | enum RTPS_DllAPI DISCOVERY_STATUS |
40 | | #else |
41 | | enum DISCOVERY_STATUS |
42 | | #endif |
43 | | { |
44 | | DISCOVERED_WRITER, |
45 | | CHANGED_QOS_WRITER, |
46 | | REMOVED_WRITER |
47 | | }; |
48 | | |
49 | | WriterDiscoveryInfo(const WriterProxyData& data) |
50 | | : status(DISCOVERED_WRITER) |
51 | | , info(data) |
52 | 0 | {} |
53 | | |
54 | 0 | virtual ~WriterDiscoveryInfo() {} |
55 | | |
56 | | //! Status |
57 | | DISCOVERY_STATUS status; |
58 | | |
59 | | //! Participant discovery info |
60 | | const WriterProxyData& info; |
61 | | }; |
62 | | |
63 | | } |
64 | | } |
65 | | } |
66 | | |
67 | | #endif // _RTPS_WRITER_WRITERDISCOVERYINFO_H_ |