2012-08-10 13:38:02 +06:00
|
|
|
using Umbraco.Core.ObjectResolution;
|
|
|
|
|
|
|
|
|
|
namespace Umbraco.Web
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
2012-09-14 09:09:23 +07:00
|
|
|
/// An object resolver to return the IPublishedContentStore
|
2012-08-10 13:38:02 +06:00
|
|
|
/// </summary>
|
2013-01-23 18:40:40 +03:00
|
|
|
internal sealed class PublishedContentStoreResolver : SingleObjectResolverBase<PublishedContentStoreResolver, IPublishedContentStore>
|
2012-08-10 13:38:02 +06:00
|
|
|
{
|
2012-09-08 11:59:01 +07:00
|
|
|
internal PublishedContentStoreResolver(IPublishedContentStore publishedContentStore)
|
2012-08-17 04:27:47 +06:00
|
|
|
: base(publishedContentStore)
|
2012-08-15 23:20:37 +06:00
|
|
|
{
|
|
|
|
|
}
|
2012-08-10 13:38:02 +06:00
|
|
|
|
2012-08-15 23:20:37 +06:00
|
|
|
/// <summary>
|
|
|
|
|
/// Can be used by developers at runtime to set their IContentStore at app startup
|
|
|
|
|
/// </summary>
|
2012-08-17 04:27:47 +06:00
|
|
|
/// <param name="publishedContentStore"></param>
|
|
|
|
|
public void SetContentStore(IPublishedContentStore publishedContentStore)
|
2012-08-15 23:20:37 +06:00
|
|
|
{
|
2012-08-17 04:27:47 +06:00
|
|
|
Value = publishedContentStore;
|
2012-08-15 23:20:37 +06:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Returns the IContentStore
|
|
|
|
|
/// </summary>
|
2012-08-17 04:27:47 +06:00
|
|
|
public IPublishedContentStore PublishedContentStore
|
2012-08-15 23:20:37 +06:00
|
|
|
{
|
|
|
|
|
get { return Value; }
|
|
|
|
|
}
|
2012-08-10 13:38:02 +06:00
|
|
|
}
|
|
|
|
|
}
|