GigyaApiResponse

open class GigyaApiResponse

Gigya generic response class.

Constructors

Link copied to clipboard
constructor(json: String)

Properties

Link copied to clipboard
open val gson: Gson
Link copied to clipboard
val INVALID_VALUE: Int = -1
Link copied to clipboard
val OK: Int = 200

Functions

Link copied to clipboard
open fun asJson(): String
Get JSON formatted of the current response.
Link copied to clipboard
open fun asMap(): Map<String, Any>
Get Map formatted of the current response.
Link copied to clipboard
open fun contains(key: String): Boolean
Check if response parameters contains a specific key.
Link copied to clipboard
open fun containsNested(key: String): Boolean
Check if response parameters contains a specific nested key.
Link copied to clipboard
Get response callId.
Link copied to clipboard
open fun getErrorCode(): Int
Get response error code.
Link copied to clipboard
Get response error details if exists.
Link copied to clipboard
open fun getErrorFlags(): String
Get response error flags if exists.
Link copied to clipboard
open fun <T> getField(key: String, clazz: Class<T>): T
Type field optional getter.
Link copied to clipboard
open fun getStatusCode(): Int
Get response status code
Link copied to clipboard
Get response status reason if exists.
Link copied to clipboard
open fun getTime(): String
Get response time.
Link copied to clipboard
open fun <A> parseAccountTo(clazz: Class<A>): A
Account object requires specific parser in order to be aligned with Site schema object.
Link copied to clipboard
open fun <T> parseTo(clazz: Class<T>): T
Optional parsing of the current response with generic given type.