-
An error identifier used for API error.
Declaration
Swift
public let code: Int -
A human (end user friendly) readable/comprehensible description of the error.
Declaration
Swift
public let message: String -
Initializes a PCF error.
- Parameters:
- code: The error code to use.
- message: The error message to use.
Declaration
Swift
public init(code: Int, message: String)Parameters
codeThe error code to use.
messageThe error message to use.
- Parameters:
-
Initializes a PCF error.
- Parameters:
- code: The error code to use.
- message: The error message to use.
Declaration
Swift
public init?(json: JSON)Parameters
jsonJSON representation of object.
Return Value
New instance when JSON parsing successful, false otherwise.
- Parameters:
-
Error for mal-formatted JSON, such as receiving arrays when expecting dictionaries as response.
Declaration
Swift
public static var invalidJSON: PCFError
PCFError Struct Reference