/// <summary> /// Initialize this module. Attach the worker method to the BeginRequest event. /// </summary> /// <param name="application">Current HttpApplication</param> public void Init(HttpApplication application) { _logger = DependencyResolver.Current.GetService <ILogger>(); _configuration = DependencyResolver.Current.GetService <IDD4TConfiguration>(); application.PreRequestHandlerExecute += new EventHandler(DistributionModule_OnPreRequestHandlerExecute); application.BeginRequest += new EventHandler(DistributionModule_OnBeginRequest); }
public FactoriesFacade(IPublicationResolver resolver, ILogger logger, IDD4TConfiguration configuration, ICacheAgent cacheAgent, ISerializerService serializerService) { if (resolver == null) { throw new ArgumentNullException("resolver"); } if (logger == null) { throw new ArgumentNullException("logger"); } if (configuration == null) { throw new ArgumentNullException("configuration"); } if (cacheAgent == null) { throw new ArgumentNullException("cacheAgent"); } if (serializerService == null) { throw new ArgumentNullException("serializerService"); } SerializerService = serializerService; Logger = logger; PublicationResolver = resolver; Configuration = configuration; CacheAgent = cacheAgent; }
public FactoryCommonServices(IPublicationResolver resolver, ILogger logger, IDD4TConfiguration configuration, ICacheAgent cacheAgent) { if (resolver == null) { throw new ArgumentNullException("resolver"); } if (logger == null) { throw new ArgumentNullException("logger"); } if (configuration == null) { throw new ArgumentNullException("configuration"); } if (cacheAgent == null) { throw new ArgumentNullException("cacheAgent"); } Logger = logger; PublicationResolver = resolver; Configuration = configuration; CacheAgent = cacheAgent; }
public PageController(IPageFactory pageFactor, IComponentPresentationFactory componentPresentationFactory, ILogger logger, IDD4TConfiguration configuration) : base(pageFactor, componentPresentationFactory, logger, configuration) { }
/// <summary> /// Initialize this module. Attach the worker method to the BeginRequest event. /// </summary> /// <param name="application">Current HttpApplication</param> public void Init(HttpApplication application) { _logger = DependencyResolver.Current.GetService<ILogger>(); _configuration = DependencyResolver.Current.GetService<IDD4TConfiguration>(); application.PreRequestHandlerExecute += new EventHandler(DistributionModule_OnPreRequestHandlerExecute); application.BeginRequest += new EventHandler(DistributionModule_OnBeginRequest); }
public XpmMarkupService(IDD4TConfiguration configuration) { if (configuration == null) throw new ArgumentNullException("configuration"); _configuration = configuration; }
public DefaultPublicationResolver(IDD4TConfiguration configuration) { if (configuration == null) throw new ArgumentException("configuration"); Configuration = configuration; }
public DxaCacheAgent(ILogger logger, IDD4TConfiguration configuration) { _logger = logger; _logger?.Debug("DxaCacheAgent implementation initialised successfully."); // create our cache provider from CIL to make use of the new caching system provided // that includes distributed caching, multi-level caching, etc. _cilCacheProvider = CacheFactory <object> .CreateFromConfiguration(); }
public UsesTridionPage(ILogger logger, IDD4TConfiguration configuration) { if (logger == null) throw new ArgumentNullException("logger"); _logger = logger; }
public DefaultPublicationResolver(IDD4TConfiguration configuration) { if (configuration == null) { throw new ArgumentException("configuration"); } Configuration = configuration; }
public XpmMarkupService(IDD4TConfiguration configuration) { if (configuration == null) { throw new ArgumentNullException("configuration"); } _configuration = configuration; }
public BaseProvider(IProvidersCommonServices providersCommonServices) { if (providersCommonServices == null) throw new ArgumentNullException("providersCommonServices"); LoggerService = providersCommonServices.Logger; PublicationResolver = providersCommonServices.PublicationResolver; Configuration = providersCommonServices.Configuration; }
public DefaultRichTextResolver(ILinkFactory linkFactory, ILogger logger, IDD4TConfiguration configuration) { if (linkFactory == null) throw new ArgumentNullException("linkFactory"); if (logger == null) throw new ArgumentNullException("logger"); if (configuration == null) throw new ArgumentNullException("configuration"); _linkFactory = linkFactory; _logger = logger; _configuration = configuration; }
public UsesTridionPage(ILogger logger, IDD4TConfiguration configuration) { if (logger == null) { throw new ArgumentNullException("logger"); } _logger = logger; }
public DefaultRichTextResolver(ILinkResolver linkResolver, ILogger logger, IDD4TConfiguration configuration) { Contract.ThrowIfNull(linkResolver, nameof(linkResolver)); Contract.ThrowIfNull(logger, nameof(logger)); Contract.ThrowIfNull(configuration, nameof(configuration)); _linkResolver = linkResolver; _logger = logger; _configuration = configuration; }
private const string URL = "navigation"; //TODO: should this be configurabale? public NavigationProvider(IContentProvider contentProvider, ILogger logger, IDD4TConfiguration configuration) { contentProvider.ThrowIfNull(nameof(contentProvider)); logger.ThrowIfNull(nameof(logger)); configuration.ThrowIfNull(nameof(configuration)); _configuration = configuration; _contentProvider = contentProvider; _logger = logger; }
public BaseProvider(IProvidersCommonServices providersCommonServices) { if (providersCommonServices == null) { throw new ArgumentNullException("providersCommonServices"); } LoggerService = providersCommonServices.Logger; PublicationResolver = providersCommonServices.PublicationResolver; Configuration = providersCommonServices.Configuration; }
public DefaultComponentPresentationRenderer(ILogger logger, IDD4TConfiguration configuration) { if (logger == null) throw new ArgumentNullException("logger"); if (configuration == null) throw new ArgumentNullException("configuration"); DefaultComponentPresentationRenderer._loggerService = logger; DefaultComponentPresentationRenderer._configuration = configuration; }
//Temp fix: Remove after 01-01-2016; IHttpMessageHandlerFactory is registered in the DI. //The DI needs to be upgraded for the registeration. below code prevent a runtime error in case that the DI is not upgraded. public BaseProvider(IProvidersCommonServices commonServices) { if (commonServices == null) { throw new ArgumentNullException("commonServices"); } Logger = commonServices.Logger; _httpMessageHandlerFactory = new DefaultHttpMessageHandlerFactory(); _publicationResolver = commonServices.PublicationResolver; Configuration = commonServices.Configuration; }
public FactoryBase(IFactoriesFacade facade) { if (facade == null) throw new ArgumentNullException("facade"); LoggerService = facade.Logger; PublicationResolver = facade.PublicationResolver; Configuration = facade.Configuration; CacheAgent = facade.CacheAgent; SerializerService = facade.SerializerService; CacheAgent.GetLastPublishDateCallBack = GetLastPublishedDateCallBack; }
public DefaultLinkResolver(ILinkFactory linkFactory, ILogger logger, IBinaryFactory binaryFactory, IDD4TConfiguration configuration) { Contract.ThrowIfNull(linkFactory, nameof(linkFactory)); Contract.ThrowIfNull(binaryFactory, nameof(binaryFactory)); Contract.ThrowIfNull(logger, nameof(logger)); Contract.ThrowIfNull(configuration, nameof(configuration)); _binaryFactory = binaryFactory; _linkFactory = linkFactory; _logger = logger; _configuration = configuration; }
public FactoryBase(IFactoryCommonServices factoryCommonServices) { if (factoryCommonServices == null) { throw new ArgumentNullException("factoryCommonServices"); } LoggerService = factoryCommonServices.Logger; PublicationResolver = factoryCommonServices.PublicationResolver; Configuration = factoryCommonServices.Configuration; CacheAgent = factoryCommonServices.CacheAgent; }
public WebConfigViewModelKeyProvider(IDD4TConfiguration configuration) { if (configuration == null) { throw new ArgumentNullException("configuration"); } ViewModelKeyField = configuration.ViewModelKeyField; if (string.IsNullOrEmpty(ViewModelKeyField)) { ViewModelKeyField = "viewModelKey"; //Default value } }
public FactoryBase(IFactoriesFacade facade) { if (facade == null) { throw new ArgumentNullException("facade"); } LoggerService = facade.Logger; PublicationResolver = facade.PublicationResolver; Configuration = facade.Configuration; CacheAgent = facade.CacheAgent; SerializerService = facade.SerializerService; CacheAgent.GetLastPublishDateCallBack = GetLastPublishedDateCallBack; }
//private readonly IBinaryFactory _binaryFactory; public DefaultRichTextResolver(ILinkResolver linkResolver, ILogger logger, IDD4TConfiguration configuration) { //binaryFactory.ThrowIfNull(nameof(binaryFactory)); //linkFactory.ThrowIfNull(nameof(linkFactory)); Contract.ThrowIfNull(linkResolver, nameof(linkResolver)); Contract.ThrowIfNull(logger, nameof(logger)); Contract.ThrowIfNull(configuration, nameof(configuration)); //_binaryFactory = binaryFactory; //_linkFactory = linkFactory; _linkResolver = linkResolver; _logger = logger; _configuration = configuration; }
public DefaultComponentPresentationRenderer(ILogger logger, IDD4TConfiguration configuration) { if (logger == null) { throw new ArgumentNullException("logger"); } if (configuration == null) { throw new ArgumentNullException("configuration"); } DefaultComponentPresentationRenderer._loggerService = logger; DefaultComponentPresentationRenderer._configuration = configuration; }
public ProvidersCommonServices(IPublicationResolver resolver, ILogger logger, IDD4TConfiguration configuration) { if (resolver == null) throw new ArgumentNullException("resolver"); if (logger == null) throw new ArgumentNullException("logger"); if (configuration == null) throw new ArgumentNullException("configuration"); Logger = logger; PublicationResolver = resolver; Configuration = configuration; }
public DefaultCacheAgent(IDD4TConfiguration configuration, ILogger logger) { if (configuration == null) { throw new ArgumentNullException("configuration"); } if (logger == null) { throw new ArgumentNullException("logger"); } _logger = logger; _configuration = configuration; }
static TridionHelper() { //this is Anti-Pattern, there is no other way to inject dependencies into this class. //This helper should not be used in views, this logic should get executed by the controller. var config = DependencyResolver.Current.GetService<IDD4TConfiguration>(); var linkFactory = DependencyResolver.Current.GetService<ILinkFactory>(); var logger = DependencyResolver.Current.GetService<ILogger>(); var renderer = DependencyResolver.Current.GetService<IComponentPresentationRenderer>(); _linkFactory = linkFactory; _configuration = config; _logger = logger; _renderer = renderer; }
static TridionHelper() { //this is Anti-Pattern, there is no other way to inject dependencies into this class. //This helper should not be used in views, this logic should get executed by the controller. var config = DependencyResolver.Current.GetService <IDD4TConfiguration>(); var linkFactory = DependencyResolver.Current.GetService <ILinkFactory>(); var logger = DependencyResolver.Current.GetService <ILogger>(); var renderer = DependencyResolver.Current.GetService <IComponentPresentationRenderer>(); _linkFactory = linkFactory; _configuration = config; _logger = logger; _renderer = renderer; }
public TridionSiteMapProvider(IPageFactory pageFactory, ICacheAgent cacheAgent, ILogger logger, IDD4TConfiguration configuration) { if (pageFactory == null) throw new ArgumentNullException("pageFactory"); if (logger == null) throw new ArgumentNullException("logger"); if (configuration == null) throw new ArgumentNullException("configuration"); if (cacheAgent == null) throw new ArgumentNullException("cacheAgent"); _pageFactory = pageFactory; _configuration = configuration; _cacheAgent = cacheAgent; _logger = logger; }
public JMSMessageProvider(ILogger logger, IDD4TConfiguration configuration) { if (logger == null) { throw new ArgumentNullException(nameof(logger)); } if (configuration == null) { throw new ArgumentNullException(nameof(configuration)); } _logger = logger; _configuration = configuration; _observers = new List <IObserver <ICacheEvent> >(); }
public TridionBackedCacheAgent(IDD4TConfiguration configuration, ILogger logger, IPageFactory pageFactory, IComponentPresentationFactory componentpresentationFactory) { if (configuration == null) { throw new ArgumentNullException("configuration"); } if (logger == null) { throw new ArgumentNullException("logger"); } _logger = logger; _configuration = configuration; _pageFactory = pageFactory; _componentPresentationFactory = componentpresentationFactory; }
public DefaultCacheAgent(IDD4TConfiguration configuration, ILogger logger) { if (configuration == null) { throw new ArgumentNullException("configuration"); } if (logger == null) { throw new ArgumentNullException("logger"); } _logger = logger; // add hardcoded file system logger because for some reason log4net does not work on a background thread _backgroundlogger = new FSLogger(); _configuration = configuration; }
public FactoryCommonServices(IPublicationResolver resolver, ILogger logger, IDD4TConfiguration configuration, ICacheAgent cacheAgent) { if (resolver == null) throw new ArgumentNullException("resolver"); if (logger == null) throw new ArgumentNullException("logger"); if (configuration == null) throw new ArgumentNullException("configuration"); if (cacheAgent == null) throw new ArgumentNullException("cacheAgent"); Logger = logger; PublicationResolver = resolver; Configuration = configuration; CacheAgent = cacheAgent; }
public ProvidersCommonServices(IPublicationResolver resolver, ILogger logger, IDD4TConfiguration configuration) { if (resolver == null) { throw new ArgumentNullException("resolver"); } if (logger == null) { throw new ArgumentNullException("logger"); } if (configuration == null) { throw new ArgumentNullException("configuration"); } Logger = logger; PublicationResolver = resolver; Configuration = configuration; }
//private readonly IExtendedPublicationResolver _publicationResolver; public DefaultContentProvider(IPageFactory pageFactory, IComponentPresentationFactory componentPresentationFactory, IViewModelFactory viewModelFactory, ILogger logger, //IExtendedPublicationResolver publicationResolver, IDD4TConfiguration configuration) { pageFactory.ThrowIfNull(nameof(pageFactory)); viewModelFactory.ThrowIfNull(nameof(viewModelFactory)); logger.ThrowIfNull(nameof(logger)); componentPresentationFactory.ThrowIfNull(nameof(componentPresentationFactory)); configuration.ThrowIfNull(nameof(configuration)); //publicationResolver.ThrowIfNull(nameof(publicationResolver)); //this._publicationResolver = publicationResolver; this._pageFactory = pageFactory; this._viewModelFactory = viewModelFactory; this._componentPresentationFactory = componentPresentationFactory; this._logger = logger; this._configuration = configuration; }
public DD4TControllerBase(IPageFactory pageFactory, IComponentPresentationFactory componentPresentationFactory, ILogger logger, IDD4TConfiguration dd4tConfiguration) { if (pageFactory == null) { throw new ArgumentNullException("pageFactory"); } if (componentPresentationFactory == null) { throw new ArgumentNullException("componentPresentationFactory"); } if (logger == null) { throw new ArgumentNullException("logger"); } LoggerService = logger; PageFactory = pageFactory; ComponentPresentationFactory = componentPresentationFactory; DD4TConfiguration = dd4tConfiguration; }
public FactoriesFacade(IPublicationResolver resolver, ILogger logger, IDD4TConfiguration configuration, ICacheAgent cacheAgent, ISerializerService serializerService) { if (resolver == null) throw new ArgumentNullException("resolver"); if (logger == null) throw new ArgumentNullException("logger"); if (configuration == null) throw new ArgumentNullException("configuration"); if (cacheAgent == null) throw new ArgumentNullException("cacheAgent"); if (serializerService == null) throw new ArgumentNullException("serializerService"); SerializerService = serializerService; Logger = logger; PublicationResolver = resolver; Configuration = configuration; CacheAgent = cacheAgent; }
public TridionSiteMapProvider(IPageFactory pageFactory, ICacheAgent cacheAgent, ILogger logger, IDD4TConfiguration configuration) { if (pageFactory == null) { throw new ArgumentNullException("pageFactory"); } if (logger == null) { throw new ArgumentNullException("logger"); } if (configuration == null) { throw new ArgumentNullException("configuration"); } if (cacheAgent == null) { throw new ArgumentNullException("cacheAgent"); } _pageFactory = pageFactory; _configuration = configuration; _cacheAgent = cacheAgent; _logger = logger; }
public WebConfigViewModelKeyProvider(IDD4TConfiguration configuration) { if (configuration == null) throw new ArgumentNullException("configuration"); ViewModelKeyField = configuration.ViewModelKeyField; if (string.IsNullOrEmpty(ViewModelKeyField)) ViewModelKeyField = "viewModelKey"; //Default value }
public ModelControllerBase(IPageFactory pageFactory, IComponentPresentationFactory componentPresentationFactory, ILogger logger, IDD4TConfiguration dd4tConfiguration, IViewModelFactory viewModelFactory) : base(pageFactory, componentPresentationFactory, logger, dd4tConfiguration) { this.ViewModelFactory = viewModelFactory; }
public RenderDataAttribute() { DD4TConfiguration = DependencyResolver.Current.GetService<IDD4TConfiguration>(); }
public JMSMessageProvider(ILogger logger, IDD4TConfiguration dd4tConfiguration) { Logger = logger; DD4TConfiguration = dd4tConfiguration; observers = new List <IObserver <ICacheEvent> >(); }
public RenderDataAttribute() { DD4TConfiguration = DependencyResolver.Current.GetService <IDD4TConfiguration>(); }
public TridionControllerBase(IPageFactory pageFactory, IComponentPresentationFactory componentPresentationFactory, ILogger logger, IDD4TConfiguration dd4tConfiguration) : base(pageFactory, componentPresentationFactory, logger, dd4tConfiguration) { }