Table of Contents

Interface ITaxonomyManager

Namespace
CMS.ContentEngine
Assembly
CMS.ContentEngine.dll

Manager for taxonomy operations.

public interface ITaxonomyManager
Extension Methods

Methods

DeleteTag(int, CancellationToken)

Deletes a tag including all children tags.

Task DeleteTag(int tagId, CancellationToken cancellationToken = default)

Parameters

tagId int

Tag ID.

cancellationToken CancellationToken

Cancellation instruction.

Returns

Task

DeleteTaxonomy(int, CancellationToken)

Deletes taxonomy with all tags if it is not used.

Task<bool> DeleteTaxonomy(int taxonomyId, CancellationToken cancellationToken = default)

Parameters

taxonomyId int

Taxonomy ID.

cancellationToken CancellationToken

Cancellation instruction.

Returns

Task<bool>

True when deleted or taxonomy does not exist, false when taxonomy is in use.

MoveTag(int, int, int, CancellationToken)

Moves a tag to a new parent tag.

Task MoveTag(int tagId, int targetParentTagId, int order, CancellationToken cancellationToken = default)

Parameters

tagId int

Tag identifier.

targetParentTagId int

Target parent tag identifier.

order int

New order of the tag.

cancellationToken CancellationToken

Cancellation instruction.

Returns

Task

Remarks

If the tag should be moved under the root the targetParentTagId should be 0.