org.komapper.dialect.oracle.OracleRelationInsertValuesStatementBuilder.kt Maven / Gradle / Ivy
package org.komapper.dialect.oracle
import org.komapper.core.BuilderDialect
import org.komapper.core.Statement
import org.komapper.core.StatementBuffer
import org.komapper.core.dsl.builder.RelationInsertValuesStatementBuilder
import org.komapper.core.dsl.context.RelationInsertValuesContext
import org.komapper.core.dsl.expression.Operand
import org.komapper.core.dsl.metamodel.EntityMetamodel
import org.komapper.core.dsl.metamodel.PropertyMetamodel
class OracleRelationInsertValuesStatementBuilder>(
dialect: BuilderDialect,
context: RelationInsertValuesContext,
) : RelationInsertValuesStatementBuilder {
private val buf = StatementBuffer()
private val builder = RelationInsertValuesStatementBuilder(dialect, context)
private val support = OracleStatementBuilderSupport(dialect, context)
override fun build(assignments: List, Operand>>): Statement {
buf.append(builder.build(assignments))
buf.appendIfNotEmpty(support.buildReturning())
return buf.toStatement()
}
}