Class UrlFragmentHandler
Handles permanent link attribute fragments
Inheritance
System.Object
    UrlFragmentHandler
  Implements
Namespace: EPiServer.Core.Html.StringParsing.Internal
Assembly: EPiServer.dll
Version: 12.0.3Syntax
[ServiceConfiguration]
public class UrlFragmentHandler : Object, IFragmentAttributeHandlerConstructors
UrlFragmentHandler(ILinkAttributeMatch)
Initializes a new instance of the UrlFragmentHandler class.
Declaration
public UrlFragmentHandler(ILinkAttributeMatch linkAttributeMatcher)Parameters
| Type | Name | Description | 
|---|---|---|
| ILinkAttributeMatch | linkAttributeMatcher | The link attribute matcher. | 
UrlFragmentHandler(ILinkAttributeMatch, IUrlResolver)
Initializes a new instance of the UrlFragmentHandler class.
Declaration
public UrlFragmentHandler(ILinkAttributeMatch linkAttributeMatcher, IUrlResolver urlResolver)Parameters
| Type | Name | Description | 
|---|---|---|
| ILinkAttributeMatch | linkAttributeMatcher | The link attribute matcher. | 
| IUrlResolver | urlResolver | The URL resolver. | 
Methods
ExtractPermanentLink(FragmentParserContext, AttributeFragment, String, String, String)
Extracts the permanent link.
Declaration
protected void ExtractPermanentLink(FragmentParserContext context, AttributeFragment attribute, string permanentLink, string prefix, string suffix)Parameters
| Type | Name | Description | 
|---|---|---|
| FragmentParserContext | context | The context. | 
| AttributeFragment | attribute | The attribute. | 
| System.String | permanentLink | The permanent link. | 
| System.String | prefix | The prefix. | 
| System.String | suffix | The suffix. | 
ParseAttribute(FragmentParserContext, ElementFragment, AttributeFragment)
Parses the attribute of a fragment into a string fragment.
Declaration
public bool ParseAttribute(FragmentParserContext context, ElementFragment parentFragment, AttributeFragment attribute)Parameters
| Type | Name | Description | 
|---|---|---|
| FragmentParserContext | context | The current parser context that contains the source and where any results should be written. | 
| ElementFragment | parentFragment | The element fragment containing the attribute. | 
| AttributeFragment | attribute | The attribute that should be parsed. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | 
 | 
ParsePossibleLink(FragmentParserContext, AttributeFragment, String, String, String)
Evaluates a possible link
Declaration
protected virtual bool ParsePossibleLink(FragmentParserContext context, AttributeFragment attribute, string attributeValue, string prefix, string suffix)Parameters
| Type | Name | Description | 
|---|---|---|
| FragmentParserContext | context | The context. | 
| AttributeFragment | attribute | The attribute. | 
| System.String | attributeValue | The attribute value. | 
| System.String | prefix | The prefix. | 
| System.String | suffix | The suffix. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | 
