DynamicDriver..::..InitializeContext Method
This virtual method is called after a data context object has been instantiated, in
preparation for a query. You can use this hook to perform additional initialization work.
In overriding InitializeContext, you can access properties on the QueryExecutionManager object that’s passed in as a parameter. One of these properties is called SqlTranslationWriter (type TextWriter) and it allows you to send data to the SQL translation tab.
Although this tab is intended primary for SQL translations, you can use it for other things as well.For example, with WCF Data Services, it makes sense to write HTTP requests here:
var dsContext = (DataServiceContext)context;
dsContext.SendingRequest += (sender, e) =>
executionManager.SqlTranslationWriter.WriteLine(e.Request.RequestUri);
Namespace:
Aerospike.Database.LINQPadDriverAssembly: Aerospike.Database.LINQPadDriver (in Aerospike.Database.LINQPadDriver.dll)
Syntax
public void InitializeContext( IConnectionInfo cxInfo, Object context, QueryExecutionManager executionManager )