CodeDom: handle 'out' stored procedure arguments as .NET SqlMetal does.
CodeDom: handle 'out' stored procedure arguments as .NET SqlMetal does.

Consider the following stored procedure:

  <Function Name="northwind.sp_selOrders" Method="SpSelOrders" IsComposable="false">
    <Parameter Name="s" Type="System.String" DbType="CHAR(20)" Direction="In" />
    <Parameter Name="s2" Type="System.Int32" DbType="int" Direction="Out" />
  </Function>

Previously, DbMetal would generate:

    [Function(Name="northwind.sp_selOrders", IsComposable=false)]
    public void SpSelOrders(
            [Parameter(Name="s", DbType="CHAR(20)")] string s, 
            [Parameter(Name="s2", DbType="int")] out int s2)
    {
        IExecuteResult result = this.ExecuteMethodCall(this, MethodBase.GetCurrentMethod(), s);
        s2 = ((int)(result.GetParameterValue(1)));
    }

While .NET SqlMetal would generate (for the same .dbml):

	[Function(Name="northwind.sp_selOrders")]
	public void SpSelOrders(
		[Parameter(DbType="CHAR(20)")] string s, 
		[Parameter(DbType="int")] out System.Nullable<int> s2)
	{
		s2 = default(System.Nullable<int>);
		IExecuteResult result = this.ExecuteMethodCall(this, ((MethodInfo)(MethodInfo.GetCurrentMethod())), s, s2);
		s2 = ((System.Nullable<int>)(result.GetParameterValue(1)));
	}

Note that .NET SqlMetal initializes the out parameters, then passes them to the 
stored procedure call.  I don't know why it does this; I just observe that it 
does.

This patch changes DbMetal's behavior to match .NET SqlMetal's.


git-svn-id: 1800f71f313d917366f95485fa960eed04b40598@1374 33146b6e-df29-0410-a1ca-39be37fb9416

koush/dblinq,koush/dblinq