X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/4bb73cb3914b5f7b77a9ec1f8abe728e637cc016..4a13db94f50023e3e9ad850b936b69b5f85b7fb7:/include/simgrid/s4u/Comm.hpp diff --git a/include/simgrid/s4u/Comm.hpp b/include/simgrid/s4u/Comm.hpp index 36a4308b44..35d601a448 100644 --- a/include/simgrid/s4u/Comm.hpp +++ b/include/simgrid/s4u/Comm.hpp @@ -6,13 +6,16 @@ #ifndef SIMGRID_S4U_COMM_HPP #define SIMGRID_S4U_COMM_HPP +#include #include +#include #include #include -#include // DEPRECATED 3.20 #include +#include +#include #include namespace simgrid { @@ -21,8 +24,7 @@ namespace s4u { * * Represents all asynchronous communications, that you can test or wait onto. */ -XBT_PUBLIC_CLASS Comm : public Activity -{ +class XBT_PUBLIC Comm : public Activity { Comm() : Activity() {} public: friend XBT_PUBLIC void intrusive_ptr_release(simgrid::s4u::Comm * c); @@ -42,9 +44,9 @@ public: intrusive_ptr_release(*(simgrid::kernel::activity::ActivityImpl**)ptr); }); for (auto const& comm : *comms_in) { - if (comm->state_ == inited) + if (comm->state_ == Activity::State::inited) comm->start(); - xbt_assert(comm->state_ == started); + xbt_assert(comm->state_ == Activity::State::started); simgrid::kernel::activity::ActivityImpl* ptr = comm->pimpl_.get(); intrusive_ptr_add_ref(ptr); xbt_dynar_push_as(comms, simgrid::kernel::activity::ActivityImpl*, ptr); @@ -67,37 +69,6 @@ public: /*! take a vector s4u::CommPtr and return the rank of the first finished one (or -1 if none is done). */ static int test_any(std::vector * comms); - /** Creates (but don't start) an async send to the mailbox @p dest */ - XBT_ATTRIB_DEPRECATED_v320("Use Mailbox::put_init(): v3.20 will turn this warning into an error.") static CommPtr - send_init(MailboxPtr dest) - { - return dest->put_init(); - } - /** Creates (but don't start) an async send to the mailbox @p dest */ - XBT_ATTRIB_DEPRECATED_v320("Use Mailbox::put_init(): v3.20 will turn this warning into an error.") static CommPtr - send_init(MailboxPtr dest, void* data, int simulatedByteAmount) - { - return dest->put_init(data, simulatedByteAmount); - } - /** Creates and start an async send to the mailbox @p dest */ - XBT_ATTRIB_DEPRECATED_v320("Use Mailbox::put_async(): v3.20 will turn this warning into an error.") static CommPtr - send_async(MailboxPtr dest, void* data, int simulatedByteAmount) - { - return dest->put_async(data, simulatedByteAmount); - } - /** Creates (but don't start) an async recv onto the mailbox @p from */ - XBT_ATTRIB_DEPRECATED_v320("Use Mailbox::get_init(): v3.20 will turn this warning into an error.") static CommPtr - recv_init(MailboxPtr from) - { - return from->get_init(); - } - /** Creates and start an async recv to the mailbox @p from */ - XBT_ATTRIB_DEPRECATED_v320("Use Mailbox::get_async(): v3.20 will turn this warning into an error.") static CommPtr - recv_async(MailboxPtr from, void** data) - { - return from->get_async(data); - } - Activity* start() override; Activity* wait() override; Activity* wait(double timeout) override;