Array
extension Array: CorvusResponse where Element: CorvusResponse
extension Array: Endpoint where Element == Endpoint
Allows ResponseModifier to work with Arrays of CorvusResponse
Instead of returning a single CorvusResponse
an array of CorvusResponse
can be returned instead.
-
Initializes a
CorvusResponse
which is anArray
by initializing its children.Declaration
Swift
public init(item: [Element.Item])
Parameters
item
The values of the items in the
Array
.
-
An
Array
ofEndpoint
is registered by registering all of theArray
‘s elements.Declaration
Swift
public func register(to routes: RoutesBuilder)
Parameters
routes
The
RoutesBuilder
containing HTTP route information up to this point.