//=====================================================================
/// <summary>
/// Constructor
/// </summary>
/// <param name="node">The XPath navigator node from which to load the link settings</param>
/// <exception cref="ArgumentNullException">This is thrown if the node parameters is null</exception>
public ConceptualLinkInfo(XPathNavigator node)
{
string target;
int pos;
if(node == null)
throw new ArgumentNullException("node");
target = node.GetAttribute("target", string.Empty);
// EFW - Added support for an optional anchor name in the target
pos = target.IndexOf('#');
if(pos != -1)
{
this.Anchor = target.Substring(pos);
target = target.Substring(0, pos);
}
this.Target = target.ToLowerInvariant();
// EFW - Trim off unwanted whitespace
this.Text = node.ToString().Trim();
}