• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# dOOdads.BusinessEntity类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中MyGeneration.dOOdads.BusinessEntity的典型用法代码示例。如果您正苦于以下问题:C# BusinessEntity类的具体用法?C# BusinessEntity怎么用?C# BusinessEntity使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



BusinessEntity类属于MyGeneration.dOOdads命名空间,在下文中一共展示了BusinessEntity类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: SqlClientDynamicQuery

		public SqlClientDynamicQuery(BusinessEntity entity)
			: base(entity)
		{
			
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:5,代码来源:SqlClientDynamicQuery.cs


示例2: CreateDynamicQuery

 internal abstract DynamicQuery CreateDynamicQuery(BusinessEntity entity);
开发者ID:ivladyka,项目名称:Ekran,代码行数:1,代码来源:BusinessEntity.cs


示例3: Enlist

		/// <summary>
		/// Enlist by the dOOdads architecture when a IDbCommand (SqlCommand is an IDbCommand). The command may or may not be enrolled 
		/// in a transaction depending on whether or not BeginTransaction has been called. Each call to Enlist must be followed by a
		/// call to <see cref="DeEnlist"/>.
		/// </summary>
		/// <param name="cmd">Your SqlCommand, OleDbCommand, etc ...</param>
		/// <param name="entity">Your business entity, in C# use 'this', VB.NET use 'Me'.</param>
		/// <example>
		/// C#
		/// <code>
		/// txMgr.Enlist(cmd, this);
		/// cmd.ExecuteNonQuery();
		/// txMgr.DeEnlist(cmd, this);
		/// </code>
		/// VB.NET
		/// <code>
		/// txMgr.Enlist(cmd, Me)
		/// cmd.ExecuteNonQuery()
		/// txMgr.DeEnlist(cmd, Me)
		/// </code>
		/// </example>
		public void Enlist(IDbCommand cmd, BusinessEntity entity)
		{
			if(txCount == 0 || entity._notRecommendedConnection != null)
			{
				// NotRecommendedConnections never play in dOOdad transactions
				cmd.Connection = CreateSqlConnection(entity);
			}
			else
			{
				string connStr = entity._config;
				if(entity._raw != "") connStr = entity._raw;

				Transaction tx = this.transactions[connStr] as Transaction;

				if(tx == null)
				{
                    IDbConnection sqlConn = CreateSqlConnection(entity);
                    
                    tx = new Transaction();
					tx.sqlConnection = sqlConn;

					if(_isolationLevel != IsolationLevel.Unspecified)
					{
						tx.sqlTx = sqlConn.BeginTransaction(_isolationLevel);
					}
					else
					{
						tx.sqlTx = sqlConn.BeginTransaction();
					}
					this.transactions[connStr] = tx;
				}

                cmd.Connection = tx.sqlConnection;
				cmd.Transaction = tx.sqlTx;
			}
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:57,代码来源:TransactionMgr.cs


示例4: CreateDynamicQuery

 internal override DynamicQuery CreateDynamicQuery(BusinessEntity entity)
 {
     return new PostgreSqlDynamicQuery(entity);
 }
开发者ID:ivladyka,项目名称:Ekran,代码行数:4,代码来源:PostgreSqlEntity.cs


示例5: OleDbDynamicQuery

 public OleDbDynamicQuery(BusinessEntity entity)
     : base(entity)
 {
 }
开发者ID:ivladyka,项目名称:Ekran,代码行数:4,代码来源:OleDbDynamicQuery.cs


示例6: AggregateClause

 public AggregateClause(BusinessEntity entity)
 {
     this._entity = entity;
 }
开发者ID:menasbeshay,项目名称:ivalley-svn,代码行数:4,代码来源:Branches.cs


示例7: CreateDynamicQuery

		override internal DynamicQuery CreateDynamicQuery(BusinessEntity entity)
		{
			return new OracleClientDynamicQuery(entity);
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:4,代码来源:OracleClientEntity.cs


示例8: CreateDynamicQuery

 internal override DynamicQuery CreateDynamicQuery(BusinessEntity entity)
 {
     return new SQLiteDynamicQuery(entity);
 }
开发者ID:ivladyka,项目名称:Ekran,代码行数:4,代码来源:SQLiteEntity.cs


示例9: CreateDynamicQuery

		override internal DynamicQuery CreateDynamicQuery(BusinessEntity entity)
		{
			return new VistaDBDynamicQuery(entity);
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:4,代码来源:VistaDBEntity.cs


示例10: OracleClientDynamicQuery

		public OracleClientDynamicQuery(BusinessEntity entity)
			: base(entity)
		{
				
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:5,代码来源:OracleClientDynamicQuery.cs


示例11: CreateSqlConnection

		private IDbConnection CreateSqlConnection(BusinessEntity entity)
		{
			IDbConnection cn;

			if(entity._notRecommendedConnection != null)
			{
				// This is assumed to be open
				cn = entity._notRecommendedConnection;
			}
			else
			{
				cn = entity.CreateIDbConnection();

				if(entity._raw != "")
					cn.ConnectionString = entity._raw;
				else
#if(VS2005)
					cn.ConnectionString = ConfigurationManager.AppSettings[entity._config];
#else
                    cn.ConnectionString = ConfigurationSettings.AppSettings[entity._config];
#endif

				cn.Open();
			}

			return cn;
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:27,代码来源:TransactionMgr.cs


示例12: AddBusinessEntity

		/// <summary>
		/// Called internally by BusinessEntity
		/// </summary>
		/// <param name="entity"></param>
		internal void AddBusinessEntity(BusinessEntity entity)
		{
			if(this.objectsInTransaction == null)
			{
				this.objectsInTransaction = new ArrayList();
			}

			this.objectsInTransaction.Add(entity);
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:13,代码来源:TransactionMgr.cs


示例13: DeEnlist

		/// <summary>
		/// Each call to Enlist must be followed eventually by a call to DeEnlist.  
		/// </summary>
		/// <param name="cmd"></param>
		/// <param name="entity"></param>
		/// <example>
		/// C#
		/// <code>
		/// txMgr.Enlist(cmd, this);
		/// cmd.ExecuteNonQuery();
		/// txMgr.DeEnlist(cmd, this); 
		/// </code>
		/// VB.NET
		/// <code>>
		/// txMgr.Enlist(cmd, Me)
		/// cmd.ExecuteNonQuery()
		/// txMgr.DeEnlist(cmd, Me)
		/// </code>
		/// </example>
		public void DeEnlist(IDbCommand cmd, BusinessEntity entity)
		{
			if(entity._notRecommendedConnection != null)
			{
				// NotRecommendedConnection never play in dOOdad transactions
				cmd.Connection = null;
			}
			else
			{
				if(txCount == 0)
				{
					cmd.Connection.Dispose();
				}
			}
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:34,代码来源:TransactionMgr.cs


示例14: VisualFoxProDynamicQuery

		public VisualFoxProDynamicQuery(BusinessEntity entity) : base(entity) { }
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:1,代码来源:VisualFoxProDynamicQuery.cs


示例15: CreateDynamicQuery

 internal override DynamicQuery CreateDynamicQuery(BusinessEntity entity)
 {
     return new FirebirdSqlDynamicQuery(entity);
 }
开发者ID:ivladyka,项目名称:Ekran,代码行数:4,代码来源:FirebirdSqlEntity.cs


示例16: DynamicQuery

		/// <summary>
		/// You never need to call this, just access your BusinessEntity.Query property.
		/// </summary>
		/// <param name="entity">Passed in via the BusinessEntity</param>
		public DynamicQuery(BusinessEntity entity)
		{
			this._entity = entity;
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:8,代码来源:DynamicQuery.cs


示例17: MySql4DynamicQuery

		public MySql4DynamicQuery(BusinessEntity entity)
			: base(entity)
		{
			
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:5,代码来源:MySql4DynamicQuery.cs


示例18: PostgreSqlDynamicQuery

		public PostgreSqlDynamicQuery(BusinessEntity entity)
			: base(entity)
		{
			
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:5,代码来源:PostgreSqlDynamicQuery.cs


示例19: SQLiteDynamicQuery

		public SQLiteDynamicQuery(BusinessEntity entity)
			: base(entity)
		{
			
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:5,代码来源:SQLiteDynamicQuery.cs


示例20: FirebirdSqlDynamicQuery

		public FirebirdSqlDynamicQuery(BusinessEntity entity)
			: base(entity)
		{
			
		}
开发者ID:nguyenhuuhuy,项目名称:mygeneration,代码行数:5,代码来源:FirebirdSqlDynamicQuery.cs



注:本文中的MyGeneration.dOOdads.BusinessEntity类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# dOOdads.WhereParameter类代码示例发布时间:2022-05-26
下一篇:
C# dOOdads.AggregateParameter类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap