gmplEventStatement

Event Statement Summary

Event is a nonterminal, declaration statement that occurs within Class statements and within the refactoring statement Migclass. It is also used within metalanguage class declarations and has some attributes that are only used in that context. Events are handled by user defined methods called "handlers". These handlers have names that are different from the event itself. In addition, the arguments associated with the event have a class name associated with them.


The attributes of the Event statement are as follows:


Attribute Description
IdThis attribute is the identifier of the event. It must be unique within the scope of the class containing the event. The identifier is not case-sensitive.
NetHandlerThis attribute is the name of the event handler to be used in the authored code.
NetArgsThis attribute is the name of the class to be associated with the arguments of the handler to be used in the authored code.
StatusThis attribute is the Status attribute as discussed on the Declaration page. It specifies the various context flags to be associated with the event.
NetNameThis attribute is the identifier of the event itself to be used when declaring or referring to it in the target language.
MigNameThis attribute is identical to NetName. If both are used in the declaration the Migname takes precedence.
MigStatusThis attribute is a MigStatus attribute as discussed on the Declaration page. It contains generalized migration settings for the event.
MigCommentThis deprecated string attribute associates a comment with the event. This comment does not trigger the gmNI event handlers and can interfere with the MigStatus attribute.
MigPatternThis string attribute associates a surface pattern string with code references to the event. See the Patterns page for details on the content of pattern strings. It is equivalent to the All pattern. Pattern strings associated with events supply code startup statements needed in the handlers of the events.
CshPatternThis string attribute associates a surface pattern string with code references to the event. See the Patterns page for details on the content of pattern strings. It is equivalent to the Csh pattern. Pattern strings associated with events supply code startup statements needed in the handlers of the events.
VbnPatternThis string attribute associates a surface pattern string with code references to the event. See the Patterns page for details on the content of pattern strings. It is equivalent to the Vbn pattern. Pattern strings associated with events supply code startup statements needed in the handlers of the events.
NpramThis integer attribute specifies the number of parameters associated with the surface pattern strings.
RoleThis attribute contains an optional keyword describing the overall role of the operation being authored via the surface pattern strings: Unknown, Property, Method, Define, Utility, Command, Constant, Function, Event, Control, Collection, Resource, Index, or Migclass. The default is None.
PatstatusAn optional keyword describing the overall status of the operation authored via the surface pattern strings: Ok, Delete, Deprecated, NotImplemented, MustCorrect, NotIdent, Postfix, or NeedsPren. The default is Ok.
OpcodeThis attribute is only used with metalanguage declarations. This entry specifies the actual opcode.subcode byte pair to be issued by references to the event as opposed to the normal call operations.
SpecializedHookupThis boolean attribute indicates that the event hookup in designer code should use the type specified by netHandler rather than a generic handler of type netArgs.  Most WinForms control events require specializedHookup="on".  The default is "off".  

The declarations within the Event statement are as follows:


Substatement Description
ArgumentDefines one of the event arguments.

The script errors associated with the Event statement are as follows:


Error Description
1130Method command missing required id attribute.
1131Unable to store METHOD vector: %1d
1132The syntax cannot be found.
1133The subprogram type is undefined.
1134Encountered following when expecting 'argument': %1d


Table of Contents