Example: Writing a persistent object server

This section shows an example of how to provide a server class implementation for persistent SOM objects. (The Persistence Framework of the full-capability SOMobjects Developer Toolkit can be used to write a persistent object s erver; an example of that type is given in the SOMobjects Developer Toolkit Users Guide.) All of the persistent object management is contained in the server class; this class can be used with the DSOM "generic" server program, somdsvr.

The following example describes a user-supplied server class "MyPServer" that is derived from SOMDServer. The "MyPServer" class introduces five new methods:

and overrides four SOMDServer methods: