IMultipleResult
我有一个用于返回在部分类中实现的存储过程的 LINQ to SQL 接线代码。
当您在dbml
文件中添加新对象时,会再次生成存储过程接线代码;这会导致代码在我的部分类和designer.cs
.
如何标记存储过程,使dbml
设计器中的更改不会自动生成接线代码?
namespace Audit
{
public partial class LinqAuditDataContext
{
[Function(Name = "getRows")]
[ResultType(typeof(featuresE))]
[ResultType(typeof(featuresWater))]
[ResultType(typeof(featuresV))]
public IMultipleResults getRows([global::System.Data.Linq.Mapping.ParameterAttribute(DbType = "Int")] System.Nullable<int> page, [global::System.Data.Linq.Mapping.ParameterAttribute(DbType = "Int")] System.Nullable<int> rowsshow, [global::System.Data.Linq.Mapping.ParameterAttribute(DbType = "NVarChar(30)")] string table, [global::System.Data.Linq.Mapping.ParameterAttribute(DbType = "Bit")] System.Nullable<bool> fact, [global::System.Data.Linq.Mapping.ParameterAttribute(DbType = "Int")] System.Nullable<int> id_obj)
{
IExecuteResult result = this.ExecuteMethodCall(this, ((MethodInfo)(MethodInfo.GetCurrentMethod())), page, rowsshow, table, fact, id_obj);
return ((IMultipleResults)(result.ReturnValue));
}
}
}