Usage accounting can also be implemented by simply applying the usage accounting SOAP extension built in Chapter 10. You do this by adding the Accounting attribute to each method for which you want to track usage accounting. Assuming you already applied the security extension, you don't need to do anything else to apply usage accounting. Listing 13.6 shows the GetTemperature and GetWeather methods with the Accounting attribute added.
<WebMethod(), _ SoapDocumentMethod( _ Binding:="WeatherInterface", _ Action:="", _ ParameterStyle:=SoapParameterStyle.Bare), _ SoapSecurity("Temperature"), _ SoapHeader("sessHdr", ...