Table of Contents

Class ContentItemCacheDependencyBuilder

Namespace
CMS.ContentEngine
Assembly
CMS.ContentEngine.dll

Represents a builder for cache dependencies of content items. CacheDependencyBuilder IContentItemFieldsSource

public sealed class ContentItemCacheDependencyBuilder
Inheritance
object
ContentItemCacheDependencyBuilder
Extension Methods

Methods

All()

Adds a dependency on all content items.

public ContentItemCacheDependencyBuilder All()

Returns

ContentItemCacheDependencyBuilder

The ContentItemCacheDependencyBuilder instance for method chaining.

Builder()

Returns the root CacheDependencyBuilder.

public CacheDependencyBuilder Builder()

Returns

CacheDependencyBuilder

ByCodeName(string, string)

Adds a dependency on content item with the given code name.

public ContentItemCacheDependencyBuilder ByCodeName(string codeName, string languageName = null)

Parameters

codeName string

The code name of the content item.

languageName string

Name of the language. If not specified, all languages are considered.

Returns

ContentItemCacheDependencyBuilder

The ContentItemCacheDependencyBuilder instance for method chaining.

ByContentType<T>(string)

Adds a dependency on content items with the given content type.

public ContentItemCacheDependencyBuilder ByContentType<T>(string languageName = null) where T : IContentItemFieldsSource

Parameters

languageName string

Name of the language. If not specified, all languages are considered.

Returns

ContentItemCacheDependencyBuilder

The ContentItemCacheDependencyBuilder instance for method chaining.

Type Parameters

T

Model representing the content type.

ByGuid(Guid, string)

Adds a dependency on content item with the given GUID.

public ContentItemCacheDependencyBuilder ByGuid(Guid guid, string languageName = null)

Parameters

guid Guid

The GUID of the content item.

languageName string

Name of the language. If not specified, all languages are considered.

Returns

ContentItemCacheDependencyBuilder

The ContentItemCacheDependencyBuilder instance for method chaining.

ById(int, string)

Adds a dependency on content item with the given ID.

public ContentItemCacheDependencyBuilder ById(int id, string languageName = null)

Parameters

id int

The ID of the content item.

languageName string

Name of the language. If not specified, all languages are considered.

Returns

ContentItemCacheDependencyBuilder

The ContentItemCacheDependencyBuilder instance for method chaining.