C# Class rosette_api.RosetteResponse

Exibir arquivo Open project: rosette-api/csharp Class Usage Examples

Private Properties

Property Type Description
contentToString string
decompress byte[]
headersAsString string

Public Methods

Method Description
ContentToString ( ) : string

Gets the content in JSON form

RosetteResponse ( HttpResponseMessage responseMsg ) : System

RosetteResponse ctor

RosetteResponse ( string>.IDictionary headers, object>.IDictionary content = null, string contentAsJson = null ) : System

Creates a Rosette Response from its components

ToString ( ) : string

ToString override.

Private Methods

Method Description
contentToString ( HttpContent httpContent ) : string

Reads the httpContent value into a string

decompress ( byte gzip ) : byte[]

Decompress

Method to decompress GZIP files Source: http://www.dotnetperls.com/decompress

headersAsString ( ) : string

Method Details

ContentToString() public method

Gets the content in JSON form
public ContentToString ( ) : string
return string

RosetteResponse() public method

RosetteResponse ctor
public RosetteResponse ( HttpResponseMessage responseMsg ) : System
responseMsg System.Net.Http.HttpResponseMessage HttpResponseMessage
return System

RosetteResponse() public method

Creates a Rosette Response from its components
public RosetteResponse ( string>.IDictionary headers, object>.IDictionary content = null, string contentAsJson = null ) : System
headers string>.IDictionary The headers from the API
content object>.IDictionary The content of the response in dictionary form
contentAsJson string The content of the response in JSON
return System

ToString() public method

ToString override.
public ToString ( ) : string
return string