Chapter Contents

Previous

Next
Object Class: _onContentsUpdated

Object Class: _onContentsUpdated



Virtual method for 'contents changed' event handler


Syntax
Details

Syntax

objectName._onContentsUpdated( attributeName );

Argument Type Use Description
attributeName Character Input Name of attribute whose value changed to cause the event


Details

This virtual method is used in model/view component communication. Using the Object Class: contentsUpdatedAttributes attribute, a model can list one or more attributes that are considered "critical," which means that if any of those attribute values change, the attached viewer should be notified. When an attribute value is changed, the _setAttributeValue method

  1. determines whether the attribute is stored in the contentUpdatedAttributes list

  2. determines whether there is a model attached to the view

  3. and, if both conditions are true, sends the 'contents updated' event.

The viewer's event handler listens for the 'contents updated' event and runs its _onContentsUpdated method.

When you design a viewer to work with a model, you can override this method and add the functionality that updates the viewer.


Chapter Contents

Previous

Next

Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.