Exemplo n.º 1
0
        /// <summary>
        /// Retrieves the XmlDocument for the provided <paramref name="entry"/>.
        /// </summary>
        /// <param name="entry">The ContentEntry to get the documentation for.</param>
        /// <include file='Documentation\documentation.xml' path='members/member[@name="GetDocumentationFor.entry"]/*'/>
        public string GetDocumentationFor(ContentEntry entry)
        {
            if (entry == null)
            {
                throw new ArgumentNullException("entry");
            }
            if (!_isLoaded)
            {
                throw new InvalidOperationException("The documentation is not loaded, call Load first");
            }

            return(GetDocumentationFor(entry.Entry));
        }
Exemplo n.º 2
0
        /// <summary>
        /// Retrieves a list of the parent entries for this ContentEntry
        /// </summary>
        /// <returns>A sequential list of parents or an empty list if the entry has no parents.</returns>
        /// <include file='Documentation\contententry.xml' path='members/member[@name="GetParents"]/*'/>
        public List <ContentEntry> GetParents()
        {
            List <ContentEntry> parents = new List <ContentEntry>();

            ContentEntry currentParent = Parent;

            while (currentParent != null)
            {
                parents.Insert(0, currentParent);
                currentParent = currentParent.Parent;
            }

            return(parents);
        }