Skip to content

Commit

Permalink
Add HtmlTextWriter and required support
Browse files Browse the repository at this point in the history
This is a port of HtmlTextWriter with the following changes:

- `HtmlTextWriter.[Enter|Exit]Style(...)` methods (4 total) are not supported. The `Style` class brings in a lot of additional stuff we probably don't want to support
- HashTable usage has been switched to Dictionary<,>
- Manual array management has been switched to lists
- Helper structs have been made into readonly records to simplify definition and usage
- Annotated for nullability
  • Loading branch information
twsouthwick committed Sep 1, 2023
1 parent 7678dee commit 95bc740
Show file tree
Hide file tree
Showing 13 changed files with 2,591 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
T:System.Diagnostics.CodeAnalysis.NotNullIfNotNullAttribute
T:System.Diagnostics.CodeAnalysis.MaybeNullWhenAttribute
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,7 @@
#pragma warning disable CS0809 // Obsolete member overrides non-obsolete member
#pragma warning disable CA1063 // Implement IDisposable Correctly
#pragma warning disable CA1816 // Dispose methods should call SuppressFinalize
#pragma warning disable CA1721 // Property names should not match get methods
#pragma warning disable CA1711 // Identifiers should not have incorrect suffix
#pragma warning disable CA1720 // Identifier contains type name

329 changes: 329 additions & 0 deletions src/Microsoft.AspNetCore.SystemWebAdapters/Generated/Ref.Standard.cs

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
#pragma warning disable CS0809 // Obsolete member overrides non-obsolete member
#pragma warning disable CA1063 // Implement IDisposable Correctly
#pragma warning disable CA1816 // Dispose methods should call SuppressFinalize
#pragma warning disable CA1721 // Property names should not match get methods
#pragma warning disable CA1711 // Identifiers should not have incorrect suffix
#pragma warning disable CA1720 // Identifier contains type name

[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.HttpApplication))]
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.HttpApplicationState))]
Expand Down Expand Up @@ -69,3 +72,8 @@
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.Hosting.HostingEnvironment))]
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.SessionState.HttpSessionState))]
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.SessionState.SessionStateMode))]
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.UI.HtmlTextWriter))]
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.UI.HtmlTextWriterAttribute))]
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.UI.HtmlTextWriterStyle))]
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.UI.HtmlTextWriterTag))]
[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Web.UI.WebControls.HorizontalAlign))]
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
using System.Collections.Specialized;
using System.IO;
using System.Text;
using Microsoft.AspNetCore.Http;

namespace System.Web
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
// The .NET Foundation licenses this file to you under the MIT license.

using System;
using System.Collections;
using System.Collections.Specialized;
using System.Text;
using System.Web;
Expand Down
Loading

0 comments on commit 95bc740

Please sign in to comment.