Code for http://www.debugrelease.com/2009/04/01/capture-xml-in-wcf-service/