Class UrlIndex
- Namespace
- Dynamicweb.Frontend.UrlHandling
- Assembly
- Dynamicweb.dll
public class UrlIndex
- Inheritance
-
UrlIndex
- Inherited Members
Properties
IndexOfQueryString
public ConcurrentDictionary<string, UrlNode> IndexOfQueryString { get; set; }
Property Value
Indexes
public static ConcurrentDictionary<string, UrlIndex> Indexes { get; }
Property Value
PathIndex
public ConcurrentDictionary<string, UrlNode> PathIndex { get; set; }
Property Value
RootNodes
public List<UrlNode> RootNodes { get; set; }
Property Value
Methods
AddOrUpdateIndexOfQueryString(UrlNode)
public void AddOrUpdateIndexOfQueryString(UrlNode node)
Parameters
nodeUrlNode
AddOrUpdatePathIndex(UrlNode)
public void AddOrUpdatePathIndex(UrlNode node)
Parameters
nodeUrlNode
BuildIndex()
public void BuildIndex()
BuildIndexes()
public static void BuildIndexes()
EnsureUniquePath(string)
public string EnsureUniquePath(string path)
Parameters
pathstring
Returns
GetIndex(string)
public static UrlIndex GetIndex(string name)
Parameters
namestring
Returns
GetNodeByPath(string)
public UrlNode? GetNodeByPath(string path)
Parameters
pathstring
Returns
GetNodeByPathForArea(string, int)
Finds a node by path, scoped to a specific area. This avoids the PathIndex collision that occurs when two language areas share the same index (UniqueForEachMasterWebsite=true) and have identical page paths. The path is matched against both the indexed (deduplicated) path and the natural path of the area's nodes; when the area has indexed nodes but none matches, null is returned. Falls back to PathIndex only when the index holds no nodes for the area at all.
public UrlNode? GetNodeByPathForArea(string path, int areaId)
Parameters
Returns
GetNodeByQuerystring(string)
public UrlNode? GetNodeByQuerystring(string queryString)
Parameters
queryStringstring
Returns
GetPathFromQueryString(string)
public string? GetPathFromQueryString(string queryString)
Parameters
queryStringstring
Returns
GetPathFromQueryString(string, string)
public string? GetPathFromQueryString(string queryString, string languageId)
Parameters
Returns
GetQueryStringByPath(string)
public UrlIndexPathLookupResult? GetQueryStringByPath(string path)
Parameters
pathstring
Returns
IndexNode(UrlNode)
public void IndexNode(UrlNode node)
Parameters
nodeUrlNode