The mutability of the underlying constructs have nothing to do with the
mutability of the connection itself. For example, sending a message does
not change the connection itself, just the underlying OS primitives. To
fix this, wrap the members of Connection in RefCell to hide this
behavior.
Also, sending a message takes the ownership of the message.
The mutability of the underlying constructs have nothing to do with the mutability of the connection itself. For example, sending a message does not change the connection itself, just the underlying OS primitives. To fix this, wrap the members of Connection in RefCell to hide this behavior.
Also, sending a message takes the ownership of the message.