-
- void SetFlags(wxSockFlags _flags);
- wxSockFlags GetFlags() const;
- inline void SetTimeout(unsigned long sec) { m_timeout = sec; }
-
- // seconds = -1 means infinite wait
- // seconds = 0 means no wait
- // seconds > 0 means specified wait
- bool Wait(long seconds = -1, long microseconds = 0);
- bool WaitForRead(long seconds = -1, long microseconds = 0);
- bool WaitForWrite(long seconds = -1, long microseconds = 0);
- bool WaitForLost(long seconds = -1, long microseconds = 0);
-
+
+ // Addresses
+ virtual bool GetPeer(wxSockAddress& addr_man) const;
+ virtual bool GetLocal(wxSockAddress& addr_man) const;
+
+ // Set attributes and flags
+ void SetTimeout(long seconds);
+ void SetFlags(wxSockFlags flags);
+ inline wxSockFlags GetFlags() const { return m_flags; };
+
+ /* Wait functions
+ * seconds = -1 means default timeout (change with SetTimeout)
+ * seconds, milliseconds = 0 means no wait
+ * seconds, milliseconds > 0 means specified wait
+ */
+ bool Wait(long seconds = -1, long milliseconds = 0);
+ bool WaitForRead(long seconds = -1, long milliseconds = 0);
+ bool WaitForWrite(long seconds = -1, long milliseconds = 0);
+ bool WaitForLost(long seconds = -1, long milliseconds = 0);
+
+ /* This function interrupts all ongoing wait operations for this
+ * socket; use it only as an escape mechanism (for example to close
+ * an app or to abort an operation). Reception of LOST events and
+ * calls to Close() automatically call this.
+ */
+ void InterruptAllWaits() { m_interrupt = TRUE; };
+