NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

ServiceBase Methods

The methods of the ServiceBase class are listed below. For a complete list of ServiceBase class members, see the ServiceBase Members topic.

Public:

Dispose Function calles when all the services in the application have reached the stopped state. Need to free the allocated memory.
Equals (inherited from Object) Determines whether the specified Object is the same instance as the current Object. Subclasses are expected to override this method to support value equality (not reference equality).
GetContainer (inherited from Component) Returns the IContainer that contains the Component.
GetDesignMode (inherited from Component) Gets a value indicating whether the Component is currently in design mode.
GetHashCode (inherited from Object) Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table.
GetServiceObject (inherited from Component) Returns an object representing a service provided by the Component.
GetType (inherited from Object) Gets the Type of the Object.
Run Overloaded. [To be supplied.]
ToString (inherited from Component) Returns a String containing the name of the Component, if any. This method should not be overridden. For internal use only.

Protected:

Finalize (inherited from Object) Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by the Garbage Collector (GC). This method may be ignored by the runtime; therefore, necessary cleanup operations should be done elsewhere.
MemberwiseClone (inherited from Object) Creates a shallow copy of the current Object.
OnContinue Called when a Continue Command message is sent to to the service. This function is expected to be overridden when the CanPauseAndContinue property is true.
OnCustomCommand Called when a custom command message is sent to to the service. This function is expected to be overridden if the CustomCommandsAccepted property is non-zero.
OnPause Called when a Pause Command message is sent to to the service. This function is expected to be overridden when the CanPauseAndContinue property is true.
OnShutdown Called when the system is shutting down. This function should be overridden when the CanShutdown property is true.
OnStart Called when the service is being started. You must override this function in order to start your service.
OnStop Called when a Stop Command message is sent to to the service. This function is expected to be overridden when the CanStop property is true.

See Also

ServiceBase Class | System.ServiceProcess Namespace