             return ["$or": .array(Document(array: expressions)) ]
         case .not(let aqt):
             return ["$not": ~aqt.document]
+        case .contains(let key, let val):
+            return [key: .string("/\(val.val)/")]
+        case .startsWith(let key, let val):
+            return [key: .string("/^\(val.val)/")]
+        case .endsWith(let key, let val):
+            return [key: .string("/\(val.val)$/")]
         case .nothing:
             return []
         }

            return false
        case .not(let aqt):
            return !self.matches(query: Query(aqt: aqt))
        case .nothing:
            return true
        }

    
    /// Whether nothing needs to be matched. Is always true and just a placeholder
    case nothing
    
    /// Whether the String value within the `key` contains this `Value` as a String.
    case contains(key: String, val: ValueProtocol)
    
    /// Whether the String value within the `key` starts with this `Value` as a String.
    case startsWith(key: String, val: ValueProtocol)
    
    /// Whether the String value within the `key` ends with this `Value` as a String.
    case endsWith(key: String, val: ValueProtocol)
}

/// The protocol all queries need to comply to
