Setting Up Callback Handlers

Use the callback handlers for event notifications.

Use the Sybase.Persistence.ICallbackHandler API for event notifications including login for synchronization and replay. If you do not register your own implementation of the Sybase.Persistence.ICallbackHandler interface, the generated code will regsiter a new default callback handler.

  1. The generated database class contains a method called RegisterCallbackHandler. Use this method to install your implementation of ICallbackHandler.
    For example:
    SUP101DB.RegisterCallbackHandler(new MyCallbackHandler());
  2. Each generated MBO class also has the same method to register your implementation of the ICallbackHandler for that particular type. For example, if Customer is a generated MBO class, you can use the following code:
    Customer.RegisterCallbackHandler(new MyCustomerMBOCallbackHandler());