19 #ifndef INCLUDE_RCF_OVERLAPPEDAMI_HPP
20 #define INCLUDE_RCF_OVERLAPPEDAMI_HPP
22 #include <boost/function.hpp>
23 #include <boost/shared_ptr.hpp>
25 #include <RCF/Asio.hpp>
26 #include <RCF/Enums.hpp>
27 #include <RCF/ThreadLibrary.hpp>
31 class RCF_EXPORT AmiNotification
35 typedef boost::function0<void> Cb;
38 void set(Cb cb, LockPtr lockPtr, MutexPtr mutexPtr);
50 typedef boost::shared_ptr<OverlappedAmi> OverlappedAmiPtr;
52 class ConnectedClientTransport;
55 public boost::enable_shared_from_this<OverlappedAmi>
59 OverlappedAmi(ConnectedClientTransport *pTcpClientTransport) :
60 mpTransport(pTcpClientTransport),
72 const AsioErrorCode & ec,
73 std::size_t bytesTransferred);
77 const AsioErrorCode & ec);
79 void ensureLifetime(
const ByteBuffer & byteBuffer);
80 void ensureLifetime(
const std::vector<ByteBuffer> & byteBuffers);
84 RecursiveMutex mMutex;
85 ConnectedClientTransport * mpTransport;
93 std::vector<ByteBuffer> mByteBuffers;
98 #endif // ! INCLUDE_RCF_OVERLAPPEDAMI_HPP