Two approaches for separating clients from servers in a simple application based on a table lamp.
Category: Client-Server
Summary: Two approaches for separating clients from servers in a simple application based on a table lamp.
Manage dependencies between clients and servers by defining an abstract class whose implementers interact with specific servers.
Break dependencies between clients and servers by defining an abstract class referenced by the client with the server implementing the abstract class.
Break dependencies between clients and servers by defining an abstract server class referenced by the client. A server is derived from the abstract server class that contains the actual server.