Skip to content

Commit 0d2438d

Browse files
authored
[EGD-3852] clean include in service (#928)
1 parent 82341fb commit 0d2438d

File tree

145 files changed

+1738
-732
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

145 files changed

+1738
-732
lines changed

module-services/service-antenna/ServiceAntenna.cpp

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,24 @@
22
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md
33

44
#include "ServiceAntenna.hpp"
5-
#include "Service/Timer.hpp"
6-
#include "api/AntennaServiceAPI.hpp"
7-
#include "log/log.hpp"
8-
#include "messages/AntennaMessage.hpp"
9-
#include "service-appmgr/ApplicationManager.hpp"
10-
#include <at/response.hpp>
11-
#include <memory>
12-
#include <module-utils/state/ServiceState.hpp>
13-
#include <service-cellular/messages/CellularMessage.hpp>
14-
15-
#include "service-cellular/api/CellularServiceAPI.hpp"
16-
#include "time/time_conversion.hpp"
17-
#include <ticks.hpp>
18-
19-
#include <cassert>
5+
6+
#include <at/response.hpp> // for parseCSQ, isRegistered, parseCREG, parseNetworkFrequency, parseQNWINFO
7+
#include <module-utils/state/ServiceState.hpp> // for State
8+
#include <service-cellular/messages/CellularMessage.hpp> // for CellularNotificationMessage, StateChange, CellularCallMessage, CellularNotificationMessage::Type, CellularNotificationMessage::Type::CallAborted
9+
#include <ticks.hpp> // for Ticks
10+
#include <memory> // for make_shared, unique_ptr, allocator, make_unique
11+
#include <algorithm> // for max
12+
#include <string> // for string
13+
#include <vector> // for vector
14+
15+
#include "Service/Timer.hpp" // for Timer
16+
#include "api/AntennaServiceAPI.hpp" // for LockRequest
17+
#include "log/log.hpp" // for LOG_INFO, LOG_WARN, LOG_FATAL
18+
#include "messages/AntennaMessage.hpp" // for AntennaLockRequestResponse, AntennaLockRequestMessage
19+
#include "service-cellular/api/CellularServiceAPI.hpp" // for GetCSQ, GetAntenna, SelectAntenna, GetCREG, GetQNWINFO
20+
#include "MessageType.hpp" // for MessageType, MessageType::AntennaCSQChange, MessageType::AntennaChanged, MessageType::AntennaGetLockState, MessageType::AntennaLockService, MessageType::CellularCall, MessageType::CellularNotification, MessageType::CellularStateRequest, MessageType::StateChange
21+
#include "projdefs.h" // for pdMS_TO_TICKS
22+
#include "service-cellular/State.hpp" // for State, State::ST, State::ST::Ready
2023

2124
const char *ServiceAntenna::serviceName = "ServiceAntenna";
2225

module-services/service-antenna/ServiceAntenna.hpp

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,30 @@
33

44
#pragma once
55

6+
#include <module-utils/state/ServiceState.hpp>
7+
#include <stdint.h> // for uint32_t
68
#include <algorithm>
79
#include <cassert>
10+
#include <memory> // for unique_ptr
811

9-
#include "Service/Service.hpp"
10-
#include "Service/Message.hpp"
12+
#include "Service/Service.hpp" // for Service
13+
#include "Service/Message.hpp" // for Message_t, DataMessage (ptr only), ResponseMessage (ptr only)
1114
#include "Service/Worker.hpp"
1215
#include "MessageType.hpp"
16+
#include "bsp/cellular/bsp_cellular.hpp" // for antenna
17+
#include "Service/Common.hpp" // for ReturnCodes, ServicePowerMode
1318

14-
#include <module-utils/state/ServiceState.hpp>
15-
16-
#include "bsp/cellular/bsp_cellular.hpp"
19+
namespace sys
20+
{
21+
class Timer;
22+
} // namespace sys
23+
namespace utils
24+
{
25+
namespace state
26+
{
27+
template <typename T> class State;
28+
} // namespace state
29+
} // namespace utils
1730

1831
namespace antenna
1932
{

module-services/service-antenna/api/AntennaServiceAPI.cpp

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,22 @@
22
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md
33

44
#include "AntennaServiceAPI.hpp"
5-
#include "../messages/AntennaMessage.hpp"
5+
6+
#include <memory> // for make_shared, allocator, shared_ptr, __shared_ptr<>::element_type
7+
#include <utility> // for pair
8+
9+
#include "../messages/AntennaMessage.hpp" // for AntennaLockRequestMessage, AntennaLockRequestResponse
10+
#include "MessageType.hpp" // for MessageType, MessageType::AntennaCSQChange, MessageType::AntennaGetLockState, MessageType::AntennaLockService
11+
#include "Service/Bus.hpp" // for Bus
12+
#include "Service/Common.hpp" // for ReturnCodes, ReturnCodes::Success, BusChannels, BusChannels::AntennaNotifications
13+
#include "Service/Message.hpp" // for DataMessage
14+
#include "service-antenna/ServiceAntenna.hpp" // for ServiceAntenna, ServiceAntenna::serviceName, lockState
15+
16+
namespace sys
17+
{
18+
class Service;
19+
} // namespace sys
20+
621
namespace AntennaServiceAPI
722
{
823

module-services/service-antenna/api/AntennaServiceAPI.hpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,12 @@
66
#include <MessageType.hpp>
77
#include <Service/Message.hpp>
88

9-
#include "../ServiceAntenna.hpp"
9+
#include "../ServiceAntenna.hpp" // for lockState
10+
11+
namespace sys
12+
{
13+
class Service;
14+
} // namespace sys
1015

1116
namespace AntennaServiceAPI
1217
{

module-services/service-appmgr/ApplicationManager.cpp

Lines changed: 21 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,28 @@
22
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md
33

44
#include "service-appmgr/ApplicationManager.hpp"
5-
#include "service-appmgr/Controller.hpp"
65

7-
#include <utility>
8-
#include <module-apps/application-desktop/data/LockPhoneData.hpp>
9-
10-
#include "application-call/ApplicationCall.hpp"
11-
#include "application-special-input/ApplicationSpecialInput.hpp"
12-
13-
#include "Service/Message.hpp"
14-
#include "AppMessage.hpp"
15-
16-
#include "Service/Timer.hpp"
17-
#include "service-db/api/DBServiceAPI.hpp"
18-
#include "service-evtmgr/EventManager.hpp"
19-
#include "service-eink/ServiceEink.hpp"
20-
#include "service-gui/ServiceGUI.hpp"
21-
22-
#include "log/log.hpp"
6+
#include <utility> // for move
7+
#include <algorithm> // for find_if
8+
#include <limits> // for numeric_limits
9+
10+
#include "service-appmgr/Controller.hpp" // for Controller
11+
#include "application-call/ApplicationCall.hpp" // for name_call
12+
#include "application-special-input/ApplicationSpecialInput.hpp" // for special_input
13+
#include "Service/Message.hpp" // for ResponseMessage, DataMessage (ptr only), Message_t
14+
#include "AppMessage.hpp" // for AppSwitchWindowMessage
15+
#include "Service/Timer.hpp" // for Timer, Timer::Type, Timer::Type::SingleShot, ms
16+
#include "service-db/api/DBServiceAPI.hpp" // for DBServiceAPI
17+
#include "service-evtmgr/EventManager.hpp" // for EventManager
18+
#include "service-eink/ServiceEink.hpp" // for ServiceEink
19+
#include "service-gui/ServiceGUI.hpp" // for ServiceGUI
20+
#include "log/log.hpp" // for LOG_INFO, LOG_ERROR, LOG_WARN, LOG_DEBUG, LOG_FATAL
21+
#include "Common.hpp" // for ShowMode, ShowMode::GUI_SHOW_INIT
22+
#include "Common/Common.hpp" // for SettingsLanguage, SettingsLanguage::ENGLISH, SettingsLanguage::GERMAN, SettingsLanguage::POLISH, SettingsLanguage::SPANISH
23+
#include "Service/Bus.hpp" // for Bus
24+
#include "SystemManager/SystemManager.hpp" // for SystemManager
25+
#include "i18/i18.hpp" // for Lang, Lang::En, Lang::De, Lang::Pl, Lang::Sp, i18, localize
26+
#include "service-appmgr/messages/APMMessage.hpp" // for APMCheckApp, APMSwitch, APMRegister, APMConfirmClose, APMConfirmSwitch, Action, APMAction, APMChangeLanguage, APMSwitchPrevApp, APMDelayedClose, APMClose, APMInitPowerSaveMode, APMPreventBlocking
2327

2428
// Auto phone lock disabled for now till the times when it's debugged
2529
// #define AUTO_PHONE_LOCK_ENABLED

module-services/service-appmgr/ApplicationManager.hpp

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,16 +3,35 @@
33

44
#pragma once
55

6-
#include <memory>
7-
#include <string>
8-
9-
#include "Application.hpp"
10-
#include "ApplicationLauncher.hpp"
6+
#include <memory> // for unique_ptr, allocator
7+
#include <string> // for string
8+
#include <deque> // for deque
9+
#include <string_view> // for string_view
10+
#include <vector> // for vector
11+
12+
#include "Application.hpp" // for Application, Application::State
13+
#include "ApplicationLauncher.hpp" // for ApplicationLauncher
1114
#include "messages/APMMessage.hpp"
15+
#include "Service/Common.hpp" // for ReturnCodes, ServicePowerMode
16+
#include "Service/Message.hpp" // for Message_t, DataMessage (ptr only), ResponseMessage (ptr only)
17+
#include "Service/Service.hpp" // for Service
18+
#include "Service/Timer.hpp" // for Timer
19+
#include "SettingsRecord.hpp" // for SettingsRecord
20+
#include "SwitchData.hpp" // for SwitchData
1221

1322
namespace app
1423
{
1524
class ApplicationLauncher;
25+
namespace manager
26+
{
27+
class APMAction;
28+
class APMChangeLanguage;
29+
class APMConfirmClose;
30+
class APMConfirmSwitch;
31+
class APMRegister;
32+
class APMSwitch;
33+
class APMSwitchPrevApp;
34+
} // namespace manager
1635
}
1736

1837
namespace app::manager

module-services/service-appmgr/Controller.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,11 @@
33

44
#include "Controller.hpp"
55

6-
#include "module-sys/Service/Bus.hpp"
6+
#include <utility> // for move
7+
8+
#include "module-sys/Service/Bus.hpp" // for Bus
9+
#include "Service/Service.hpp" // for Service
10+
#include "service-appmgr/ApplicationManager.hpp" // for ApplicationManager, ApplicationManager::ServiceName, ApplicationHandle, ApplicationHandle::Name
711

812
namespace app::manager
913
{

module-services/service-appmgr/Controller.hpp

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,19 @@
33

44
#pragma once
55

6-
#include "ApplicationManager.hpp"
6+
#include <memory> // for unique_ptr
7+
#include <string> // for string
78

9+
#include "ApplicationManager.hpp" // for ApplicationHandle, ApplicationHandle::Name
810
#include "module-sys/Service/Service.hpp"
11+
#include "SwitchData.hpp" // for SwitchData
12+
#include "i18/i18.hpp" // for Lang
13+
#include "service-appmgr/messages/APMMessage.hpp" // for APMSwitchPrevApp, Action (ptr only)
14+
15+
namespace sys
16+
{
17+
class Service;
18+
} // namespace sys
919

1020
namespace app::manager
1121
{

module-services/service-audio/api/AudioServiceAPI.cpp

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,20 @@
22
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md
33

44
#include "AudioServiceAPI.hpp"
5-
#include "Service/Bus.hpp"
6-
#include "../ServiceAudio.hpp"
5+
6+
#include <utility> // for move, pair
7+
8+
#include "Service/Bus.hpp" // for Bus, defaultCmdTimeout
9+
#include "../ServiceAudio.hpp" // for ServiceAudio, ServiceAudio::serviceName
10+
#include "Audio/decoder/decoder.hpp" // for Tags
11+
#include "Service/Common.hpp" // for ReturnCodes, ReturnCodes::Success
12+
#include "log/log.hpp" // for LOG_DEBUG, LOG_ERROR
13+
#include "service-audio/messages/AudioMessage.hpp" // for AudioStopRequest, AudioResponseMessage, AudioEventRequest, AudioGetFileTagsRequest, AudioGetSetting, AudioKeyPressedRequest, AudioPauseRequest, AudioResumeRequest, AudioStartPlaybackRequest, AudioStartRecorderRequest, AudioStartRoutingRequest, AudioMessage, AudioSetSetting (ptr only)
14+
15+
namespace sys
16+
{
17+
class Service;
18+
} // namespace sys
719

820
using namespace audio;
921
namespace AudioServiceAPI

module-services/service-audio/api/AudioServiceAPI.hpp

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,25 @@
33

44
#pragma once
55

6+
#include <optional> // for optional
7+
#include <memory> // for shared_ptr
8+
#include <string> // for string
9+
#include <vector> // for vector
10+
611
#include "../messages/AudioMessage.hpp"
712
#include "Audio/decoder/decoder.hpp"
8-
9-
#include <optional>
13+
#include "Audio/AudioCommon.hpp" // for PlaybackType, PlaybackType::None, Token (ptr only), RetCode, Setting, Event (ptr only), EventType
14+
#include "Audio/Profiles/Profile.hpp" // for Profile, Profile::Type, Profile::Type::Idle
1015

1116
class Service;
17+
namespace audio
18+
{
19+
struct Tags;
20+
} // namespace audio
21+
namespace sys
22+
{
23+
class Service;
24+
} // namespace sys
1225

1326
/**
1427
* Audio service API.

0 commit comments

Comments
 (0)