17 #ifndef GZ_MSGS_MESSAGE_FACTORY_HH_
18 #define GZ_MSGS_MESSAGE_FACTORY_HH_
26 #include "gz/msgs/config.hh"
27 #include "gz/msgs/Export.hh"
28 #include "gz/msgs/detail/dynamic_message_cast.hh"
29 #include <gz/utils/ImplPtr.hh>
36 inline namespace GZ_MSGS_VERSION_NAMESPACE {
46 public:
using Message = google::protobuf::Message;
72 public:
template<
typename T>
75 return detail::dynamic_message_cast<T>(New(_msgType));
83 public:
template<
typename T>
87 return detail::dynamic_message_cast<T>(New(_msgType, _args));
117 GZ_UTILS_UNIQUE_IMPL_PTR_FWD(gz::msgs::DynamicFactory, dynamicFactory)