[progress Communities] [progress Openedge Abl] Forum Post: Re: Immutable Objects

  • Thread starter Thread starter Peter Judge
  • Start date Start date
Status
Not open for further replies.
P

Peter Judge

Guest
Maybe I should state the requirement slightly differently. The registry – and only the registry – should hold the canonical data. To change the registry, a set of Put() and Remove() methods are provided. A caller can retrieve the service data via Get() methods. The caller will receive a Service() object. If changes are made to the object returned, the changes must not affect the registry data. Immutable objects are one way to prevent changes by the caller. Cloned objects are another, although this presents its own set of challenges (deep clones). For instance, a service has a version. Changing the version (object ref) on the service should not change the version in the registry.

Continue reading...
 
Status
Not open for further replies.
Back
Top