Table of Contents

Class DynamicStructureService

Namespace
Dynamicweb.Indexing.DynamicStructuring
Assembly
Dynamicweb.Core.dll

The class DynamicStructureService provids different methods for querying and saving the dynamic structures.

public class DynamicStructureService
Inheritance
DynamicStructureService
Inherited Members

Methods

ClearCache()

Clear dynamic structures cache.

public void ClearCache()

Delete(IEnumerable<Guid>)

Delete the dynamic structure.

public void Delete(IEnumerable<Guid> dynamicStructureIds)

Parameters

dynamicStructureIds IEnumerable<Guid>

The dynamic structures

Delete(IEnumerable<string>)

Delete the dynamic structure.

public void Delete(IEnumerable<string> dynamicStructureIds)

Parameters

dynamicStructureIds IEnumerable<string>

The dynamic structures

Delete(Guid)

Delete the dynamic structure.

public void Delete(Guid dynamicStructureId)

Parameters

dynamicStructureId Guid

The dynamic structure

Delete(string)

Delete the dynamic structure.

public void Delete(string dynamicStructureId)

Parameters

dynamicStructureId string

The dynamic structure

DeleteStructureLevel(string, int)

Delete the dynamic structure.

public void DeleteStructureLevel(string dynamicStructureId, int levelId)

Parameters

dynamicStructureId string

The dynamic structure

levelId int

DeleteStructureLevels(string)

Delete the dynamic structure.

public void DeleteStructureLevels(string dynamicStructureId)

Parameters

dynamicStructureId string

The dynamic structure

GetAll()

Gets all dynamic structures.

public IEnumerable<DynamicStructure> GetAll()

Returns

IEnumerable<DynamicStructure>

GetById(Guid)

Gets the dynamic structure by id.

public DynamicStructure GetById(Guid dynamicStructureId)

Parameters

dynamicStructureId Guid

The dynamic structure id

Returns

DynamicStructure

GetById(string)

Gets the dynamic structure by id.

public DynamicStructure GetById(string dynamicStructureId)

Parameters

dynamicStructureId string

The dynamic structure id

Returns

DynamicStructure

GetDynamicStructureChildLevels(DynamicStructure, DynamicStructureLevelScope)

Gets child levels for current level scope

public static IEnumerable<DynamicStructureLevel> GetDynamicStructureChildLevels(DynamicStructure dynamicStructure, DynamicStructureLevelScope scope)

Parameters

dynamicStructure DynamicStructure

The dynamicStructure containing levels info.

scope DynamicStructureLevelScope

The level scope with previous levels values

Returns

IEnumerable<DynamicStructureLevel>

The collection of child levels for current level scope.

GetDynamicStructureScopeParameters(DynamicStructureLevelScope)

Gets dictionary of query parameters for specific scope.

public Dictionary<string, string> GetDynamicStructureScopeParameters(DynamicStructureLevelScope scope)

Parameters

scope DynamicStructureLevelScope

The level scope.

Returns

Dictionary<string, string>

GetDynamicStructureScopeParameters(List<DynamicStructureLevel>, List<string>)

Gets dictionary of query parameters based on structure level and scope values.

public static Dictionary<string, string> GetDynamicStructureScopeParameters(List<DynamicStructureLevel> dynamicStructureLevels, List<string> values)

Parameters

dynamicStructureLevels List<DynamicStructureLevel>

The structure levels.

values List<string>

The level scope values.

Returns

Dictionary<string, string>

GetNoMatchLevel(DynamicStructure, DynamicStructureLevelScope)

Gets no match level for current level scope

public static DynamicStructureLevel GetNoMatchLevel(DynamicStructure dynamicStructure, DynamicStructureLevelScope structureScope)

Parameters

dynamicStructure DynamicStructure

The dynamicStructure containing levels info.

structureScope DynamicStructureLevelScope

The level scope with previous levels values

Returns

DynamicStructureLevel

'No match' level if according to structure scope there are results with empty values, otherwise null

Save(DynamicStructure)

Saves the dynamic structure.

public void Save(DynamicStructure dynamicStructure)

Parameters

dynamicStructure DynamicStructure

The dynamic structure

UpdateStructureLevelsSourceField(IEnumerable<DynamicStructure>, string, string)

Finds the needed source field in levels of dynamic structures and replaces it by new one.

public void UpdateStructureLevelsSourceField(IEnumerable<DynamicStructure> dynamicStructures, string sourceField, string newSourceField)

Parameters

dynamicStructures IEnumerable<DynamicStructure>

The dynamic structures.

sourceField string

Source field to find.

newSourceField string

New source field value.

UpdateStructureLevelsSourceField(string, string)

Finds the needed source field in levels of all dynamic structures and replaces it by new one.

public void UpdateStructureLevelsSourceField(string sourceField, string newSourceField)

Parameters

sourceField string

Source field to find.

newSourceField string

New source field value.

To top