A class event is a class member of the publisher class that you define. Here is the short syntax for defining a class event in the publisher class.

define [access-mode] event Event-Name 
  signature void (parameter, [parameter…]).

Syntax Element

Description

access-mode

Specifies whether the method will be available to other parts of an application. For more information, see Access modes.

For a class event, the access mode specifies where you can subscribe a handler for the event using the subscribe( ) method.

Event-Name

The name of the event. This name must be unique among all other events, properties, and variable data members in the application.

signature void (parameter, [parameter..])

The signature of the class event. This indicates the required signature for any event handler that subscribes to the event.