#import <MPJSONModelError.h>
Inherits NSError.
Custom NSError subclass with shortcut methods for creating the common MPJSONModel errors
◆ errorBadJSON
◆ errorBadResponse
◆ errorByPrependingKeyPathComponent:
- (instancetype) errorByPrependingKeyPathComponent: |
|
(NSString *) |
component |
|
Creates a new MPJSONModelError with the same values plus information about the key-path of the error. Properties in the new error object are the same as those from the receiver, except that a new key kMPJSONModelKeyPath is added to the userInfo dictionary. This key contains the component string parameter. If the key is already present then the new error object has the component string prepended to the existing value.
◆ errorInputIsNil
◆ errorInvalidDataWithMessage:
+ (id) errorInvalidDataWithMessage: |
|
(NSString *) |
message |
|
◆ errorInvalidDataWithMissingKeys:
+ (id) errorInvalidDataWithMissingKeys: |
|
(NSSet *) |
keys |
|
Creates a MPJSONModelError instance with code kMPJSONModelErrorInvalidData = 1
- Parameters
-
keys | a set of field names that were required, but not found in the input |
◆ errorInvalidDataWithTypeMismatch:
+ (id) errorInvalidDataWithTypeMismatch: |
|
(NSString *) |
mismatchDescription |
|
Creates a MPJSONModelError instance with code kMPJSONModelErrorInvalidData = 1
- Parameters
-
mismatchDescription | description of the type mismatch that was encountered. |
◆ errorModelIsInvalid
+ (id) errorModelIsInvalid |
|
|
|
Creates a MPJSONModelError instance with code kMPJSONModelErrorModelIsInvalid = 4
The documentation for this class was generated from the following file: