I have the following code located in a Swashbuckle.Swagger.IOperationFilter
class.
List<CustomAttributeData> controllerAttributes = apiDescription
.ActionDescriptor
.ControllerDescriptor
.ControllerType
.CustomAttributes
.Where(a => a.AttributeType == typeof(SwaggerFileInFormDataAttribute))
.ToList();
I am obtaining the collection successfully. I want to convert the collection into a collection of my custom attribute List<SwaggerFileInFormDataAttribute>
.
I want to convert the System.Reflection.CustomAttributeData
class to my custom attribute SwaggerFileInFormDataAttribute
.
Aucun commentaire:
Enregistrer un commentaire