Extend the ClientBase<(Of <(TChannel>)>) class to create a custom Silverlight 2 client object that can be used to connect to a service.
The ClientBase<(Of <(TChannel>)>) class can be used quickly and easily by developers who prefer objects to the use of the interfaces and the System.ServiceModel..::.ChannelFactory<(Of <(TChannel>)>) class. In all cases this class wraps or exposes the methods and functionality of the System.ServiceModel..::.ChannelFactory<(Of <(TChannel>)>) class and the System.ServiceModel..::.IClientChannel interface.
As when using the System.ServiceModel..::.ServiceHost class, you can create the class and modify the endpoint, channel factory, or security information prior to making any calls or calling Open.
Special note for Managed C++ users deriving from this class:
Put your clean-up code in (On)(Begin)Close (and/or OnAbort), not in a destructor.
Avoid destructors: they cause the compiler to auto-generate IDisposable.
Avoid non-reference members: they can cause the compiler to auto-generate IDisposable.
Avoid finalizers; but if you include one, you should suppress the build warning and call SuppressFinalize(Object) and the finalizer itself from (On)(Begin)Close (and/or OnAbort) to emulate what would have been the auto-generated IDisposable behavior.