[history/cw-adjutant] Table now can be converted to SQL string
This commit is contained in:
parent
b757b4c589
commit
fc29095e2b
@ -91,12 +91,12 @@ public class SqliteNamespace(
|
|||||||
return SqliteTableName(this.formatTableName(name))
|
return SqliteTableName(this.formatTableName(name))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private fun formatTableName(name: String) = this.path.joinToString(prefix = "::", separator = "::", postfix = "::${name}")
|
||||||
private fun formatTableName(name: String) = this.path.joinToString(prefix = "\"::", separator = "::", postfix = "::${name}\"")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@JvmInline
|
public class SqliteTableName(private val name: String) {
|
||||||
public value class SqliteTableName(private val value: String) {
|
public val asSqlReference: String = "\"${this.name}\""
|
||||||
override fun toString(): String = this.value
|
public val asSqlString: String = "\'${this.name}\'"
|
||||||
|
override fun toString(): String = this.asSqlReference
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user