Browse Prior Art Database

Asynchronous Software Communication Using Response Objects

IP.com Disclosure Number: IPCOM000111251D
Original Publication Date: 1994-Feb-01
Included in the Prior Art Database: 2005-Mar-26
Document File: 2 page(s) / 54K

Publishing Venue

IBM

Related People

Dietel, JD: AUTHOR [+3]

Abstract

Disclosed is a method to decouple asynchronous communication between software objects using an intermediate response object.

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 66% of the total text.

Asynchronous Software Communication Using Response Objects

      Disclosed is a method to decouple asynchronous communication
between software objects using an intermediate response object.

      Asynchronous communication between program entities (tasks,
threads, objects, others) is a common requirement.  Consider a
client-server relationship in which the client wishes to invoke some
function on the server and be notified asynchronously when the
function has completed.  The server must have some knowledge of, or
interface to, the client in order to carry out the function-complete
notification.  This knowledge introduces undesirable coupling from
the server to the client.  The penalty for this coupling is paid when
another client arises that wishes to use some other kind of
function-complete notification, but is locked into the kind chosen by
the first client.

      The solution to the coupling problem is easily implemented in
an object-oriented environment that provides inheritance and
polymorphism, and so will be described using OO terminology.

      Request/Response Scenario - A new abstract base class called
Response is introduced, having one pure virtual method called
whenDone.  Each client provides a derived Response class, overriding
the whenDone method to do whatever it wants.  The client passes a
derived Response object to the server when invoking the function.
When the server completes the function, it just calls the whenDone
function on t...