This repository was archived by the owner on Nov 16, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 35
/
Copy pathKnownXmlStrings.cs
81 lines (76 loc) · 3.81 KB
/
KnownXmlStrings.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
// ------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License (MIT). See License.txt in the repo root for license information.
// ------------------------------------------------------------
namespace Microsoft.OpenApi.CSharpAnnotations.DocumentGeneration.Models.KnownStrings
{
/// <summary>
/// Class to store known xml tags that will be processed by the generation engine.
/// </summary>
public class KnownXmlStrings
{
public const string Annotation = "annotation";
public const string Body = "body";
public const string Code = "code";
public const string Cref = "cref";
public const string Default = "default";
public const string Description = "description";
public const string Example = "example";
public const string Group = "group";
public const string Header = "header";
public const string In = "in";
public const string Name = "name";
public const string Option = "option";
public const string Options = "options";
public const string Para = "para";
public const string Param = "param";
public const string Paramref = "paramref";
public const string Path = "path";
public const string PathParam = "pathParam";
public const string Query = "query";
public const string QueryParam = "queryParam";
public const string Remarks = "remarks";
public const string RequestType = "requestType";
public const string Required = "required";
public const string Response = "response";
public const string ResponseType = "responseType";
public const string See = "see";
public const string Seealso = "seealso";
public const string Summary = "summary";
public const string T = "T";
public const string Typeparamref = "Typeparamref";
public const string Tag = "tag";
public const string Type = "type";
public const string Url = "url";
public const string Value = "value";
public const string Variant = "variant";
public const string Verb = "verb";
public const string ApiKey = "apiKey";
public const string Http = "http";
public const string OAuth2 = "oauth2";
public const string OpenIdConnect = "openIdConnect";
public const string Security = "security";
public const string Cookie = "cookie";
public const string Scheme = "scheme";
public const string BearerFormat = "bearerFormat";
public const string OpenIdConnectUrl = "openIdConnectUrl";
public const string TokenUrl = "tokenUrl";
public const string RefreshUrl = "refreshUrl";
public const string AuthorizationUrl = "authorizationUrl";
public const string Flow = "flow";
public const string ImplicitFlow = "implicit";
public const string Password = "password";
public const string AuthorizationCode = "authorizationCode";
public const string ClientCredentials = "clientCredentials";
public const string Scope = "scope";
public const string OperationId = "operationId";
public static string[] AllowedAppKeyInValues => new[] {Header, Query, Cookie};
public static string[] AllowedFlowTypeValues => new[]
{ImplicitFlow, Password, AuthorizationCode, ClientCredentials};
public static string[] AllowedInValues => new[] {Header, Path, Query, Body};
public static string[] AllowedSecurityTypeValues => new[]
{ApiKey, Http, OpenIdConnect, OAuth2};
// "body" in attribute is translated to a requestBody instead of a parameter.
public static string[] InValuesTranslatableToParameter => new[] {Header, Path, Query};
}
}