fwd.hpp 964 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. #ifndef ENTT_SIGNAL_FWD_HPP
  2. #define ENTT_SIGNAL_FWD_HPP
  3. #include <memory>
  4. namespace entt {
  5. template<typename>
  6. class delegate;
  7. template<typename = std::allocator<void>>
  8. class basic_dispatcher;
  9. template<typename, typename = std::allocator<void>>
  10. class emitter;
  11. class connection;
  12. struct scoped_connection;
  13. template<typename>
  14. class sink;
  15. template<typename Type, typename = std::allocator<void>>
  16. class sigh;
  17. /*! @brief Alias declaration for the most common use case. */
  18. using dispatcher = basic_dispatcher<>;
  19. /*! @brief Disambiguation tag for constructors and the like. */
  20. template<auto>
  21. struct connect_arg_t {
  22. /*! @brief Default constructor. */
  23. explicit connect_arg_t() = default;
  24. };
  25. /**
  26. * @brief Constant of type connect_arg_t used to disambiguate calls.
  27. * @tparam Candidate Element to connect (likely a free or member function).
  28. */
  29. template<auto Candidate>
  30. inline constexpr connect_arg_t<Candidate> connect_arg{};
  31. } // namespace entt
  32. #endif