Update 20240719

This commit is contained in:
Stefan Hutter
2024-07-19 17:03:49 +02:00
parent 153fbef133
commit ea8d48ac9e
90 changed files with 1011 additions and 230 deletions

View File

@@ -3,7 +3,7 @@ using System.Text;
using System.Web;
using System.Web.Http.Description;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
public static class ApiDescriptionExtensions
{

View File

@@ -16,7 +16,7 @@ using System.Web.Http;
using System.Web.Http.OData;
#endif
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// Use this class to customize the Help Page.
@@ -26,7 +26,7 @@ namespace EDOKAAPI_NetFramework.Areas.HelpPage
public static class HelpPageConfig
{
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters",
MessageId = "EDOKAAPI_NetFramework.Areas.HelpPage.TextSample.#ctor(System.String)",
MessageId = "EDOKA API_NetFramework.Areas.HelpPage.TextSample.#ctor(System.String)",
Justification = "End users may choose to merge this string with existing localized resources.")]
[SuppressMessage("Microsoft.Naming", "CA2204:Literals should be spelled correctly",
MessageId = "bsonspec",

View File

@@ -1,10 +1,10 @@
using System;
using System.Web.Http;
using System.Web.Mvc;
using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions;
using EDOKAAPI_NetFramework.Areas.HelpPage.Models;
using API_NetFramework.Areas.HelpPage.ModelDescriptions;
using API_NetFramework.Areas.HelpPage.Models;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.Controllers
namespace API_NetFramework.Areas.HelpPage.Controllers
{
/// <summary>
/// The controller that will handle requests for the help page.

View File

@@ -1,7 +1,7 @@
using System.Web.Http;
using System.Web.Mvc;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
public class HelpPageAreaRegistration : AreaRegistration
{

View File

@@ -11,10 +11,10 @@ using System.Net.Http.Headers;
using System.Web.Http;
using System.Web.Http.Controllers;
using System.Web.Http.Description;
using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions;
using EDOKAAPI_NetFramework.Areas.HelpPage.Models;
using API_NetFramework.Areas.HelpPage.ModelDescriptions;
using API_NetFramework.Areas.HelpPage.Models;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
public static class HelpPageConfigurationExtensions
{

View File

@@ -1,4 +1,4 @@
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class CollectionModelDescription : ModelDescription
{

View File

@@ -1,6 +1,6 @@
using System.Collections.ObjectModel;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class ComplexTypeModelDescription : ModelDescription
{

View File

@@ -1,4 +1,4 @@
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class DictionaryModelDescription : KeyValuePairModelDescription
{

View File

@@ -1,7 +1,7 @@
using System.Collections.Generic;
using System.Collections.ObjectModel;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class EnumTypeModelDescription : ModelDescription
{

View File

@@ -1,4 +1,4 @@
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class EnumValueDescription
{

View File

@@ -1,7 +1,7 @@
using System;
using System.Reflection;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public interface IModelDocumentationProvider
{

View File

@@ -1,4 +1,4 @@
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class KeyValuePairModelDescription : ModelDescription
{

View File

@@ -1,6 +1,6 @@
using System;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
/// <summary>
/// Describes a type model.

View File

@@ -11,7 +11,7 @@ using System.Web.Http.Description;
using System.Xml.Serialization;
using Newtonsoft.Json;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
/// <summary>
/// Generates model descriptions for given types.

View File

@@ -1,6 +1,6 @@
using System;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
/// <summary>
/// Use this attribute to change the name of the <see cref="ModelDescription"/> generated for a type.

View File

@@ -3,7 +3,7 @@ using System.Globalization;
using System.Linq;
using System.Reflection;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
internal static class ModelNameHelper
{

View File

@@ -1,6 +1,6 @@
using System;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class ParameterAnnotation
{

View File

@@ -1,7 +1,7 @@
using System.Collections.Generic;
using System.Collections.ObjectModel;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class ParameterDescription
{

View File

@@ -1,4 +1,4 @@
namespace EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
namespace API_NetFramework.Areas.HelpPage.ModelDescriptions
{
public class SimpleTypeModelDescription : ModelDescription
{

View File

@@ -2,9 +2,9 @@ using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Net.Http.Headers;
using System.Web.Http.Description;
using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions;
using API_NetFramework.Areas.HelpPage.ModelDescriptions;
namespace EDOKAAPI_NetFramework.Areas.HelpPage.Models
namespace API_NetFramework.Areas.HelpPage.Models
{
/// <summary>
/// The model that represents an API displayed on the help page.

View File

@@ -13,7 +13,7 @@ using System.Web.Http.Description;
using System.Xml.Linq;
using Newtonsoft.Json;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// This class will generate the samples for the help page.

View File

@@ -3,7 +3,7 @@ using System.Collections.Generic;
using System.ComponentModel;
using System.Net.Http.Headers;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// This is used to identify the place where the sample should be applied.

View File

@@ -1,6 +1,6 @@
using System;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// This represents an image sample on the help page. There's a display template named ImageSample associated with this class.

View File

@@ -1,6 +1,6 @@
using System;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// This represents an invalid sample on the help page. There's a display template named InvalidSample associated with this class.

View File

@@ -6,7 +6,7 @@ using System.Globalization;
using System.Linq;
using System.Reflection;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// This class will create an object of a given type and populate it with sample data.

View File

@@ -1,4 +1,4 @@
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// Indicates whether the sample is used for request or response

View File

@@ -1,6 +1,6 @@
using System;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// This represents a preformatted text sample on the help page. There's a display template named TextSample associated with this class.

View File

@@ -1,5 +1,5 @@
@using System.Web.Http
@using EDOKAAPI_NetFramework.Areas.HelpPage.Models
@using API_NetFramework.Areas.HelpPage.Models
@model HelpPageApiModel
@{

View File

@@ -1,8 +1,8 @@
@using System.Web.Http
@using System.Web.Http.Controllers
@using System.Web.Http.Description
@using EDOKAAPI_NetFramework.Areas.HelpPage
@using EDOKAAPI_NetFramework.Areas.HelpPage.Models
@using API_NetFramework.Areas.HelpPage
@using API_NetFramework.Areas.HelpPage.Models
@model IGrouping<HttpControllerDescriptor, ApiDescription>
@{

View File

@@ -1,4 +1,4 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model CollectionModelDescription
@if (Model.ElementDescription is ComplexTypeModelDescription)
{

View File

@@ -1,3 +1,3 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model ComplexTypeModelDescription
@Html.DisplayFor(m => m.Properties, "Parameters")

View File

@@ -1,4 +1,4 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model DictionaryModelDescription
Dictionary of @Html.DisplayFor(m => Model.KeyModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.KeyModelDescription }) [key]
and @Html.DisplayFor(m => Model.ValueModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.ValueModelDescription }) [value]

View File

@@ -1,4 +1,4 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model EnumTypeModelDescription
<p>Possible enumeration values:</p>

View File

@@ -1,7 +1,7 @@
@using System.Web.Http
@using System.Web.Http.Description
@using EDOKAAPI_NetFramework.Areas.HelpPage.Models
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.Models
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model HelpPageApiModel
@{

View File

@@ -1,4 +1,4 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage
@using API_NetFramework.Areas.HelpPage
@model ImageSample
<img src="@Model.Src" />

View File

@@ -1,4 +1,4 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage
@using API_NetFramework.Areas.HelpPage
@model InvalidSample
@if (HttpContext.Current.IsDebuggingEnabled)

View File

@@ -1,4 +1,4 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model KeyValuePairModelDescription
Pair of @Html.DisplayFor(m => Model.KeyModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.KeyModelDescription }) [key]
and @Html.DisplayFor(m => Model.ValueModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.ValueModelDescription }) [value]

View File

@@ -1,4 +1,4 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model Type
@{
ModelDescription modelDescription = ViewBag.modelDescription;

View File

@@ -2,7 +2,7 @@
@using System.Collections.ObjectModel
@using System.Web.Http.Description
@using System.Threading
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model IList<ParameterDescription>
@if (Model.Count > 0)

View File

@@ -1,3 +1,3 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model SimpleTypeModelDescription
@Model.Documentation

View File

@@ -1,4 +1,4 @@
@using EDOKAAPI_NetFramework.Areas.HelpPage
@using API_NetFramework.Areas.HelpPage
@model TextSample
<pre class="wrapped">

View File

@@ -2,7 +2,7 @@
@using System.Web.Http.Controllers
@using System.Web.Http.Description
@using System.Collections.ObjectModel
@using EDOKAAPI_NetFramework.Areas.HelpPage.Models
@using API_NetFramework.Areas.HelpPage.Models
@model Collection<ApiDescription>
@{

View File

@@ -1,5 +1,5 @@
@using System.Web.Http
@using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions
@using API_NetFramework.Areas.HelpPage.ModelDescriptions
@model ModelDescription
<link type="text/css" href="~/Areas/HelpPage/HelpPage.css" rel="stylesheet" />

View File

@@ -5,9 +5,9 @@ using System.Reflection;
using System.Web.Http.Controllers;
using System.Web.Http.Description;
using System.Xml.XPath;
using EDOKAAPI_NetFramework.Areas.HelpPage.ModelDescriptions;
using API_NetFramework.Areas.HelpPage.ModelDescriptions;
namespace EDOKAAPI_NetFramework.Areas.HelpPage
namespace API_NetFramework.Areas.HelpPage
{
/// <summary>
/// A custom <see cref="IDocumentationProvider"/> that reads the API documentation from an XML documentation file.