public PostsController(PostServices postServices,TagServices tagService ,CommentServices commentService,AppConfiguration config)
 {
     this.postServices = postServices;
     this.commentService = commentService;
     this.tagService = tagService;
     this.config = config;
 }
 public CommentServices(ICommentRepository commentRepository, IPostRepository postRepository, UserServices userServices, AppConfiguration config)
 {
     this.commentRepository = commentRepository;
     this.config = config;
     this.userServices = userServices;
     this.postRepository = postRepository;
 }
        public DataSessionFactoryProvider(AppConfiguration configuration)
        {
            config = configuration;

            Assembly entityAssembly = Assembly.Load(EntityAssembly);

            factory = Fluently.Configure()
                .Database(MsSqlConfiguration.MsSql2005.ConnectionString(config.ConnectionString))
                .Mappings(m => m.FluentMappings
                                   .AddFromAssembly(entityAssembly)
                )
                .ExposeConfiguration(c => c.EventListeners.PostInsertEventListeners = new IPostInsertEventListener[] {new NHibernateEventListener()})
                .ExposeConfiguration(c => c.EventListeners.PostUpdateEventListeners = new IPostUpdateEventListener[] { new NHibernateEventListener() })
                .BuildSessionFactory();
        }
示例#4
0
 public PostServices(IPostRepository postRepository, ITagRepository tagRepository, AppConfiguration config)
 {
     this.postRepository = postRepository;
     this.tagRepository = tagRepository;
     this.config = config;
 }
示例#5
0
 public UserRepository(AppConfiguration config, DbContext ctx)
     : base(ctx)
 {
     this.config = config;
 }
示例#6
0
 public PostRepository(ITagRepository tagRepository, AppConfiguration config, DbContext ctx)
     : base(ctx)
 {
     this.config = config;
     this.tagRepository = tagRepository;
 }
示例#7
0
 public TagServices(ITagRepository tagRepository, AppConfiguration config)
 {
     this.tagRepository = tagRepository;
     this.config = config;
 }
示例#8
0
 public HomeController(PostServices postService, AppConfiguration config,ILog logger)
     : base(logger)
 {
     this.postService = postService;
 }
示例#9
0
 public UserServices(IUserRepository userRepository, AppConfiguration config)
 {
     this.userRepository = userRepository;
     this.config = config;
 }
示例#10
0
 public WidgetController(PostServices postService, AppConfiguration config, ILog logger)
     : base(logger)
 {
     this.postService = postService;
     this.config = config;
 }