Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Pav 15 posts 45 karma points
    Nov 27, 2013 @ 17:12
    Pav
    0

    Injection of IPublishedContent using AutoFac

    I would like to inject IPublishedContent into my implementation of class that depends on it.

    public class DocumentDataSource : IDocumentDataSource{

       public DocumentDataSource(IPublishedContent publishedContentcontent){
          }
     }

    I am using this in my MVC Controller, while hijacking the route.

    How do I register  IPublishedContent  using AutoFac specific for the content I am in?

    Because before introducing IPuiblishedContent into contructor my resolver worked.

    Now its saying that I cannot resolve IPublishedContent publishedContentcontent

     

     

     

     

  • alper 8 posts 55 karma points
    Feb 24, 2015 @ 09:59
Please Sign in or register to post replies

Write your reply to:

Draft