コード例 #1
0
 public NSwaggerProvider(PathProcessor pathProcessor, SwaggerKeyRoles keyRoles,
                         IOptions <SchemaGeneratorOptions> swaggerOptions, IOptions <DocXmlOptions> docXmlOptions)
 {
     _pathProcessor  = pathProcessor;
     _keyRoles       = keyRoles;
     _swaggerOptions = swaggerOptions.Value;
     _docXmlOptions  = docXmlOptions.Value;
     _doc            = new OpenApiDocument();
 }
コード例 #2
0
 public static void ResetXmlForInnerType(SchemaGeneratorOptions swaggerOptions, DocXmlOptions docXmlOptions, List <ContractInfo> contracts)
 {
     foreach (var path in docXmlOptions.Paths)
     {
         swaggerOptions.SchemaFilters.Add(new XmlCommentsSchemaFilter(ResetXmlForInnerType_InnerTypeMap(path)));
         swaggerOptions.SchemaFilters.Add(new XmlCommentsSchemaFilter(ResetXmlForInnerType_MethodParams(contracts, path)));
     }
 }