Class LinkViewModel
- Namespace
- Dynamicweb.Frontend
- Assembly
- Dynamicweb.dll
The LinkViewModel class is a specialized view model for handling links. It extends from the ViewModelBase class.
public class LinkViewModel : ViewModelBase
- Inheritance
-
LinkViewModel
- Inherited Members
Remarks
This class provides properties for the page ID, paragraph ID, URL, whether the URL is external or not, and the raw model value. It also overrides the ToString method to return the string representation of the model - either the Url or RawValue property.
Properties
IsExternal
Gets or sets is the url external or not.
public bool IsExternal { get; set; }
Property Value
Remarks
Returns true if the URL is a link to another website, i.e. www.google.com. Returns false if the URL is a page of the current website, i.e. Default.aspx?ID=123.
PageId
Gets or sets the page id.
public int PageId { get; set; }
Property Value
- int
the page id.
ParagraphId
Gets or sets the paragraph id.
public int ParagraphId { get; set; }
Property Value
- int
The paragraph id.
RawValue
Gets or sets the raw model value.
public string RawValue { get; set; }
Property Value
- string
The raw model value.
Url
Gets or sets the url.
public string Url { get; set; }
Property Value
- string
The url.
Methods
ToString()
Returns the string representation of model
public override string ToString()