This repository was archived by the owner on Jan 12, 2024. It is now read-only.
File tree Expand file tree Collapse file tree
src/Build/NuGet.Build.Packaging.Tasks Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,6 +19,8 @@ public class ApiIntersect : ToolTask
1919
2020 public ITaskItem [ ] ExcludeType { get ; set ; }
2121
22+ public ITaskItem [ ] RemoveAbstractTypeMembers { get ; set ; }
23+
2224 public string KeepInternalConstructors { get ; set ; }
2325
2426 public string KeepMarshalling { get ; set ; }
@@ -78,6 +80,14 @@ protected override string GenerateCommandLineCommands()
7880 builder . AppendTextUnquoted ( "\" " ) ;
7981 }
8082
83+ foreach ( var removeAbstractType in RemoveAbstractTypeMembers . NullAsEmpty ( ) )
84+ {
85+ builder . AppendSwitch ( "-a" ) ;
86+ builder . AppendTextUnquoted ( " \" " ) ;
87+ builder . AppendTextUnquoted ( removeAbstractType . ItemSpec ) ;
88+ builder . AppendTextUnquoted ( "\" " ) ;
89+ }
90+
8191 AppendSwitchIfTrue ( builder , "-k" , KeepInternalConstructors ) ;
8292
8393 AppendSwitchIfTrue ( builder , "-m" , KeepMarshalling ) ;
Original file line number Diff line number Diff line change @@ -523,6 +523,7 @@ Copyright (c) .NET Foundation. All rights reserved.
523523 IntersectionAssembly=" @(IntersectionAssembly)"
524524 ReferencePath=" $(IntersectionAssemblyReferencePath)"
525525 ExcludeType=" $(IntersectionExcludeType)"
526+ RemoveAbstractTypeMembers=" $(IntersectionRemoveAbstractTypeMembers)"
526527 KeepInternalConstructors=" $(IntersectionKeepInternalConstructors)"
527528 KeepMarshalling=" $(IntersectionKeepMarshalling)"
528529 ToolPath=" $(ApiIntersectToolPath)"
You can’t perform that action at this time.
0 commit comments