Assembly: Glitch9.IO.dll
[Serializable]
public struct HttpHeader : IValidatable
Constructors
|
Edit this page
View Source
Declaration
public HttpHeader(string key, string value, bool removeOnRedirect = false, string logValue = null)
Parameters
Fields
|
Edit this page
View Source
Declaration
public const string AuthorizationKey = "Authorization"
Field Value
|
Edit this page
View Source
Declaration
public const string BearerTemplate = "Bearer {0}"
Field Value
|
Edit this page
View Source
Declaration
public const string ContentTypeKey = "Content-Type"
Field Value
|
Edit this page
View Source
Declaration
public const string XApiKeyKey = "x-api-key"
Field Value
|
Edit this page
View Source
Declaration
public const string XiApiKeyKey = "xi-api-key"
Field Value
|
Edit this page
View Source
Declaration
[SerializeField]
[FormerlySerializedAs("name")]
public string key
Field Value
|
Edit this page
View Source
Declaration
[SerializeField]
public string logValue
Field Value
|
Edit this page
View Source
Declaration
[SerializeField]
public bool removeOnRedirect
Field Value
|
Edit this page
View Source
Declaration
[SerializeField]
public string value
Field Value
Methods
|
Edit this page
View Source
Declaration
public static HttpHeader Bearer(string token, bool removeOnRedirect = false)
Parameters
| Type |
Name |
Description |
| string |
token |
|
| bool |
removeOnRedirect |
|
Returns
|
Edit this page
View Source
Declaration
public static HttpHeader ContentType(MimeType contentType, bool removeOnRedirect = false)
Parameters
| Type |
Name |
Description |
| MimeType |
contentType |
|
| bool |
removeOnRedirect |
|
Returns
|
Edit this page
View Source
Declaration
public readonly bool IsValid()
Returns
|
Edit this page
View Source
Validates the object's parameters and throws if invalid.
Declaration
public readonly void Validate()
|
Edit this page
View Source
Declaration
public static HttpHeader XApiKey(string apiKey, bool removeOnRedirect = false)
Parameters
| Type |
Name |
Description |
| string |
apiKey |
|
| bool |
removeOnRedirect |
|
Returns
|
Edit this page
View Source
Declaration
public static HttpHeader XiApiKey(string apiKey, bool removeOnRedirect = false)
Parameters
| Type |
Name |
Description |
| string |
apiKey |
|
| bool |
removeOnRedirect |
|
Returns
Implements
Extension Methods