@@ -53,7 +53,7 @@ public static async Task TransformOpenApiDocument(HidiOptions options, ILogger l
5353 if ( options . Output == null )
5454 {
5555 var inputExtension = GetInputPathExtension ( options . OpenApi , options . Csdl ) ;
56- options . Output = new FileInfo ( $ "./output{ inputExtension } ") ;
56+ options . Output = new ( $ "./output{ inputExtension } ") ;
5757 } ;
5858
5959 if ( options . CleanOutput && options . Output . Exists )
@@ -194,7 +194,7 @@ private static void WriteOpenApi(HidiOptions options, OpenApiFormat openApiForma
194194
195195 IOpenApiWriter writer = openApiFormat switch
196196 {
197- OpenApiFormat . Json => options . TerseOutput ? new OpenApiJsonWriter ( textWriter , settings , options . TerseOutput ) : new OpenApiJsonWriter ( textWriter , settings , false ) ,
197+ OpenApiFormat . Json => options . TerseOutput ? new ( textWriter , settings , options . TerseOutput ) : new OpenApiJsonWriter ( textWriter , settings , false ) ,
198198 OpenApiFormat . Yaml => new OpenApiYamlWriter ( textWriter , settings ) ,
199199 _ => throw new ArgumentException ( "Unknown format" ) ,
200200 } ;
@@ -368,11 +368,11 @@ private static async Task<ReadResult> ParseOpenApi(string openApiFile, bool inli
368368 {
369369 stopwatch . Start ( ) ;
370370
371- result = await new OpenApiStreamReader ( new OpenApiReaderSettings
372- {
371+ result = await new OpenApiStreamReader ( new ( )
372+ {
373373 LoadExternalRefs = inlineExternal ,
374374 BaseUrl = openApiFile . StartsWith ( "http" , StringComparison . OrdinalIgnoreCase ) ?
375- new Uri ( openApiFile ) :
375+ new ( openApiFile ) :
376376 new Uri ( "file://" + new FileInfo ( openApiFile ) . DirectoryName + Path . DirectorySeparatorChar )
377377 }
378378 ) . ReadAsync ( stream , cancellationToken ) . ConfigureAwait ( false ) ;
@@ -459,7 +459,7 @@ private static Dictionary<string, List<string>> EnumerateJsonDocument(JsonElemen
459459 }
460460 else
461461 {
462- paths . Add ( path , new List < string > { method } ) ;
462+ paths . Add ( path , new ( ) { method } ) ;
463463 }
464464 }
465465 else
@@ -741,7 +741,7 @@ internal static async Task PluginManifest(HidiOptions options, ILogger logger, C
741741 outputFolder . Create ( ) ;
742742 }
743743 // Write OpenAPI to Output folder
744- options . Output = new FileInfo ( Path . Combine ( options . OutputFolder , "openapi.json" ) ) ;
744+ options . Output = new ( Path . Combine ( options . OutputFolder , "openapi.json" ) ) ;
745745 options . TerseOutput = true ;
746746 WriteOpenApi ( options , OpenApiFormat . Json , OpenApiSpecVersion . OpenApi3_0 , document , logger ) ;
747747
@@ -762,7 +762,7 @@ internal static async Task PluginManifest(HidiOptions options, ILogger logger, C
762762 // Write OpenAIPluginManifest to Output folder
763763 var manifestFile = new FileInfo ( Path . Combine ( options . OutputFolder , "ai-plugin.json" ) ) ;
764764 using var file = new FileStream ( manifestFile . FullName , FileMode . Create ) ;
765- using var jsonWriter = new Utf8JsonWriter ( file , new JsonWriterOptions { Indented = true } ) ;
765+ using var jsonWriter = new Utf8JsonWriter ( file , new ( ) { Indented = true } ) ;
766766 manifest . Write ( jsonWriter ) ;
767767 await jsonWriter . FlushAsync ( cancellationToken ) . ConfigureAwait ( false ) ;
768768 }
0 commit comments