Пример #1
0
 /// <summary>
 /// Creates a new instance of the <see cref="XmlDocCommentReader"/> class
 /// by searching for a doc comments file that corresponds to the given assembly.
 /// Configures the reader to use a user-defined read policy.
 /// </summary>
 ///
 /// <param name="assembly">
 /// The <see cref="System.Reflection.Assembly"/> whose doc comments are retrieved.
 /// </param>
 ///
 /// <param name="createReadPolicy">
 /// A factory method that accepts the full path to an XML doc comments file,
 /// returning a user-defined read policy.
 /// </param>
 ///
 /// <remarks>
 /// Searches in the application's configured search paths, if any.
 /// </remarks>
 public XmlDocCommentReader(Assembly assembly, CreateReadPolicyDelegate createReadPolicy)
     : this(assembly, ConfigurationManager.GetSection("XmlDocCommentsReader") as XmlDocCommentReaderSettings, createReadPolicy)
 {
 }
Пример #2
0
 internal XmlDocCommentReader(AssemblyDefinition assemblyDefinition, XmlDocCommentReaderSettings settings, CreateReadPolicyDelegate createReadPolicy)
 {
     _settings              = settings ?? XmlDocCommentReaderSettings.Default;
     _docCommentsFullPath   = ResolveDocCommentsLocation(assemblyDefinition, _settings.DirectoryNames);
     _docCommentsReadPolicy = createReadPolicy(_docCommentsFullPath);
 }
Пример #3
0
 /// <summary>
 /// Creates a new instance of the <see cref="XmlDocCommentReader"/> class
 /// with a given path to the XML doc comments, and configures the reader
 /// to use a user-defined read policy.
 /// </summary>
 ///
 /// <param name="docCommentsFullPath">
 /// The full path of the XML doc comments.
 /// </param>
 ///
 /// <param name="createReadPolicy">
 /// A factory method that accepts the full path to an XML doc comments file,
 /// returning a user-defined read policy.
 /// </param>
 public XmlDocCommentReader(string docCommentsFullPath, CreateReadPolicyDelegate createReadPolicy)
     : this(docCommentsFullPath, createReadPolicy(docCommentsFullPath))
 {
 }
Пример #4
0
        /// <summary>
        /// Creates a new instance of the <see cref="XmlDocCommentReader"/> class
        /// by searching for a doc comments file that corresponds to the given assembly.
        /// Searches the given paths, and configures the reader to use a user-defined read policy.
        /// </summary>
        ///
        /// <param name="assembly">
        /// The <see cref="System.Reflection.Assembly"/> whose doc comments are retrieved.
        /// </param>
        ///
        /// <param name="settings">
        /// The <see cref="XmlDocCommentReaderSettings"/> object containing the doc comment search paths.
        /// </param>
        ///
        /// <param name="createReadPolicy">
        /// A factory method that accepts the full path to an XML doc comments file,
        /// returning a user-defined read policy.
        /// </param>
        public XmlDocCommentReader(Assembly assembly, XmlDocCommentReaderSettings settings, CreateReadPolicyDelegate createReadPolicy)
        {
            m_settings            = settings ?? XmlDocCommentReaderSettings.Default;
            m_docCommentsFullPath = ResolveDocCommentsLocation(assembly, m_settings.DirectoryNames);

            m_docCommentsReadPolicy = createReadPolicy(m_docCommentsFullPath);
        }
Пример #5
0
 /// <summary>
 /// Creates a new instance of the <see cref="XmlDocCommentReader"/> class
 /// by searching for a doc comments file that corresponds to the given assembly.
 /// Searches the given paths, and configures the reader to use a user-defined read policy.
 /// </summary>
 ///
 /// <param name="assembly">
 /// The <see cref="System.Reflection.Assembly"/> whose doc comments are retrieved.
 /// </param>
 ///
 /// <param name="settings">
 /// The <see cref="XmlDocCommentReaderSettings"/> object containing the doc comment search paths.
 /// </param>
 ///
 /// <param name="createReadPolicy">
 /// A factory method that accepts the full path to an XML doc comments file,
 /// returning a user-defined read policy.
 /// </param>
 public XmlDocCommentReader(Assembly assembly, XmlDocCommentReaderSettings settings, CreateReadPolicyDelegate createReadPolicy)
     : this(assembly, settings, DefaultFileProxy, createReadPolicy)
 {
 }
Пример #6
0
 /// <summary>
 /// Creates a new instance of the <see cref="XmlDocCommentReader"/> class
 /// by searching for a doc comments file that corresponds to the given assembly.
 /// Searches the given paths, and configures the reader to use a user-defined read policy.
 /// </summary>
 ///
 /// <param name="assembly">
 /// The <see cref="System.Reflection.Assembly"/> whose doc comments are retrieved.
 /// </param>
 ///
 /// <param name="settings">
 /// The <see cref="XmlDocCommentReaderSettings"/> object containing the doc comment search paths.
 /// </param>
 ///
 /// <param name="fileProxy">
 /// The proxy to the file system.
 /// </param>
 ///
 /// <param name="createReadPolicy">
 /// A factory method that accepts the full path to an XML doc comments file,
 /// returning a user-defined read policy.
 /// </param>
 ///
 /// <remarks>
 /// Used internally by test code to override file IO operations.
 /// </remarks>
 internal XmlDocCommentReader(Assembly assembly, XmlDocCommentReaderSettings settings, IFile fileProxy, CreateReadPolicyDelegate createReadPolicy)
 {
     m_settings              = settings ?? XmlDocCommentReaderSettings.Default;
     m_docCommentsFullPath   = ResolveDocCommentsLocation(assembly, m_settings.DirectoryNames, fileProxy);
     m_fileProxy             = fileProxy;
     m_docCommentsReadPolicy = createReadPolicy(m_docCommentsFullPath);
 }