using Umbraco.Core; using Umbraco.Web.Composing; using Umbraco.Core.Models.PublishedContent; namespace Umbraco.Web { /// /// Provides extension methods for IPublishedProperty. /// public static class PublishedPropertyExtension { // see notes in PublishedElementExtensions // private static IPublishedValueFallback PublishedValueFallback => Current.PublishedValueFallback; #region Value public static object Value(this IPublishedProperty property, string culture = null, string segment = null, Fallback fallback = default, object defaultValue = default) { return property.Value(PublishedValueFallback, culture, segment, fallback, defaultValue); } #endregion #region Value public static T Value(this IPublishedProperty property, string culture = null, string segment = null, Fallback fallback = default, T defaultValue = default) { return property.Value(PublishedValueFallback, culture, segment, fallback, defaultValue); } #endregion } }