| | |
| | | using System.Web.Http; |
| | | using System.Web.Http.Description; |
| | | using System.Xml.Serialization; |
| | | using Newtonsoft.Json; |
| | | |
| | | |
| | | namespace YwUser.Web.SysApi.Areas.HelpPage.ModelDescriptions |
| | | namespace IStation.WebApi.Areas.HelpPage.ModelDescriptions |
| | | { |
| | | /// <summary> |
| | | /// Generates model descriptions for given types. |
| | |
| | | |
| | | private Lazy<IModelDocumentationProvider> _documentationProvider; |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | /// <param name="config"></param> |
| | | public ModelDescriptionGenerator(HttpConfiguration config) |
| | | { |
| | | if (config == null) |
| | |
| | | GeneratedModels = new Dictionary<string, ModelDescription>(StringComparer.OrdinalIgnoreCase); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | public Dictionary<string, ModelDescription> GeneratedModels { get; private set; } |
| | | |
| | | private IModelDocumentationProvider DocumentationProvider |
| | |
| | | return _documentationProvider.Value; |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// |
| | | /// </summary> |
| | | /// <param name="modelType"></param> |
| | | /// <returns></returns> |
| | | |
| | | public ModelDescription GetOrCreateModelDescription(Type modelType) |
| | | { |
| | | if (modelType == null) |