Glossary Item Box
An EndXXX event is a generic term to describe any event used by PowerTCP Sockets for .NET that begins with the word "End". These events are reserved to notify the application of a process being completed. In addition, all EndXXX events are raised by the completion of a corresponding BeginXXX method. The EndXXX events used by PowerTCP SSL Sockets for .NET components are as follows:
Event | Raised By | Purpose |
---|---|---|
EndConnected Event | Use of the BeginConnect method | Notifies the application that a the Tcp component is connected. |
EndReceive event | Use of the BeginReceive method | Notifies the application that data has been received. |
EndSend event | Use of the BeginSend method | Notifies the application that data has been asynchronously sent. |
EndReceive event | Use of the BeginReceive method | Notifies the application that data has been received. |
EndSend event | Use of the BeginSend method | Notifies the application that data has been asynchronously sent. |
EndGetHost event | Use of the BeginGetHost method | Notifies the application that a host or IP address has been resolved, successfully or unsuccessfully. |
EndGetMailHosts event | Use of the BeginGetMailHosts method | Notifies the application that an email address has been resolved, successfully or unsuccessfully. |
EndSend event | Use of the BeginSend method | Notifies the application that an asynchronous ping operation has completed. |
EndSend event | Use of the BeginSend method | Notifies the application that an asynchronous trace route operation has completed. |
Comparison With Other Techniques:
PowerTCP products employ a unique technique for handling asynchronous completion notification:
We believe that this approach has made asynchronous communications programming as easy as it gets, providing our users with superior value.
Special Notes About EndXXX Events:
Be sure to check the e.Exception property for exceptions that occurred during the asynchronous method call. If the operation failed to complete, the presence of an Exception object may be your only indication that the operation failed.
It is a very good programming practice to surround your event code with a try/catch block. If you do not do so and generate an exception within your code, a default exception handler will display your exception to the user of your application using a MessageBox.
Send comments on this topic.
Documentation version 1.1.2.0.
© 2008 Dart Communications. All rights reserved.