Skip to content

Commit

Permalink
feat: change some internal types from public to internal (dotnet#9401)
Browse files Browse the repository at this point in the history
Co-authored-by: Yufei Huang <[email protected]>
  • Loading branch information
2 people authored and p-kostov committed Jun 28, 2024
1 parent 9765e96 commit 50354b3
Show file tree
Hide file tree
Showing 33 changed files with 28 additions and 298 deletions.
1 change: 0 additions & 1 deletion Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
<PackageVersion Include="Stubble.Core" Version="1.10.8" />
<PackageVersion Include="System.Collections.Immutable" Version="7.0.0" />
<PackageVersion Include="System.Composition" Version="7.0.0" />
<PackageVersion Include="System.Configuration.ConfigurationManager" Version="7.0.0" />
<PackageVersion Include="YamlDotNet" Version="13.7.1" />
<!-- Test only -->
<PackageVersion Include="coverlet.collector" Version="6.0.0" />
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/CompositionContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
namespace Docfx.Common;

[Export(typeof(ICompositionContainer))]
public class CompositionContainer : ICompositionContainer
class CompositionContainer : ICompositionContainer
{
public static CompositionHost DefaultContainer { get; private set; }

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/Conceptual/BuildConceptualDocument.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
namespace Docfx.Build.ConceptualDocuments;

[Export(nameof(ConceptualDocumentProcessor), typeof(IDocumentBuildStep))]
public class BuildConceptualDocument : BaseDocumentBuildStep
class BuildConceptualDocument : BaseDocumentBuildStep
{
private const string ConceptualKey = Constants.PropertyName.Conceptual;
private const string DocumentTypeKey = "documentType";
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/Conceptual/ConceptualDocumentProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
namespace Docfx.Build.ConceptualDocuments;

[Export(typeof(IDocumentProcessor))]
public class ConceptualDocumentProcessor : DisposableDocumentProcessor
class ConceptualDocumentProcessor : DisposableDocumentProcessor
{
#region Fields

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/Conceptual/CountWord.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
namespace Docfx.Build.ConceptualDocuments;

[Export(nameof(ConceptualDocumentProcessor), typeof(IDocumentBuildStep))]
public class CountWord : BaseDocumentBuildStep
class CountWord : BaseDocumentBuildStep
{
public override string Name => nameof(CountWord);

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/Conceptual/HtmlDocumentUtility.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Docfx.Build.ConceptualDocuments;

public static class HtmlDocumentUtility
static class HtmlDocumentUtility
{
public static SeparatedHtmlInfo SeparateHtml(string contentHtml)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/Conceptual/SeparatedHtmlInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Docfx.Build.ConceptualDocuments;

public class SeparatedHtmlInfo
class SeparatedHtmlInfo
{
public string Title { get; set; }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
namespace Docfx.Build.ConceptualDocuments;

[Export(nameof(ConceptualDocumentProcessor), typeof(IDocumentBuildStep))]
public class ValidateConceptualDocumentMetadata : BaseDocumentBuildStep
class ValidateConceptualDocumentMetadata : BaseDocumentBuildStep
{
private const string ConceptualKey = Constants.PropertyName.Conceptual;

Expand Down
114 changes: 0 additions & 114 deletions src/Docfx.Build/FileMetadataConverter.cs

This file was deleted.

2 changes: 1 addition & 1 deletion src/Docfx.Build/ManifestUtility.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ namespace Docfx.Common;

#pragma warning disable CS0612 // Type or member is obsolete

public static class ManifestUtility
static class ManifestUtility
{
public static void RemoveDuplicateOutputFiles(ManifestItemCollection manifestItems)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/PostProcessors/ExtractSearchIndex.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
namespace Docfx.Build.Engine;

[Export(nameof(ExtractSearchIndex), typeof(IPostProcessor))]
public class ExtractSearchIndex : IPostProcessor
class ExtractSearchIndex : IPostProcessor
{
private static readonly Regex s_regexWhiteSpace = new(@"\s+", RegexOptions.Compiled);
private static readonly HashSet<string> s_htmlInlineTags = new(StringComparer.OrdinalIgnoreCase)
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/PostProcessors/HtmlPostProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace Docfx.Build.Engine;

internal sealed class HtmlPostProcessor : IPostProcessor
sealed class HtmlPostProcessor : IPostProcessor
{
public List<IHtmlDocumentHandler> Handlers { get; } = new List<IHtmlDocumentHandler>();

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/PostProcessors/PostProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Docfx.Build.Engine;

internal sealed class PostProcessor
sealed class PostProcessor
{
public string ContractName { get; set; }

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/PostProcessors/PostProcessorsManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

namespace Docfx.Build.Engine;

internal class PostProcessorsManager : IDisposable
class PostProcessorsManager : IDisposable
{
private readonly List<PostProcessor> _postProcessors;

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/PostProcessors/RemoveDebugInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Docfx.Build.Engine;

public sealed class RemoveDebugInfo : HtmlDocumentHandler
class RemoveDebugInfo : HtmlDocumentHandler
{
private readonly string[] DebugInfoAttributes =
{
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/PostProcessors/SearchIndexItem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Docfx.Build.Engine;

public class SearchIndexItem
class SearchIndexItem
{
[JsonProperty("href")]
[JsonPropertyName("href")]
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/PostProcessors/SitemapGenerator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
namespace Docfx.Build.Engine;

[Export(nameof(SitemapGenerator), typeof(IPostProcessor))]
public class SitemapGenerator : IPostProcessor
class SitemapGenerator : IPostProcessor
{
private static readonly XNamespace Namespace = "http://www.sitemaps.org/schemas/sitemap/0.9"; // lgtm [cs/non-https-url]
private const string HtmlExtension = ".html";
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/PostProcessors/ValidateBookmark.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

namespace Docfx.Build.Engine;

public sealed class ValidateBookmark : HtmlDocumentHandler
sealed class ValidateBookmark : HtmlDocumentHandler
{
private static readonly string XPathTemplate = "//*/@{0}";
private static readonly HashSet<string> WhiteList = new() { "top" };
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/ResourceFiles/ResourceDocumentProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
namespace Docfx.Build.ResourceFiles;

[Export(typeof(IDocumentProcessor))]
public class ResourceDocumentProcessor : DisposableDocumentProcessor
class ResourceDocumentProcessor : DisposableDocumentProcessor
{
[ImportMany]
public IEnumerable<IResourceFileConfig> Configs { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/ResourceFiles/ValidateResourceMetadata.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
namespace Docfx.Build.ResourceFiles;

[Export(nameof(ResourceDocumentProcessor), typeof(IDocumentBuildStep))]
public class ValidateResourceMetadata : BaseDocumentBuildStep
class ValidateResourceMetadata : BaseDocumentBuildStep
{
public override string Name => nameof(ValidateResourceMetadata);

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/BuildTocDocument.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
namespace Docfx.Build.TableOfContents;

[Export(nameof(TocDocumentProcessor), typeof(IDocumentBuildStep))]
public class BuildTocDocument : BaseDocumentBuildStep
class BuildTocDocument : BaseDocumentBuildStep
{
public override string Name => nameof(BuildTocDocument);

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/HrefType.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Docfx.Build.TableOfContents;

internal enum HrefType
enum HrefType
{
AbsolutePath,
RelativeFile,
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/TocDocumentProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
namespace Docfx.Build.TableOfContents;

[Export(typeof(IDocumentProcessor))]
public class TocDocumentProcessor : DisposableDocumentProcessor
class TocDocumentProcessor : DisposableDocumentProcessor
{
private static readonly char[] QueryStringOrAnchor = new[] { '#', '?' };

Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/TocFileType.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Docfx.Build.TableOfContents;

internal enum TocFileType
enum TocFileType
{
None,
Markdown,
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/TocHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

namespace Docfx.Build.TableOfContents;

public static class TocHelper
static class TocHelper
{
private static readonly YamlDeserializerWithFallback _deserializer =
YamlDeserializerWithFallback.Create<TocViewModel>()
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/TocItemInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Docfx.Build.TableOfContents;

internal sealed class TocItemInfo
class TocItemInfo
{
public TocItemViewModel Content { get; set; }
public FileAndType File { get; }
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/TocResolver.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

namespace Docfx.Build.TableOfContents;

internal sealed class TocResolver
class TocResolver
{
private readonly Dictionary<string, TocItemInfo> _collection;
private readonly Dictionary<FileAndType, TocItemInfo> _notInProjectTocCache = new();
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/TocRestructureUtility.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

namespace Docfx.Build.TableOfContents;

internal static class TocRestructureUtility
static class TocRestructureUtility
{
public static void Restructure(TocItemViewModel toc, IList<TreeItemRestructure> restructures)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Docfx.Build/TableOfContents/Utility.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Docfx.Build.TableOfContents;

internal static class Utility
static class Utility
{
public static bool IsSupportedFile(string file)
{
Expand Down
1 change: 0 additions & 1 deletion src/Docfx.Dotnet/Docfx.Dotnet.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@
<PackageReference Include="IgnoresAccessChecksToGenerator" PrivateAssets="All" />
<PackageReference Include="OneOf" />
<PackageReference Include="OneOf.SourceGenerator" />
<PackageReference Include="System.Configuration.ConfigurationManager" />
<PackageReference Include="Markdig" />
<PackageReference Include="Microsoft.Build" ExcludeAssets="runtime" />
<PackageReference Include="Microsoft.Build.Locator" />
Expand Down
Loading

0 comments on commit 50354b3

Please sign in to comment.