Esempio n. 1
0
        public LocatorNode(XElement xNode, DiscoverableTaxonomySet dts) : base(xNode)
        {
            Reference = new Uri(xNode.Attribute(XLinkXNames.Href).Value, UriKind.RelativeOrAbsolute);

            var idPart = Reference.OriginalString.Substring(Reference.OriginalString.IndexOf("#") + 1);
            var item   = dts.FindItem(idPart);

            if (item == null)
            {
                throw new ArgumentException($"The item {idPart} was not found in the DTS.");
            }
            Connect(item);
        }
Esempio n. 2
0
 public void AddLink(Link link, DiscoverableTaxonomySet dts)
 {
     link.RoleType = dts.FindRoleType(link.Role);
     Links.Add(link);
 }
Esempio n. 3
0
 internal Taxonomy(Uri entryPointUri, DiscoverableTaxonomySet discoverableTaxonomySet)
 {
     EntryPointUri = entryPointUri;
     Dts           = discoverableTaxonomySet;
 }