stephencelis / SQLite.swift

A type-safe, Swift-language layer over SQLite3.
MIT License
9.57k stars 1.54k forks source link

Make ithe IndexDefinition properties public #1196

Closed stefansaasen closed 1 year ago

stefansaasen commented 1 year ago

The documentation suggests that the index schema information can be queried. That requires the IndexDefinition properties to be public.

At the moment, the following code does not work, when used in an project that depends on SQLite.swift:

let indexes = try schema.indexDefinitions("users")

for index in indexes {
    print("\(index.name) columns:\(index.columns))") // <- index.name and index.columns is not visible
}

ObjectDefinition and ColumnDefinition properties are already public, so it seems not to far fetched to change the IndexDefinition properties as well?