System.Web.Services 1.0.5000.0 2.0.0.0 Gtk# is thread aware, but not thread safe; See the <link location="node:gtk-sharp/programming/threads">Gtk# Thread Programming</link> for details. System.Object

ASP.NET allows a SOAP-related infrastructure to be built by means of an extensibility mechanism. The ASP.NET SOAP extension architecture revolves around an extension that can inspect or modify a message at specific stages in message processing on either the client or the server.

ASP.NET SOAP extensions derive from the class. The and methods provide alternative mechanisms for initializing the SOAP extension to enhance performance. is the heart of most SOAP extensions, as the method is called at each stage defined in , allowing the SOAP extension to perform the desired behavior of that specific SOAP extension. For SOAP extensions that need to modify the SOAP request or SOAP response, provides an opportunity to receive the proposed data to be sent across the wire.

The base class for SOAP extensions for XML Web services created using ASP.NET.

- Constructor
  To be added

  Initializes a new instance of the class.

  1.0.5000.0
  2.0.0.0
- Method
  System.IO.Stream ``

  ensures that SOAP extensions with the highest priority can modify the actual data closest to the SOAP message sent or returned over the wire.

  SOAP extensions should save references of the passed into and the returned from . If the SOAP extension is configured to run with a XML Web service method, the passed into contains the serialized SOAP request at the . Similarily, the reference returned from is written into when the serialization occurs and thus contains the serialized SOAP response in the .

  When overridden in a derived class, allows a SOAP extension access to the memory buffer containing the SOAP request or response.

  A representing a new memory buffer that this SOAP extension can modify.

  A memory buffer containing the SOAP request or response. 1.0.5000.0 2.0.0.0
- Method
  System.Object ``

  The overload of that gets called by ASP.NET depends on how the SOAP extension was specified. There are two methods for specifying a SOAP extension:

  Apply a custom attribute, deriving from , to the individual XML Web service method.

  Add a reference in either the web.config or app.config configuration files.

  If you add a reference to one of the configuration files, the SOAP extension runs for all XML Web services within the scope of that configuration file. When specifying, a SOAP extension by referencing a configuration file, ASP.NET invokes the overload that passes in a . When specifying an extension by applying a custom attribute, ASP.NET invokes the that passes in a and a .

  For details on adding SOAP extensions to a configuration file, see [<topic://cpconconfigurationoptionsforaspnetwebservices>].

  When overridden in a derived class, allows a SOAP extension to initialize data specific to a class implementing an XML Web service at a one time performance cost.

  The that the SOAP extension initializes for caching.

  The type of the class implementing the XML Web service to which the SOAP extension is applied. 1.0.5000.0 2.0.0.0
- Method
  System.Object `` ``

  If the SOAP extension is configured using a configuration file see the overload that accepts a .

  A SOAP extension has three opportunities to initialize data and they all have different purposes:

  Class constructor - The class constructor is called every time a SOAP extension is instantiated and is typically used to initialize member variables.

  - , however, is called just once, the first time a SOAP request is made to an XML Web services method. If a custom attribute is applied to the XML Web service method, the method is invoked. This allows the SOAP extension to interrogate the of an XML Web service method for prototype information or to access extension-specific data passed by a class deriving from . The return value is cached by ASP.NET and passed into subsequent methods. Therefore, initialization done in is encapsulated essentially into a one-time performance hit.

  - is called every time a SOAP request is made to an XML Web service method, but has an advantage over the class constructor, in that the initialized in is passed to it.

  When overridden in a derived class, allows a SOAP extension to initialize data specific to an XML Web service method using an attribute applied to the XML Web service method at a one time performance cost.

  The that the SOAP extension initializes for caching.

  A representing the specific function prototype for the XML Web service method to which the SOAP extension is applied. The applied to the XML Web service method. 1.0.5000.0 2.0.0.0
- Method
  System.Void ``

  A SOAP extension has three opportunities to initialize data and they all have different purposes:

  Class constructor - The class constructor is called every time a SOAP extension is instantiated and is typically used to initialize member variables.

  - , however, is called just once, the first time a SOAP request is made to an XML Web services method. If a custom attribute is applied to the XML Web service method, the method is invoked. This allows the SOAP extension to interrogate the of an XML Web service method for prototype information or to access extension-specific data passed by a class deriving from . The return value is cached by ASP.NET and passed into subsequent methods. Therefore, initialization done in is encapsulated essentially into a one-time performance hit.

  - is called every time a SOAP request is made to an XML Web service method, but has an advantage over the class constructor, in that the initialized in is passed to it.

  You can also add a SOAP extension without deriving from by using the <soapExtensionTypes> Element in a configuration file. For details, see <soapExtensionTypes> Element and SOAP Message Modification Using SOAP Extensions.

  When overridden in a derived class, allows a SOAP extension to initialize itself using the data cached in the method.

  The returned from cached by ASP.NET. 1.0.5000.0 2.0.0.0
- Method
  System.Void ``

  is called at all stages for SOAP extensions applied to both XML Web services created using ASP.NET and their clients. At each , an instance of a class deriving from is passed to . If the SOAP extension is running on the XML Web service client, then a object is passed into ; otherwise a object is passed in.

  When overridden in a derived class, allows a SOAP extension to receive a to process at each .

  The to process. 1.0.5000.0 2.0.0.0