30 lines
911 B
C#
30 lines
911 B
C#
|
|
using Umbraco.Core.Composing;
|
|||
|
|
using Umbraco.Web.Trees;
|
|||
|
|
|
|||
|
|
// the namespace here is intentional - although defined in Umbraco.Web assembly,
|
|||
|
|
// this class should be visible when using Umbraco.Core.Components, alongside
|
|||
|
|
// Umbraco.Core's own CompositionExtensions class
|
|||
|
|
|
|||
|
|
// ReSharper disable once CheckNamespace
|
|||
|
|
namespace Umbraco.Extensions
|
|||
|
|
{
|
|||
|
|
/// <summary>
|
|||
|
|
/// Provides extension methods to the <see cref="Composition"/> class.
|
|||
|
|
/// </summary>
|
|||
|
|
public static class WebCompositionExtensions
|
|||
|
|
{
|
|||
|
|
#region Collection Builders
|
|||
|
|
|
|||
|
|
/// <summary>
|
|||
|
|
/// Gets the back office tree collection builder
|
|||
|
|
/// </summary>
|
|||
|
|
/// <param name="composition"></param>
|
|||
|
|
/// <returns></returns>
|
|||
|
|
public static TreeCollectionBuilder Trees(this Composition composition)
|
|||
|
|
=> composition.WithCollectionBuilder<TreeCollectionBuilder>();
|
|||
|
|
|
|||
|
|
#endregion
|
|||
|
|
|
|||
|
|
}
|
|||
|
|
}
|