RemoteToolsJoinThread.h 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. /*
  2. * Copyright (c) Contributors to the Open 3D Engine Project.
  3. * For complete copyright and license terms please see the LICENSE at the root of this distribution.
  4. *
  5. * SPDX-License-Identifier: Apache-2.0 OR MIT
  6. *
  7. */
  8. #pragma once
  9. #include <AzNetworking/Utilities/TimedThread.h>
  10. namespace AZ
  11. {
  12. class Name;
  13. }
  14. namespace RemoteTools
  15. {
  16. class RemoteToolsSystemComponent;
  17. //! @class ToolingJoinThread
  18. //! @brief A class for polling a connection to the host target
  19. class RemoteToolsJoinThread final : public AzNetworking::TimedThread
  20. {
  21. public:
  22. RemoteToolsJoinThread(int updateRate, RemoteToolsSystemComponent* component);
  23. ~RemoteToolsJoinThread() override;
  24. private:
  25. AZ_DISABLE_COPY_MOVE(RemoteToolsJoinThread);
  26. //! Invoked on thread start
  27. void OnStart() override{}
  28. //! Invoked on thread stop
  29. void OnStop() override{}
  30. //! Invoked on thread update to poll for a target host to join
  31. //! @param updateRateMs The amount of time the thread can spend in OnUpdate in ms
  32. void OnUpdate(AZ::TimeMs updateRateMs) override;
  33. RemoteToolsSystemComponent* m_remoteToolsComponent;
  34. };
  35. } // namespace RemoteTools