Initializerswift-bson 0.3.1BSONABI
init(parsing:)
Parses an option set from a MongoDB regex matching options string.
init(parsing string: some StringProtocol) throws
Parses an option set from a MongoDB regex matching options string.
init(parsing string: some StringProtocol) throws
import BSONABI
Models the BSON type system and the binary interface of the BSON serialization format.
@frozen struct Options
A set of MongoDB regex matching options.
@frozen enum BSON
The namespace for all BSON types.
@frozen struct Regex
A MongoDB regex.
protocol StringProtocol : BidirectionalCollection, Comparable, ExpressibleByStringInterpolation, Hashable, LosslessStringConvertible, TextOutputStream, TextOutputStreamable where Self.Element == Character, Self.Index == String.Index, Self.StringInterpolation == DefaultStringInterpolation, Self.SubSequence : StringProtocol
A type that can represent a string as a collection of characters.
init(rawValue: UInt8)
static let i: `Self`
static let l: `Self`
static let m: `Self`
static let s: `Self`
static let u: `Self`
static let x: `Self`
var description: String { get }
This option set, encoded in alphabetical order as a option string.
let rawValue: UInt8
var size: Int { get }
The size of this option set, when encoded as a option string, including its trailing null byte.
func contains(option: BSON.Regex.Option) -> Bool