From a8c78dffb36688b06c6a2650121f534d15a6e30a Mon Sep 17 00:00:00 2001 From: elianalf <62831776+elianalf@users.noreply.github.com> Date: Fri, 19 Apr 2024 09:09:53 +0200 Subject: [PATCH] Refs #20818: Make ResourceEvent private Signed-off-by: elianalf <62831776+elianalf@users.noreply.github.com> --- .../fastrtps/rtps/resources/ResourceEvent.h | 25 ------------------- src/cpp/fastdds/publisher/DataWriterImpl.cpp | 3 ++- src/cpp/fastdds/subscriber/DataReaderImpl.cpp | 2 +- .../discovery/participant/PDPServer.hpp | 3 +-- .../participant/timedevent/DSClientEvent.cpp | 3 +-- .../participant/timedevent/DServerEvent.cpp | 3 +-- src/cpp/rtps/builtin/liveliness/WLP.cpp | 2 +- .../rtps/participant/RTPSParticipantImpl.h | 2 +- src/cpp/rtps/reader/RTPSReader.cpp | 19 +++++--------- src/cpp/rtps/resources/ResourceEvent.cpp | 3 ++- .../cpp}/rtps/resources/ResourceEvent.h | 0 src/cpp/rtps/resources/TimedEvent.cpp | 2 +- src/cpp/rtps/writer/StatefulWriter.cpp | 2 +- .../fastdds/domain/DomainParticipantImpl.hpp | 2 +- .../rtps/participant/RTPSParticipant.h | 2 +- .../rtps/participant/RTPSParticipantImpl.h | 2 +- .../rtps/resources/ResourceEvent.h | 0 .../fastdds/rtps/reader/StatefulReader.h | 2 +- .../rtps/reader/WriterProxyStopTest.cpp | 4 +-- .../resources/timedevent/TimedEventTests.cpp | 2 +- .../rtps/writer/LivelinessManagerTests.cpp | 3 +-- .../statistics/rtps/MonitorServiceTests.cpp | 2 +- 22 files changed, 27 insertions(+), 61 deletions(-) delete mode 100644 include/fastrtps/rtps/resources/ResourceEvent.h rename {include/fastdds => src/cpp}/rtps/resources/ResourceEvent.h (100%) rename test/mock/rtps/ResourceEvent/{fastdds => }/rtps/resources/ResourceEvent.h (100%) diff --git a/include/fastrtps/rtps/resources/ResourceEvent.h b/include/fastrtps/rtps/resources/ResourceEvent.h deleted file mode 100644 index 70b2020edab..00000000000 --- a/include/fastrtps/rtps/resources/ResourceEvent.h +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima). -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -/** - * @file ResourceEvent.h - * - */ - -#ifndef _RTPS_RESOURCES_RESOURCEEVENT_H_ -#define _RTPS_RESOURCES_RESOURCEEVENT_H_ - -#include - -#endif //_RTPS_RESOURCES_RESOURCEEVENT_H_ diff --git a/src/cpp/fastdds/publisher/DataWriterImpl.cpp b/src/cpp/fastdds/publisher/DataWriterImpl.cpp index 03696bb7e5b..c899e82ea9f 100644 --- a/src/cpp/fastdds/publisher/DataWriterImpl.cpp +++ b/src/cpp/fastdds/publisher/DataWriterImpl.cpp @@ -37,7 +37,7 @@ #include #include #include -#include + #include #include #include @@ -48,6 +48,7 @@ #include #include #include +#include #include #include #ifdef FASTDDS_STATISTICS diff --git a/src/cpp/fastdds/subscriber/DataReaderImpl.cpp b/src/cpp/fastdds/subscriber/DataReaderImpl.cpp index b9233a7f039..c4185fa1921 100644 --- a/src/cpp/fastdds/subscriber/DataReaderImpl.cpp +++ b/src/cpp/fastdds/subscriber/DataReaderImpl.cpp @@ -38,7 +38,6 @@ #include #include #include -#include #include #include #include @@ -50,6 +49,7 @@ #include #include +#include #include #ifdef FASTDDS_STATISTICS #include diff --git a/src/cpp/rtps/builtin/discovery/participant/PDPServer.hpp b/src/cpp/rtps/builtin/discovery/participant/PDPServer.hpp index 3d54c147ef2..39536cf4c57 100644 --- a/src/cpp/rtps/builtin/discovery/participant/PDPServer.hpp +++ b/src/cpp/rtps/builtin/discovery/participant/PDPServer.hpp @@ -30,12 +30,11 @@ #include #include -#include - #include #include #include #include +#include namespace eprosima { namespace fastdds { diff --git a/src/cpp/rtps/builtin/discovery/participant/timedevent/DSClientEvent.cpp b/src/cpp/rtps/builtin/discovery/participant/timedevent/DSClientEvent.cpp index 007289a0bb5..f52d6d8d5b4 100644 --- a/src/cpp/rtps/builtin/discovery/participant/timedevent/DSClientEvent.cpp +++ b/src/cpp/rtps/builtin/discovery/participant/timedevent/DSClientEvent.cpp @@ -19,8 +19,6 @@ #include -#include - #include #include @@ -29,6 +27,7 @@ #include #include #include +#include #include namespace eprosima { diff --git a/src/cpp/rtps/builtin/discovery/participant/timedevent/DServerEvent.cpp b/src/cpp/rtps/builtin/discovery/participant/timedevent/DServerEvent.cpp index c0c77000077..284b2efad03 100644 --- a/src/cpp/rtps/builtin/discovery/participant/timedevent/DServerEvent.cpp +++ b/src/cpp/rtps/builtin/discovery/participant/timedevent/DServerEvent.cpp @@ -19,14 +19,13 @@ #include -#include - #include #include #include #include +#include namespace eprosima { namespace fastdds { diff --git a/src/cpp/rtps/builtin/liveliness/WLP.cpp b/src/cpp/rtps/builtin/liveliness/WLP.cpp index 123aa2f4dd2..a3e09f06aab 100644 --- a/src/cpp/rtps/builtin/liveliness/WLP.cpp +++ b/src/cpp/rtps/builtin/liveliness/WLP.cpp @@ -28,7 +28,6 @@ #include #include #include -#include #include #include @@ -39,6 +38,7 @@ #include #include #include +#include #include #include diff --git a/src/cpp/rtps/participant/RTPSParticipantImpl.h b/src/cpp/rtps/participant/RTPSParticipantImpl.h index b87ea3368e9..954561c42e5 100644 --- a/src/cpp/rtps/participant/RTPSParticipantImpl.h +++ b/src/cpp/rtps/participant/RTPSParticipantImpl.h @@ -43,7 +43,6 @@ #include #include #include -#include #include #include "../flowcontrol/FlowControllerFactory.hpp" @@ -52,6 +51,7 @@ #include #include #include +#include #include #include #include diff --git a/src/cpp/rtps/reader/RTPSReader.cpp b/src/cpp/rtps/reader/RTPSReader.cpp index 297feee6ef9..deb713a4a8f 100644 --- a/src/cpp/rtps/reader/RTPSReader.cpp +++ b/src/cpp/rtps/reader/RTPSReader.cpp @@ -16,29 +16,22 @@ * RTPSReader.cpp * */ +#include #include #include #include +#include +#include +#include +#include +#include #include #include - #include - #include - #include - -#include - -#include -#include -#include -#include - -#include - #include diff --git a/src/cpp/rtps/resources/ResourceEvent.cpp b/src/cpp/rtps/resources/ResourceEvent.cpp index 6957c2c1239..fe2aa99f635 100644 --- a/src/cpp/rtps/resources/ResourceEvent.cpp +++ b/src/cpp/rtps/resources/ResourceEvent.cpp @@ -16,9 +16,10 @@ * @file ResourceEvent.cpp */ +#include + #include -#include #include #include "TimedEventImpl.h" diff --git a/include/fastdds/rtps/resources/ResourceEvent.h b/src/cpp/rtps/resources/ResourceEvent.h similarity index 100% rename from include/fastdds/rtps/resources/ResourceEvent.h rename to src/cpp/rtps/resources/ResourceEvent.h diff --git a/src/cpp/rtps/resources/TimedEvent.cpp b/src/cpp/rtps/resources/TimedEvent.cpp index 5b83b1640ce..15e9f243cd5 100644 --- a/src/cpp/rtps/resources/TimedEvent.cpp +++ b/src/cpp/rtps/resources/TimedEvent.cpp @@ -18,7 +18,7 @@ */ #include -#include +#include #include "TimedEventImpl.h" diff --git a/src/cpp/rtps/writer/StatefulWriter.cpp b/src/cpp/rtps/writer/StatefulWriter.cpp index ec2b10342dc..81b62057073 100644 --- a/src/cpp/rtps/writer/StatefulWriter.cpp +++ b/src/cpp/rtps/writer/StatefulWriter.cpp @@ -30,7 +30,6 @@ #include #include #include -#include #include #include #include @@ -47,6 +46,7 @@ #include #include #include +#include #include #ifdef FASTDDS_STATISTICS diff --git a/test/mock/dds/DomainParticipantImpl/fastdds/domain/DomainParticipantImpl.hpp b/test/mock/dds/DomainParticipantImpl/fastdds/domain/DomainParticipantImpl.hpp index 0a8053e1a9c..888748df13a 100644 --- a/test/mock/dds/DomainParticipantImpl/fastdds/domain/DomainParticipantImpl.hpp +++ b/test/mock/dds/DomainParticipantImpl/fastdds/domain/DomainParticipantImpl.hpp @@ -42,13 +42,13 @@ #include #include #include -#include #include #include #include #include #include +#include #include namespace eprosima { diff --git a/test/mock/rtps/RTPSParticipant/fastdds/rtps/participant/RTPSParticipant.h b/test/mock/rtps/RTPSParticipant/fastdds/rtps/participant/RTPSParticipant.h index 0ea712ba9c5..e5583cf6e58 100644 --- a/test/mock/rtps/RTPSParticipant/fastdds/rtps/participant/RTPSParticipant.h +++ b/test/mock/rtps/RTPSParticipant/fastdds/rtps/participant/RTPSParticipant.h @@ -27,9 +27,9 @@ #include #include #include -#include #include +#include #include namespace eprosima { diff --git a/test/mock/rtps/RTPSParticipantImpl/rtps/participant/RTPSParticipantImpl.h b/test/mock/rtps/RTPSParticipantImpl/rtps/participant/RTPSParticipantImpl.h index f9ec06ee23a..ec5933e2d4b 100644 --- a/test/mock/rtps/RTPSParticipantImpl/rtps/participant/RTPSParticipantImpl.h +++ b/test/mock/rtps/RTPSParticipantImpl/rtps/participant/RTPSParticipantImpl.h @@ -31,10 +31,10 @@ #include #include #include -#include #include #include +#include #if HAVE_SECURITY #include #endif // if HAVE_SECURITY diff --git a/test/mock/rtps/ResourceEvent/fastdds/rtps/resources/ResourceEvent.h b/test/mock/rtps/ResourceEvent/rtps/resources/ResourceEvent.h similarity index 100% rename from test/mock/rtps/ResourceEvent/fastdds/rtps/resources/ResourceEvent.h rename to test/mock/rtps/ResourceEvent/rtps/resources/ResourceEvent.h diff --git a/test/mock/rtps/StatefulReader/fastdds/rtps/reader/StatefulReader.h b/test/mock/rtps/StatefulReader/fastdds/rtps/reader/StatefulReader.h index 20e92cdb030..2ff5f346e4d 100644 --- a/test/mock/rtps/StatefulReader/fastdds/rtps/reader/StatefulReader.h +++ b/test/mock/rtps/StatefulReader/fastdds/rtps/reader/StatefulReader.h @@ -18,7 +18,7 @@ #include #include #include -#include +#include namespace eprosima { namespace fastrtps { diff --git a/test/unittest/rtps/reader/WriterProxyStopTest.cpp b/test/unittest/rtps/reader/WriterProxyStopTest.cpp index 038382f0894..d7c5b35a098 100644 --- a/test/unittest/rtps/reader/WriterProxyStopTest.cpp +++ b/test/unittest/rtps/reader/WriterProxyStopTest.cpp @@ -20,13 +20,13 @@ #include #include #include -#include #include #include #include - #include +#include + namespace testing { namespace internal { diff --git a/test/unittest/rtps/resources/timedevent/TimedEventTests.cpp b/test/unittest/rtps/resources/timedevent/TimedEventTests.cpp index 62e11d28994..6c4c62506b6 100644 --- a/test/unittest/rtps/resources/timedevent/TimedEventTests.cpp +++ b/test/unittest/rtps/resources/timedevent/TimedEventTests.cpp @@ -17,7 +17,7 @@ #include -#include +#include #include "mock/MockEvent.h" diff --git a/test/unittest/rtps/writer/LivelinessManagerTests.cpp b/test/unittest/rtps/writer/LivelinessManagerTests.cpp index 05d2829fd16..442ed485e5c 100644 --- a/test/unittest/rtps/writer/LivelinessManagerTests.cpp +++ b/test/unittest/rtps/writer/LivelinessManagerTests.cpp @@ -21,8 +21,7 @@ #include #include -#include - +#include #include class LivelinessManagerTests : public ::testing::Test diff --git a/test/unittest/statistics/rtps/MonitorServiceTests.cpp b/test/unittest/statistics/rtps/MonitorServiceTests.cpp index bb35df72573..06b895ed3e4 100644 --- a/test/unittest/statistics/rtps/MonitorServiceTests.cpp +++ b/test/unittest/statistics/rtps/MonitorServiceTests.cpp @@ -17,7 +17,7 @@ #include #include -#include +#include #include #include