Class RESTResponse
The base class for all API objects returned by Glitch9.IO.Networking.RESTApi.RESTApiV7.
This class encapsulates common properties and methods for handling
various types of outputs from REST API responses.
Assembly: Glitch9.IO.dll
Syntax
public class RESTResponse : ResultBase, IResult
Properties
|
Edit this page
View Source
AudioOutput
Audio data output from the API as an AudioClip object
Declaration
public AudioOutput AudioOutput { get; set; }
Property Value
|
Edit this page
View Source
BinaryOutput
Binary data output from the API
Declaration
public ReadOnlyMemory<byte> BinaryOutput { get; set; }
Property Value
|
Edit this page
View Source
FileOutput
File output from the API as a UnityFile object
Declaration
public SerializableFile FileOutput { get; set; }
Property Value
|
Edit this page
View Source
HasBody
Whether the API response has an empty body.
Declaration
public virtual bool HasBody { get; }
Property Value
|
Edit this page
View Source
HTTP headers returned in the API response
Declaration
public Dictionary<string, string> Headers { get; set; }
Property Value
|
Edit this page
View Source
ImageOutput
Image data output from the API as a Texture2D object
Declaration
public ImageOutput ImageOutput { get; set; }
Property Value
|
Edit this page
View Source
IsSuccess
Declaration
public override bool IsSuccess { get; }
Property Value
Overrides
|
Edit this page
View Source
OutputPath
The absolute path (full path) where the output file is saved
Declaration
public string OutputPath { get; set; }
Property Value
|
Edit this page
View Source
StatusCode
The HTTP status code of the API response.
Declaration
public long StatusCode { get; set; }
Property Value
|
Edit this page
View Source
TextOutput
Text data output from the API
Declaration
public string TextOutput { get; set; }
Property Value
Methods
|
Edit this page
View Source
FromUwr<T>(UnityWebRequest)
Declaration
public static T FromUwr<T>(UnityWebRequest uwr) where T : RESTResponse, new()
Parameters
| Type |
Name |
Description |
| UnityWebRequest |
uwr |
|
Returns
Type Parameters
|
Edit this page
View Source
Declaration
public string GetHeader(string headerName)
Parameters
| Type |
Name |
Description |
| string |
headerName |
|
Returns
Implements
Extension Methods