本文整理汇总了C#中IContentLoader类的典型用法代码示例。如果您正苦于以下问题:C# IContentLoader类的具体用法?C# IContentLoader怎么用?C# IContentLoader使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IContentLoader类属于命名空间,在下文中一共展示了IContentLoader类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: TagsScheduledJob
public TagsScheduledJob()
{
IsStoppable = true;
_contentTypeRepository = ServiceLocator.Current.GetInstance<IContentTypeRepository>();
_tagService = ServiceLocator.Current.GetInstance<ITagService>();
_contentLoader = ServiceLocator.Current.GetInstance<IContentLoader>();
}
开发者ID:boyanin,项目名称:Tags,代码行数:7,代码来源:TagsScheduledJob.cs
示例2: InMemoryPriceDetailService
public InMemoryPriceDetailService(ReferenceConverter referenceConverter)
{
this._referenceConverter = referenceConverter;
_contentLoader = ServiceLocator.Current.GetInstance<IContentLoader>();
_relationRepository = ServiceLocator.Current.GetInstance<IRelationRepository>();
}
开发者ID:mmols,项目名称:pricing-providers,代码行数:7,代码来源:InMemoryPriceDetailService.cs
示例3: PageContextActionFilter
// private readonly ViewModelFactory _modelFactory;
/// <summary>
/// Initializes a new instance of the <see cref="PageContextActionFilter"/> class.
/// </summary>
public PageContextActionFilter(IContentLoader contentLoader, UrlResolver urlResolver, ILanguageBranchRepository languageBranchRepository, ISiteSettingsProvider siteConfiguration)
{
_contentLoader = contentLoader;
_urlResolver = urlResolver;
_languageBranchRepository = languageBranchRepository;
_siteConfiguration = siteConfiguration;
}
开发者ID:smchristenson,项目名称:CommerceStarterKit,代码行数:11,代码来源:PageContextActionFilter.cs
示例4: CartItemViewModelFactory
public CartItemViewModelFactory(
IContentLoader contentLoader,
IPricingService pricingService,
UrlResolver urlResolver,
ICurrentMarket currentMarket,
ICurrencyService currencyService,
IPromotionService promotionService,
AppContextFacade appContext,
ILineItemCalculator lineItemCalculator,
IProductService productService,
IRelationRepository relationRepository,
ICartService cartService)
{
_contentLoader = contentLoader;
_pricingService = pricingService;
_urlResolver = urlResolver;
_currentMarket = currentMarket;
_currencyService = currencyService;
_promotionService = promotionService;
_appContext = appContext;
_lineItemCalculator = lineItemCalculator;
_productService = productService;
_relationRepository = relationRepository;
_cartService = cartService;
}
开发者ID:adrian18hd,项目名称:Quicksilver,代码行数:25,代码来源:CartItemViewModelFactory.cs
示例5: FindProductUiSearchProvider
public FindProductUiSearchProvider(LocalizationService localizationService, ICatalogSystem catalogSystem, ReferenceConverter referenceConverter, IContentLoader contentLoader)
{
_catalogSystem = catalogSystem;
_localizationService = localizationService;
_catalogContext = catalogSystem;
_referenceConverter = referenceConverter;
_contentLoader = contentLoader;
}
开发者ID:smchristenson,项目名称:CommerceStarterKit,代码行数:8,代码来源:FindProductSearchProvider.cs
示例6: ReferencePropertyGetter
public ReferencePropertyGetter(IContentLoader contentLoader,
LocalizationService localizationService,
IContentTypeRepository contentTypeRepository)
{
_contentLoader = contentLoader;
_localizationService = localizationService;
_contentTypeRepository = contentTypeRepository;
}
开发者ID:VladimirLevchuk,项目名称:EPiProperties,代码行数:8,代码来源:ReferencePropertyGetter.cs
示例7: FilterOptionViewModelBinder
public FilterOptionViewModelBinder(IContentLoader contentLoader,
LocalizationService localizationService,
PreferredCultureAccessor preferredCulture)
{
_contentLoader = contentLoader;
_localizationService = localizationService;
_preferredCulture = preferredCulture();
}
开发者ID:bmcdavid,项目名称:Quicksilver,代码行数:8,代码来源:FilterOptionViewModelBinder.cs
示例8: EmailService
public EmailService(INotificationSettingsRepository notificationSettingsRepository, IEmailDispatcher emailDispatcher, ICurrentMarket currentMarket, IContentLoader contentLoader, IMarketService marketService)
{
_notificationSettingsRepository = notificationSettingsRepository;
_emailDispatcher = emailDispatcher;
_currentMarket = currentMarket;
_contentLoader = contentLoader;
_marketService = marketService;
}
开发者ID:smchristenson,项目名称:CommerceStarterKit,代码行数:8,代码来源:EmailService.cs
示例9: FilterOptionFormModelBinder
public FilterOptionFormModelBinder(IContentLoader contentLoader,
LocalizationService localizationService,
Func<CultureInfo> preferredCulture)
{
_contentLoader = contentLoader;
_localizationService = localizationService;
_preferredCulture = preferredCulture();
}
开发者ID:ocrenaka,项目名称:Quicksilver,代码行数:8,代码来源:FilterOptionFormModelBinder.cs
示例10: SyndicationItemFactory
public SyndicationItemFactory(IContentLoader contentLoader, IFeedContentResolver feedContentResolver, IFeedContentFilterer feedFilterer, IFeedDescriptionProvider feedDescriptionProvider, IContentCategoryLoader contentCategoryLoader)
{
ContentLoader = contentLoader;
ContentCategoryLoader = contentCategoryLoader;
FeedContentResolver = feedContentResolver ?? new FeedContentResolver(ContentLoader);
FeedFilterer = feedFilterer ?? new FeedContentFilterer();
FeedDescriptionProvider = feedDescriptionProvider ?? new FeedDescriptionProvider();
}
开发者ID:pappabj0rn,项目名称:Chief2moro.SyndicationFeeds,代码行数:8,代码来源:SyndicationItemFactory.cs
示例11: PageRatingController
public PageRatingController()
{
_reviewService = ServiceLocator.Current.GetInstance<IReviewService>();
_loader = ServiceLocator.Current.GetInstance<IContentLoader>();
contentAssetHelper = ServiceLocator.Current.GetInstance<ContentAssetHelper>();
_repository = ServiceLocator.Current.GetInstance<IContentRepository>();
_urlResolver = ServiceLocator.Current.GetInstance<UrlResolver>();
//_logger = logger;
}
开发者ID:ojarsb,项目名称:EpiRatingAlloySite,代码行数:9,代码来源:PageRatingController.cs
示例12: NavigationController
public NavigationController(IContentLoader contentLoader, ICartService cartService, ICartService wishListService, UrlHelper urlHelper, LocalizationService localizationService)
{
_contentLoader = contentLoader;
_cartService = cartService;
_wishListService = wishListService;
_urlHelper = urlHelper;
_localizationService = localizationService;
_wishListService.InitializeAsWishList();
}
开发者ID:ocrenaka,项目名称:Quicksilver,代码行数:10,代码来源:NavigationController.cs
示例13: CachingUrlResolver
public CachingUrlResolver(RouteCollection routes,
IContentLoader contentLoader,
SiteDefinitionRepository siteDefinitionRepository,
TemplateResolver templateResolver,
IPermanentLinkMapper permanentLinkMapper,
IObjectInstanceCache cache)
: base(routes, contentLoader, siteDefinitionRepository, templateResolver, permanentLinkMapper)
{
_cache = cache;
}
开发者ID:solita,项目名称:episerver-performance,代码行数:10,代码来源:CachingUrlResolver.cs
示例14: MailService
public MailService(HttpContextBase httpContextBase,
UrlResolver urlResolver,
IContentLoader contentLoader,
IHtmlDownloader htmlDownloader)
{
_httpContextBase = httpContextBase;
_urlResolver = urlResolver;
_contentLoader = contentLoader;
_htmlDownloader = htmlDownloader;
}
开发者ID:adrian18hd,项目名称:Quicksilver,代码行数:10,代码来源:MailService.cs
示例15: MarketContentLoader
/// <summary>
/// Initializes a new instance of the <see cref="MarketContentLoader" /> class.
/// </summary>
/// <param name="contentLoader">Service used to load content data.</param>
/// <param name="campaignInfoExtractor">Used to extract informations about campaigns and promotions.</param>
/// <param name="promotionProcessorResolver">The promotion processor resolver.</param>
public MarketContentLoader(
IContentLoader contentLoader,
CampaignInfoExtractor campaignInfoExtractor,
PromotionProcessorResolver promotionProcessorResolver)
{
_contentLoader = contentLoader;
_campaignInfoExtractor = campaignInfoExtractor;
_promotionProcessorResolver = promotionProcessorResolver;
}
开发者ID:adrian18hd,项目名称:Quicksilver,代码行数:16,代码来源:MarketContentLoader.cs
示例16: LevelScreen
public LevelScreen(IGameObjectsFactory gameObjectsFactory, IUserInterfaceFactory interfaceFactory,
IMathFunctionsFactory functionsFactory, ICamera2D camera2D, IContentLoader contentLoader)
{
this.contentLoader = contentLoader;
this.camera = camera2D;
player = new Player();
this.objectsFactory = gameObjectsFactory;
scene2d = new Scene2D(gameObjectsFactory, new GameplayFactory(gameObjectsFactory), interfaceFactory);
this.functionsFactory = functionsFactory;
}
开发者ID:HeavyBomber,项目名称:HeavyBomber,代码行数:10,代码来源:LevelScreen.cs
示例17: Register
public void Register(string extension, IContentLoader loader)
{
if (extension == null) throw new ArgumentNullException("extension");
if (loader == null) throw new ArgumentNullException("loader");
loaders[extension] = loader;
Tracer.TraceSource.TraceInformation("Registerd ContentLoader '{0}' for '{1}'",
loader.GetType().FullName, extension);
}
开发者ID:willcraftia,项目名称:WindowsGame,代码行数:10,代码来源:ContentLoaderRegistry.cs
示例18: RenderMainNavigation
public static void RenderMainNavigation(this HtmlHelper html, PageReference rootLink = null,
ContentReference contentLink = null,
bool includeRoot = true, IContentLoader contentLoader = null)
{
contentLink = contentLink ?? html.ViewContext.RequestContext.GetContentLink();
rootLink = rootLink ?? ContentReference.StartPage;
var writer = html.ViewContext.Writer;
// top level
writer.WriteLine("<nav class=\"navbar navbar-inverse\">");
writer.WriteLine("<ul class=\"nav navbar-nav\">");
if (includeRoot)
{
if (rootLink.CompareToIgnoreWorkID(contentLink))
{
writer.WriteLine("<li class=\"active\">");
}
else
{
writer.WriteLine("<li>");
}
writer.WriteLine(html.PageLink(rootLink).ToHtmlString());
writer.WriteLine("</li>");
}
// hämta ut alla barn från start
contentLoader = ServiceLocator.Current.GetInstance<IContentLoader>();
var topLevelPages = contentLoader.GetChildren<PageData>(rootLink);
topLevelPages = FilterForVisitor.Filter(topLevelPages).OfType<PageData>().Where(x => x.VisibleInMenu);
var currentBranch = contentLoader.GetAncestors(contentLink).Select(x => x.ContentLink).ToList();
currentBranch.Add(contentLink);
//skriv ut dom
foreach (var topLevelPage in topLevelPages)
{
if (currentBranch.Any(x => x.CompareToIgnoreWorkID(topLevelPage.ContentLink)))
{
writer.WriteLine("<li class=\"active\">");
}
else
{
writer.WriteLine("<li>");
}
writer.WriteLine(html.PageLink(topLevelPage).ToHtmlString());
writer.WriteLine("</li>");
}
//Close top level
writer.WriteLine("</ul");
writer.WriteLine("</nav>");
}
开发者ID:Siipikeisari,项目名称:fruitcorp,代码行数:55,代码来源:NavigationHelpers.cs
示例19: CreateMenuItem
private static MenuItem CreateMenuItem(PageData page, ContentReference currentContentLink, ContentReference rootLink, IContentLoader contentLoader, Func<IEnumerable<PageData>, IEnumerable<PageData>> filter)
{
var menuItem = new MenuItem
{
Page = page,
Selected = page.ContentLink.CompareToIgnoreWorkID(currentContentLink),
HasChildren = new Lazy<bool>(() => filter(contentLoader.GetChildren<PageData>(page.ContentLink)).Any()),
HasSelectedChildPage = new Lazy<bool>(() => HasSelectedChildPage(rootLink, currentContentLink, page))
};
return menuItem;
}
开发者ID:dnasir,项目名称:EPi.Extensions,代码行数:11,代码来源:HtmlHelperExtensions.cs
示例20: CartController
public CartController(IContentLoader contentLoader,
ICartService cartService,
ICartService wishListService,
IProductService productService)
{
_contentLoader = contentLoader;
_cartService = cartService;
_wishListService = wishListService;
_productService = productService;
_wishListService.InitializeAsWishList();
}
开发者ID:ocrenaka,项目名称:Quicksilver,代码行数:11,代码来源:CartController.cs
注:本文中的IContentLoader类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论