/// <summary> /// Reads the specified documentation file and returns a lazily-constructed /// set of members that can be visited. /// </summary> /// <param name="fileName">Path to the documentation file.</param> /// <param name="options">Options for reading the documentation</param> /// <returns>All documented members found in the given file.</returns> /// <exception cref="System.IO.FileNotFoundException">Could not find documentation file to load.</exception> public static DocumentMembers Read(string fileName, ReaderOptions options) { return(new DocReader(options).ReadInternal(fileName)); }
private DocReader(ReaderOptions options) { _options = options ?? new ReaderOptions(); }
/// <summary> /// Uses the specified assembly to locate a documentation file alongside the assembly by /// changing the extension to ".xml". If the file is found, it will be read and all /// found members will contain extended reflection information in the <see cref="Member.Info"/> /// property. /// </summary> /// <param name="assembly">The assembly to read the documentation from.</param> /// <param name="options">Options for reading the documentation</param> /// <returns>All documented members found in the given file, together with the reflection metadata /// association from the assembly.</returns> /// <exception cref="System.IO.FileNotFoundException">Could not find documentation file to load.</exception> public static AssemblyMembers Read(Assembly assembly, ReaderOptions options) { return(Read(assembly, null, options)); }
/// <summary> /// Uses the specified assembly to locate a documentation file alongside the assembly by /// changing the extension to ".xml". If the file is found, it will be read and all /// found members will contain extended reflection information in the <see cref="Member.Info"/> /// property. /// </summary> /// <param name="assembly">The assembly to read the documentation from.</param> /// <param name="documentationFilename">Path to the documentation file.</param> /// <param name="options">Options for reading the documentation</param> /// <returns>All documented members found in the given file, together with the reflection metadata /// association from the assembly.</returns> /// <exception cref="System.IO.FileNotFoundException">Could not find documentation file to load.</exception> public static AssemblyMembers Read(Assembly assembly, string documentationFilename, ReaderOptions options) { return(new DocReader(options).ReadInternal(assembly, documentationFilename)); }
DocReader(ReaderOptions options) => this.options = options;