virtual DNA_Point *GetDestination(void) const
Return the destination of the connection.
virtual long Compare(const DNA_BusImp *imp) const
Return 0 if the implementation and imp are identical.
virtual void SetDestination(DNA_Point *p)
Set the destination of the connection to p. Note that this may be
a pointer to an object of any class derived from DNA_IPPoint.
virtual void SetBackLog(const unsigned long b)
Set the size of the queue of waiting connections to be b. The
first call to Accept() calls
SetBackLog(DNA_DEFAULT_TCP_BACK_LOG) if SetBackLog() has
not been called previously. This method should not be invoked until
after the socket has been bound.
virtual void Reset(void)
Reset the implementation to an initialized state.
virtual GPL_Boolean Accept(DNA_ConnectionImp *i, DNA_Error & error)
Accept, from another peer which has called Connect(), an entirely
new connection, i. The connection must be valid, open, and bound
for this method to succeed. Return TRUE if the acceptance
succeeded and FALSE if it failed. Upon return, error
contains any errors.
virtual GPL_Boolean Connect(DNA_Error & error)
Connect to another peer. The connection must be valid, open, bound,
and connected for this method to succeed. Return TRUE if the
connection succeeded and FALSE if it failed. Upon return,
error contains any errors.
virtual GPL_Boolean Disconnect(DNA_Error & error)
Disconnect from another peer. The connection must be valid, open,
bound, and connected for this method to succeed. Return TRUE if
the disconnect succeeded and FALSE if it failed. Upon return,
error contains any errors.
virtual GPL_Boolean Open(DNA_Error & error)
Open the connection. Turns off blocking I/O and message buffering and
turns on address reuse. Return TRUE if the opening succeeded and
FALSE if it failed. Upon return, error contains any errors.
virtual GPL_Boolean Bind(DNA_Point *point, DNA_Error & error)
Perform the binding between the source, specified by point, and the
destination, previously specified with SetDestination(). Return
TRUE if the binding succeeded and FALSE if it failed. Upon
return, error contains any errors.
virtual GPL_Boolean Close(DNA_Error & error)
Close the connection. Return TRUE if the closing succeeded and
FALSE if it failed. Upon return, error contains any errors.
virtual GPL_Boolean Read(void *buffer, const unsigned long size, unsigned long & length)
Read size bytes from the message connection into buffer. Upon
return, length contains the actual number of bytes read. Return
TRUE if the read succeeds, FALSE if the read fails.
virtual GPL_Boolean Read(void *buffer, const unsigned long size,
const long timeout, unsigned long & length)
Read size bytes from
the message connection into buffer, waiting at least timeout
milliseconds for the data to be available. Upon return, length
contains the actual number of bytes read. Return TRUE if the
read succeeds, FALSE if the read fails. If no data arrives
before the timeout, FALSE is returned and the value of
error.type is DNA_ERROR_NO_DATA_AVAILABLE.
virtual GPL_Boolean Write(void *buffer, const unsigned long size, unsigned long & length)
Write size bytes from buffer onto the message connection. Upon
return, length contains the actual number of bytes written. Return
TRUE if the read succeeds, FALSE if the read fails.