     func results(matching pattern: QuadPattern) throws -> AnyIterator<TermResult>
     func quads(matching pattern: QuadPattern) throws -> AnyIterator<Quad>
     func effectiveVersion(matching pattern: QuadPattern) throws -> Version?
+}
+
+extension QuadStoreProtocol {
+    public func effectiveVersion() throws -> Version? {
+        let pattern = QuadPattern(
+            subject: .variable("s", binding: true),
+            predicate: .variable("p", binding: true),
+            object: .variable("o", binding: true),
+            graph: .variable("g", binding: true)
+        )
+        return try effectiveVersion(matching: pattern)
+    }
 }
 
 // swiftlint:disable:next type_body_length

                return !defaultQuadsIndex.contains(key: indexOrder)
            }

            for spogquad in spog {
                let indexOrder = toIndex(spogquad)
                let pair = (indexOrder, empty)

        self.id = try PersistentTermIdentityMap(mediator: mediator, readonly: readonly)
    }

    public var count : Int {
        let pattern = QuadPattern(
            subject: .variable("s", binding: true),
            predicate: .variable("p", binding: true),
            object: .variable("o", binding: true),
            graph: .variable("g", binding: true)
        )
        return count(matching: pattern)
    }
    
    public func count(matching pattern: QuadPattern) -> Int {
        guard let idquads = try? idquads(matching: pattern) else { return 0 }
        var count = 0
        for _ in idquads {
            count += 1
        }
        return count
    }
    
    public static func create(mediator: RWMediator) throws -> QuadStore {
        do {
            _ = try PersistentTermIdentityMap(mediator: mediator)
