mirror of
https://github.com/groue/GRDB.swift
synced 2026-11-25 04:07:47 +00:00
AnyFetchRequest is now generic on RowDecoder
This commit is contained in:
1 parent
94b4131ce4
commit
76e0a9f6b6
2 files changed
+4
-3
No files matched your search
@@ -146,9 +146,7 @@ public struct AdaptedFetchRequest<Base: FetchRequest>: FetchRequest {
|
||||
///
|
||||
/// An AnyFetchRequest forwards its operations to an underlying request,
|
||||
/// hiding its specifics.
|
||||
public struct AnyFetchRequest<T>: FetchRequest {
|
||||
public typealias RowDecoder = T
|
||||
|
||||
public struct AnyFetchRequest<RowDecoder>: FetchRequest {
|
||||
private let _preparedRequest: (Database, _ singleResult: Bool) throws -> PreparedRequest
|
||||
private let _fetchCount: (Database) throws -> Int
|
||||
private let _databaseRegion: (Database) throws -> DatabaseRegion
|
||||
|
||||
@@ -7,6 +7,9 @@ import UIKit
|
||||
#endif
|
||||
|
||||
extension AnyFetchRequest {
|
||||
@available(*, unavailable, renamed: "RowDecoder")
|
||||
typealias T = RowDecoder
|
||||
|
||||
@available(*, unavailable, message: "Define your own FetchRequest type instead.")
|
||||
public init(_ prepare: @escaping (Database, _ singleResult: Bool) throws -> (SelectStatement, RowAdapter?))
|
||||
{ preconditionFailure() }
|
||||
|
||||
Reference in new issue
Block a user