Created
April 2, 2017 21:56
-
-
Save diegobersano/994fe415ddac9b476ee39901c766c3e2 to your computer and use it in GitHub Desktop.
Ejemplo para configurar el origen de la documentación Xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Diagnostics.CodeAnalysis; | |
using System.Net.Http.Headers; | |
using System.Web; | |
using System.Web.Http; | |
namespace WebApi.Areas.HelpPage | |
{ | |
/// <summary> | |
/// Use this class to customize the Help Page. | |
/// For example you can set a custom <see cref="System.Web.Http.Description.IDocumentationProvider"/> to supply the documentation | |
/// or you can provide the samples for the requests/responses. | |
/// </summary> | |
public static class HelpPageConfig | |
{ | |
public static void Register(HttpConfiguration config) | |
{ | |
// Uncomment the following to use the documentation from XML documentation file. | |
config.SetDocumentationProvider(new XmlDocumentationProvider(HttpContext.Current.Server.MapPath("~/App_Data/XmlDocument.xml"))); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment