VkModel(3x)
VkModel - An abstract class that supports Model-View-Controller style applications
As shipped in IRIX 6.5.19. Unchanged since IRIX 6.5.
NAME VkModel - An abstract class that supports Model-View-Controller style applications INHERITS FROM VkCallbackObject HEADER FILE #include <Vk/VkModel.h> PUBLIC PROTOCOL SUMMARY Destructor virtual void ~VkModel(void); PROTECTED PROTOCOL SUMMARY Constructor VkModel(void); Notifying Views of Changes void updateViews(void *data); CLASS DESCRIPTION The VkModel class is a very simple abstract class that supports applications that want to use the Model-View-Controller (MVC) architecture. The VkModel class is intended to be subclassed, and the subclass provides the data members and any additional functions required to implement the model. ViewKit components can be used as both "views" and "controllers". View components can arrange to be notified of changes to the model by registering a member function with the VkModel::updateCallback list. Callbacks on this list are invoked when a subclass of VkModel calls updateViews(). This method is just a convenient way to invoke the functions on the updateCallback list. Components used as "controllers" are expected to send messages to subclasses of VkModel to alter the state of the model. This protocol must be worked out between the VkModel subclass and the controller components. FUNCTION DESCRIPTIONS updateViews() void updateViews(void * data); Calls all member functions on the updateCallback list, passing the provided data as the callData. VkModel() VkModel(void); Initialize a VkModel class. ~VkModel() virtual void ~VkModel(void); Empty function. DATA MEMBER DESCRIPTIONS updateCallback static const const char* updateCallback; Other classes that wish to be notified when the internal state of a VkModel subclass has changed should register a member function with this callback list. INHERITED MEMBER FUNCTIONS Inherited from VkCallbackObject callCallbacks(), addCallback(), removeCallback(), removeAllCallbacks() SEE ALSO VkCallbackObject ViewKit Programmer's Guide The X Window System, DEC Press, Bob Sheifler and Jim Gettys The X Window System Toolkit, DEC Press, Paul Asente and Ralph Swick The OSF/Motif Programmers Reference, Prentice Hall, OSF