当前位置: 首页>>代码示例>>C#>>正文


C# Dialect.GetSequenceNextValString方法代码示例

本文整理汇总了C#中Dialect.GetSequenceNextValString方法的典型用法代码示例。如果您正苦于以下问题:C# Dialect.GetSequenceNextValString方法的具体用法?C# Dialect.GetSequenceNextValString怎么用?C# Dialect.GetSequenceNextValString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Dialect的用法示例。


在下文中一共展示了Dialect.GetSequenceNextValString方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: SequenceStructure

		public SequenceStructure(Dialect.Dialect dialect, string sequenceName, int initialValue, int incrementSize)
		{
			_sequenceName = sequenceName;
			_initialValue = initialValue;
			_incrementSize = incrementSize;
			_sql = new SqlString(dialect.GetSequenceNextValString(sequenceName));
		}
开发者ID:duraes,项目名称:nhibernate-core,代码行数:7,代码来源:SequenceStructure.cs

示例2: Configure

		/// <summary>
		/// Configures the SequenceGenerator by reading the value of <c>sequence</c> and
		/// <c>schema</c> from the <c>parms</c> parameter.
		/// </summary>
		/// <param name="type">The <see cref="IType"/> the identifier should be.</param>
		/// <param name="parms">An <see cref="IDictionary"/> of Param values that are keyed by parameter name.</param>
		/// <param name="dialect">The <see cref="Dialect.Dialect"/> to help with Configuration.</param>
		public virtual void Configure( IType type, IDictionary parms, Dialect.Dialect dialect )
		{
			this.sequenceName = PropertiesHelper.GetString( Sequence, parms, "hibernate_sequence" );
			string schemaName = ( string ) parms[ Schema ];
			if( schemaName != null && sequenceName.IndexOf( StringHelper.Dot ) < 0 )
			{
				sequenceName = schemaName + '.' + sequenceName;
			}
			returnClass = type.ReturnedClass;
			sql = dialect.GetSequenceNextValString( sequenceName );
		}
开发者ID:rcarrillopadron,项目名称:nhibernate-1.0.2.0,代码行数:18,代码来源:SequenceGenerator.cs

示例3: Configure

		/// <summary>
		/// Configures the SequenceGenerator by reading the value of <c>sequence</c> and
		/// <c>schema</c> from the <c>parms</c> parameter.
		/// </summary>
		/// <param name="type">The <see cref="IType"/> the identifier should be.</param>
		/// <param name="parms">An <see cref="IDictionary"/> of Param values that are keyed by parameter name.</param>
		/// <param name="dialect">The <see cref="Dialect.Dialect"/> to help with Configuration.</param>
		public virtual void Configure(IType type, IDictionary<string, string> parms, Dialect.Dialect dialect)
		{
			sequenceName = PropertiesHelper.GetString(Sequence, parms, "hibernate_sequence");
			string schemaName;
			string catalogName;
			parms.TryGetValue(Parameters, out parameters);
			parms.TryGetValue(PersistentIdGeneratorParmsNames.Schema, out schemaName);
			parms.TryGetValue(PersistentIdGeneratorParmsNames.Catalog, out catalogName);

			if (sequenceName.IndexOf('.') < 0)
			{
				sequenceName = Table.Qualify(catalogName, schemaName, sequenceName);
			}

			identifierType = type;
			sql = new SqlString(dialect.GetSequenceNextValString(sequenceName));
		}
开发者ID:ray2006,项目名称:WCell,代码行数:24,代码来源:SequenceGenerator.cs

示例4: Configure

		/// <summary>
		/// Configures the SequenceGenerator by reading the value of <c>sequence</c> and
		/// <c>schema</c> from the <c>parms</c> parameter.
		/// </summary>
		/// <param name="type">The <see cref="IType"/> the identifier should be.</param>
		/// <param name="parms">An <see cref="IDictionary"/> of Param values that are keyed by parameter name.</param>
		/// <param name="dialect">The <see cref="Dialect.Dialect"/> to help with Configuration.</param>
		public virtual void Configure(IType type, IDictionary<string, string> parms, Dialect.Dialect dialect)
		{
			var nativeSequenceName = PropertiesHelper.GetString(Sequence, parms, "hibernate_sequence");
			bool needQuote = StringHelper.IsBackticksEnclosed(nativeSequenceName);
			bool isQuelified = nativeSequenceName.IndexOf('.') > 0;
			if (isQuelified)
			{
				string qualifier = StringHelper.Qualifier(nativeSequenceName);
				nativeSequenceName = StringHelper.Unqualify(nativeSequenceName);
				nativeSequenceName = StringHelper.PurgeBackticksEnclosing(nativeSequenceName);
				sequenceName = qualifier + '.' + (needQuote ? dialect.QuoteForTableName(nativeSequenceName) : nativeSequenceName);
			}
			else
			{
				nativeSequenceName = StringHelper.PurgeBackticksEnclosing(nativeSequenceName);
				sequenceName = needQuote ? dialect.QuoteForTableName(nativeSequenceName) : nativeSequenceName;
			}
			string schemaName;
			string catalogName;
			parms.TryGetValue(Parameters, out parameters);
			parms.TryGetValue(PersistentIdGeneratorParmsNames.Schema, out schemaName);
			parms.TryGetValue(PersistentIdGeneratorParmsNames.Catalog, out catalogName);

			if (!isQuelified)
			{
				sequenceName = dialect.Qualify(catalogName, schemaName, sequenceName);
			}

			identifierType = type;
			sql = new SqlString(dialect.GetSequenceNextValString(sequenceName));
		}
开发者ID:renefc3,项目名称:nhibernate,代码行数:38,代码来源:SequenceGenerator.cs


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