20.02.2013 Views

Connie's Convenience Store - About Peter Coad

Connie's Convenience Store - About Peter Coad

Connie's Convenience Store - About Peter Coad

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

82 Connie’s <strong>Convenience</strong> <strong>Store</strong> Selecting System-Interaction Objects<br />

Interaction within this system<br />

A point-of-sale application is a very likely candidate for a client-server architecture.<br />

However, do not build separate object models for the client and the server. Why? The<br />

models will be exactly the same—almost. And that’s a waste of time and energy. Instead,<br />

you are far better off building one object model.<br />

You might encounter a variety of client-server environments, including:<br />

– object environments on client and server, with object communications<br />

support (ORB, SOM/DSOM, ODBMS)<br />

– object environments on client and server, with nonobject communications<br />

support<br />

– object environment on the client but not the server.<br />

If you find that you must deal with a transition to nonobject technology (which is<br />

often the case), here’s the basic approach to follow:<br />

– allocate objects to the client or server<br />

– decide which services will be allowed to run on which platform<br />

– add both client and server objects, for translating in and out of your object<br />

technology.<br />

If you have object-oriented environments on both client and server and your implementation<br />

environment supports an ORB, or you are using an object-oriented database<br />

that supports a client-server model, great news: you will not have to make any changes<br />

to your model, except minor changes to match any specific requirements of the environment<br />

you are using.<br />

If you have object-oriented environments on both the client and the server, but there<br />

is no object communications support between them, then you need to add a “server” object<br />

for the client side, and a “client” object for the server side. These objects provide<br />

the transitions across the non-object communications boundaries. You need to decide<br />

which objects reside on each side of the boundary. You also need to define the client<br />

and server objects, to provide a communications link, one that routes messages between<br />

objects on different platforms.<br />

If you have an object-oriented environment on the client and a relational database<br />

on the server, then use DM objects to provide the mapping and boundary to the nonobject<br />

oriented server.<br />

Use an object-modeling tool with view management, working out what’s needed on<br />

each processor.<br />

For this point-of-sale application, you get to take it easy (after all, this chapter<br />

needs to end at some point). Here’s what you have to work with:<br />

– an object-oriented environment on both the client and server<br />

– access to an object-oriented communications mechanism.<br />

Piece of cake!<br />

No client object is needed here. No server object is needed here.<br />

Move ahead and establish responsibilities for authorization system.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!