Added a write shortcut for tcp and sctp endpoints