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


C# IResultTransformer类代码示例

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


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

示例1: Init

 public void Init(ISession session, ISearchFactoryImplementor searchFactoryImplementor,
                  IResultTransformer transformer, string[] aliases)
 {
     Init(session, searchFactoryImplementor);
     this.transformer = transformer;
     this.aliases = aliases;
 }
开发者ID:kstenson,项目名称:NHibernate.Search,代码行数:7,代码来源:ProjectionLoader.cs

示例2: Session

 public Session(IResultTransformer resultTransformer, IDao<Bank> bankDao, IDao<LogModel> logDao, IDao<Customer> customerDao) 
     : base(resultTransformer)
 {
     this.bankDao = bankDao;
     this.logDao = logDao;
     this.customerDao = customerDao;
 }
开发者ID:BosphorusTeam,项目名称:bosphorus.dao,代码行数:7,代码来源:Session.cs

示例3: GetResultColumnOrRow

		protected override object GetResultColumnOrRow(object[] row, IResultTransformer resultTransformer, IDataReader rs,
		                                               ISessionImplementor session)
		{
			object[] result;
			string[] aliases;

			if (translator.HasProjection)
			{
				IType[] types = translator.ProjectedTypes;
				result = new object[types.Length];
				string[] columnAliases = translator.ProjectedColumnAliases;

				for (int i = 0; i < result.Length; i++)
				{
					result[i] = types[i].NullSafeGet(rs, columnAliases[i], session, null);
				}
				aliases = translator.ProjectedAliases;
			}
			else
			{
				result = row;
				aliases = userAliases;
			}
			return translator.RootCriteria.ResultTransformer.TransformTuple(result, aliases);
		}
开发者ID:hazzik,项目名称:nh-contrib-everything,代码行数:25,代码来源:CriteriaLoader.cs

示例4: SetResultTransformerIfNotNull

 public static void SetResultTransformerIfNotNull(this ICriteria criteria, IResultTransformer transformer)
 {
     if (transformer != null)
         criteria.SetResultTransformer(transformer);
     else
         criteria.SetResultTransformer(new RootEntityResultTransformer());
 }
开发者ID:hazzik,项目名称:nh-contrib-everything,代码行数:7,代码来源:CriteriaUtil.cs

示例5: GetHolderInstantiator

		public static HolderInstantiator GetHolderInstantiator(IResultTransformer selectNewTransformer,
		                                                       IResultTransformer customTransformer,
		                                                       string[] queryReturnAliases)
		{
			return new HolderInstantiator(ResolveResultTransformer(selectNewTransformer, customTransformer),
			                              queryReturnAliases);
		}
开发者ID:NikGovorov,项目名称:nhibernate-core,代码行数:7,代码来源:HolderInstantiator.cs

示例6: LinqProvider

        //this.Add("LinqProvider - LinQ Equals ", () => from model in accountDao.Query() where model.No  == 0L select model);
        //this.Add("LinqProvider - LinQ Oracle Left Join", () =>
        //    from model in accountDao.Query()
        //    from customer in bankDao.Query()
        //    where model.Customer.Id == customer.Id.OraclePlus()
        //    select model);

        public LinqProvider(IResultTransformer resultTransformer, IDao<Customer> customerDao, IDao<Account> accountDao) 
            : base(resultTransformer)
        {
            this.customerDao = customerDao;
            this.accountDao = accountDao;
            inList = new[] {"Onur", "Oğuz"};
        }
开发者ID:BosphorusTeam,项目名称:bosphorus.dao,代码行数:14,代码来源:LinqProvider.cs

示例7: Session

 public Session(IResultTransformer resultTransformer, IDao<Bank> bankDao, IDao<LogModel> logDao, ISessionProviderFactory<NHibernateStatelessSession> sessionProviderFactory) 
     : base(resultTransformer)
 {
     this.bankDao = bankDao;
     this.logDao = logDao;
     logSessionProvider = sessionProviderFactory.Build("LOG");
 }
开发者ID:BosphorusTeam,项目名称:bosphorus.dao,代码行数:7,代码来源:Session.cs

示例8: AutoMap

 public AutoMap(IResultTransformer resultTransformer, IDao<Bank> bankDao, IDao<Account> accountDao, IDao<Customer> customerDao, IMapper mapper) 
     : base(resultTransformer)
 {
     this.bankDao = bankDao;
     this.accountDao = accountDao;
     this.customerDao = customerDao;
     this.mapper = mapper;
 }
