The Gravey 2.5 Framework and AIM RIA

Class GrvObject

Object
   |
   +--GrvObject
Direct Known Subclasses:
MVCContext, EDOHolderSelectionItem, MVCDecode, MVCMutex, MVCEditRule, EDOIndex, MVCObserver, MVCMap, MVCView, EDO, MVCCommand

class GrvObject


This is the root class for all "classes" implemented via the GLOBALS.Class() function (ala Java "Object"). Class replaces the normal Javascript "constructor" function with a new wrapper function that implements a robust inheritence mechanism. This mechanism supports "pretty" source code whereby "methods" are declared inline, but the source code of those methods are not copied into every object instance as would otherwise be the case.

The wrapper function also sets up a real "constructor" that can use GLOBALS.grvValidateArgs() to insure that the required parameters are passed to it, throwing an exception if not.

The design pattern implemented by Class/Extends corrects several problems that occur with the naive inheritence mechanisms often used with Javascript.

  The required coding convention for "GrvObject":
  (1) the "class" is declared via the utility
      function GLOBALS.Class()
  (2) the "superclass" (if any) is declared via the
      .Extends method GLOBALS.grvExtends()
  (3) the "constructor" logic for the class is placed
      in a "method" named "konstructor"
  (4) the konstructor method invokes the "super" constructor
      via its class name [rather than literally "super()"]

Version: 2.0

Author: Bruce Wallace (PolyGlotInc.com)
See:Defined in grvClass.js


Constructor Summary
GrvObject ()
           
 
Method Summary
 Object souper()
           Invokes the "super" version of whatever method that is calling souper.

Constructor Detail

GrvObject

GrvObject()

Method Detail

souper

Object souper()

The Gravey 2.5 Framework and AIM RIA

Documentation generated by JSDoc on Thu Jan 6 12:46:39 2011