HUBJSONBoolPath

@protocol HUBJSONBoolPath <HUBJSONPath>

Protocol defining the API of a JSON path that points to a BOOL value

See HUBJSONPath and HUBMutableJSONPath for more information on how JSON paths work.

  • Return a BOOL value by following this path in a JSON dictionary

    Declaration

    Objective-C

    - (BOOL)boolFromJSONDictionary:
        (nonnull NSDictionary<NSString *, NSObject *> *)dictionary;

    Parameters

    dictionary

    The JSON dictionary to apply the path on

    Return Value

    A BOOL found by following the path, or NO as the default in case an operation in the path failed, or if the found value couldn’t be converted into a BOOL.