Ejemplo n.º 1
0
        public AnnotatedResponse(SwaggerResponseAttribute attr, ISwaggerModelCatalog modelCatalog)
        {
            Description = attr.Message;
            StatusCode = (int) attr.Code;

            if (attr.Model != null)
            {
                Schema = modelCatalog.GetModelForType(attr.Model)?.GetSchema();
            }
        }
Ejemplo n.º 2
0
 private AnnotatedResponse CreateSwaggerResponseObject(SwaggerResponseAttribute attr)
 {
     return new AnnotatedResponse(attr, _modelCatalog);
 }