*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> Vk/VkAction (3)              
Title
Content
Arch
Section
 

Contents


VkAction(3x)							  VkAction(3x)


NAME    [Toc]    [Back]

     VkAction -	Supports encapsulation of a command that can be	undone

HEADER FILE    [Toc]    [Back]

     #include <Vk/VkAction.h>

PUBLIC PROTOCOL	SUMMARY
   Constructor/Destructor
	   VkAction(const char*);
	   virtual void	~VkAction(void);


   Executing actions    [Toc]    [Back]
	  void execute(void);

PROTECTED PROTOCOL SUMMARY    [Toc]    [Back]

   Specifying do/undo Behavior
	   virtual void	doit(void);
	   virtual void	undoit(void);


   Protected Data Members    [Toc]    [Back]
	  char*	_name;

CLASS DESCRIPTION    [Toc]    [Back]

	  This class supports applications that	wish to	model undoable actions
	  as objects. Applications must	create derived classes that define the
	  exact	actions	to be taken. Applications use classes derived from
	  VkAction by instantiating an instance	of a class and calling the
	  object's execute() member function. The object automatically
	  registers itself with	the application's undo manager,	which provides
	  the interface	for undoing the	command.


DERIVING SUBCLASSES    [Toc]    [Back]

	  To use this class, an	application must create	a derived class	for
	  every	type of	action it wishes to perform. Each derived class	must
	  override the virtual functions doit()	and undoit(). The derived
	  class	can add	data members to	maintain any state required between
	  doing	the command and	undoing	the command.


FUNCTION DESCRIPTIONS    [Toc]    [Back]

   doit()
	  virtual void doit(void);






									Page 1






VkAction(3x)							  VkAction(3x)



	  This virtual function	should be overridden to	provide	the action to
	  be performed by the derived class.

   undoit()
	  virtual void undoit(void);


	  This virtual function	should be overridden to	reverse	the effects of
	  the action performed by the derived class.

   VkAction()    [Toc]    [Back]
	  VkAction(const char* name);


	  Initialize a VkAction	object.

   ~VkAction()
	  virtual void ~VkAction(void);


	  Handle destruction of	a VkAction object.

   execute()
	  void execute(void);


	  Calls	derived	classes' doit()	method and arranges for	the undo
	  action to be registered with the undo	manager.

DATA MEMBER DESCRIPTIONS    [Toc]    [Back]

   _name
	  char*	_name;


	  Every	action should have a name, which is used to identify the
	  action in the	undo manager.

CLASSES	USED BY	THIS CLASS
     VkMenuUndoManager

SEE ALSO    [Toc]    [Back]

      
      
     VkMenuUndoManager
     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


									PPPPaaaaggggeeee 2222
[ Back ]
 Similar pages
Name OS Title
vlan OpenBSD IEEE 802.1Q encapsulation/decapsulation pseudo-device
VkInput IRIX Encapsulation class for input callbacks on file descriptors
VkWidgetList IRIX Supports operations on a list of widgets
VkPrefItem IRIX Abstract class that supports preference items
VkNameList IRIX A class that supports and manipulates lists of strings
setPowerSaver IRIX turns on powersave option, if monitor supports it
VkGangedGroup IRIX Utility class that supports ganged scrollbars and scales
kkcd Tru64 Daemon that supports the Kana-Kanji conversion service
VkGenericDialog IRIX An abstract class that supports custom dialog managers
VkCompletionField IRIX A text input field that supports automatic name completion
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service