using System; using System.Collections.Generic; using System.Linq; using Umbraco.Core.Models; using Umbraco.Core.Models.PublishedContent; using Umbraco.Web.Models; namespace Umbraco.Web.PublishedCache { public interface IPublishedContentCache : IPublishedCache { /// /// Gets content identified by a route. /// /// The context. /// A value indicating whether to consider unpublished content. /// The route /// A value forcing the HideTopLevelNode setting. /// The content, or null. /// /// A valid route is either a simple path eg /foo/bar/nil or a root node id and a path, eg 123/foo/bar/nil. /// If is null then the settings value is used. /// The value of overrides the context. /// IPublishedContent GetByRoute(UmbracoContext umbracoContext, bool preview, string route, bool? hideTopLevelNode = null); /// /// Gets the route for a content identified by its unique identifier. /// /// The context. /// A value indicating whether to consider unpublished content. /// The content unique identifier. /// The route. /// The value of overrides the context. string GetRouteById(UmbracoContext umbracoContext, bool preview, int contentId); /// /// Creates a detached property. /// /// The published property type. /// The value. /// A value indicating whether the property is created within a previewing context. /// A detached property. /// Implementations must check that propertyType.IsDetachedOrNested is true. IPublishedProperty CreateDetachedProperty(PublishedPropertyType propertyType, object value, bool isPreviewing); } }