开发者ID:BosphorusTeam,项目名称:bosphorus.dao,代码行数:8,代码来源:AutoMap.cs

示例9: GetCustomerOrderHistory

        private static IList<CustomerOrderHistory> GetCustomerOrderHistory(string customerId, IResultTransformer transformer) {
            var query =
                UnitOfWork.CurrentSession.GetNamedQuery("NSoft.NFramework.Data.NHibernateEx.Domain.Northwind.GetCustomerOrderHistory",
                                                        new NHParameter("CustomerId", customerId, TypeFactory.GetStringType(255)));

            query.SetResultTransformer(transformer);
            return query.List<CustomerOrderHistory>();
        }
开发者ID:debop,项目名称:NFramework,代码行数:8,代码来源:CustomerOrderHistoryFixture.cs

示例10: HolderInstantiator

		public HolderInstantiator(
			IResultTransformer transformer,
			string[] queryReturnAliases
			)
		{
			this.transformer = transformer;
			this.queryReturnAliases = queryReturnAliases;
		}
开发者ID:Novthirteen,项目名称:sconit_timesseiko,代码行数:8,代码来源:HolderInstantiator.cs

示例11: QueryParameters

		public QueryParameters(IType[] positionalParameterTypes, object[] positionalParameterValues,
		                       IDictionary<string, LockMode> lockModes, RowSelection rowSelection, bool cacheable,
		                       string cacheRegion, string comment, bool isLookupByNaturalKey, IResultTransformer transformer)
			: this(
				positionalParameterTypes, positionalParameterValues, null, lockModes, rowSelection, false, cacheable, cacheRegion,
				comment, null, transformer)
		{
			NaturalKeyLookup = isLookupByNaturalKey;
		}
开发者ID:hazzik,项目名称:nh-contrib-everything,代码行数:9,代码来源:QueryParameters.cs

示例12: QueryParameters

		public QueryParameters(IDictionary<string, TypedValue> namedParameters, IDictionary<string, LockMode> lockModes, RowSelection rowSelection, bool isReadOnlyInitialized,
		                       bool readOnly, bool cacheable, string cacheRegion, string comment, bool isLookupByNaturalKey, IResultTransformer transformer)
			: this(
				ArrayHelper.EmptyTypeArray, ArrayHelper.EmptyObjectArray, namedParameters, lockModes, rowSelection, isReadOnlyInitialized, readOnly, cacheable, cacheRegion, comment, null,
				transformer)
		{
			// used by CriteriaTranslator
			NaturalKeyLookup = isLookupByNaturalKey;
		}
开发者ID:Ruhollah,项目名称:nhibernate-core,代码行数:9,代码来源:QueryParameters.cs

示例13: GetHolderInstantiator

		public static HolderInstantiator GetHolderInstantiator(IResultTransformer selectNewTransformer,
		                                                       IResultTransformer customTransformer,
		                                                       string[] queryReturnAliases)
		{
            //todo ÐÞ¸ÄÔ´Âë
            if (customTransformer != null)
                return new HolderInstantiator(customTransformer, queryReturnAliases);
            else
                return new HolderInstantiator(selectNewTransformer, queryReturnAliases);
		}
开发者ID:Mrding,项目名称:Ribbon,代码行数:10,代码来源:HolderInstantiator.cs

示例14: CreateClassicHolderInstantiator

		public static HolderInstantiator CreateClassicHolderInstantiator(ConstructorInfo constructor,
		                                                                 IResultTransformer transformer)
		{
			if (constructor != null)
			{
				return new HolderInstantiator(new AliasToBeanConstructorResultTransformer(constructor), null);
			}
			else
			{
				return new HolderInstantiator(transformer, null);
			}
		}
开发者ID:Mrding,项目名称:Ribbon,代码行数:12,代码来源:HolderInstantiator.cs

示例15: GetHolderInstantiator

		public static HolderInstantiator GetHolderInstantiator(IResultTransformer selectNewTransformer,
		                                                       IResultTransformer customTransformer,
		                                                       string[] queryReturnAliases)
		{
			if (selectNewTransformer != null)
			{
				return new HolderInstantiator(selectNewTransformer, queryReturnAliases);
			}
			else
			{
				return new HolderInstantiator(customTransformer, queryReturnAliases);
			}
		}
开发者ID:Novthirteen,项目名称:sconit_timesseiko,代码行数:13,代码来源:HolderInstantiator.cs


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