FWCompoundResponseSerializer
@interface FWCompoundResponseSerializer : FWHTTPResponseSerializer
FWCompoundSerializer is a subclass of FWHTTPResponseSerializer that delegates the response serialization to the first FWHTTPResponseSerializer object that returns an object for responseObjectForResponse:data:error:, falling back on the default behavior of FWHTTPResponseSerializer. This is useful for supporting multiple potential types and structures of server responses with a single serializer.
-
The component response serializers.
Declaration
Objective-C
@property (nonatomic, copy, readonly) NSArray<id<FWURLResponseSerialization>> *_Nonnull responseSerializers; -
Creates and returns a compound serializer comprised of the specified response serializers.
Warning
Each response serializer specified must be a subclass ofFWHTTPResponseSerializer, and response to-validateResponse:data:error:.Declaration
Objective-C
+ (nonnull instancetype)compoundSerializerWithResponseSerializers: (nonnull NSArray<id<FWURLResponseSerialization>> *)responseSerializers;
FWCompoundResponseSerializer Class Reference