Ok, so I'm trying to build something like the foll...
# arrow
b
Ok, so I'm trying to build something like the following:
Copy code
fun constructQuery(QS: QuerySyntax) {
    with (QS) {
        "SELECT sum, cc FROM summary WHERE idx1 = " + fr<Int>("idx1") + " AND idx2 = " + fr<Long>("idx2")
    }
}
with the idea that whatever the result of the
with (QS)
block is is something like
TypedQuery<Int, Long, Result>
and has a
bind(p1: Int, p2: Long)
as a method signature. I think I want to accumulate this incrementally, so I think the sequence is something like the following
Copy code
(String).plus(fr: Fragment<Int>) -> TypedQuery<Int, Result>
TypedQuery<Int, Result>.plus(s: String) -> TypedQuery<Int, Result>
TypedQuery<Int, Result>.plus(fr: Fragment<Long>) -> TypedQuery<Int, Long, Result>
But I think I'm starting to walk into
Kind<TypedQuery, Int, Result>
land here?