All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.komapper.dialect.oracle.OracleRelationUpdateStatementBuilder.kt Maven / Gradle / Ivy

There is a newer version: 4.0.0
Show newest version
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.RelationUpdateStatementBuilder
import org.komapper.core.dsl.context.RelationUpdateContext
import org.komapper.core.dsl.expression.Operand
import org.komapper.core.dsl.metamodel.EntityMetamodel
import org.komapper.core.dsl.metamodel.PropertyMetamodel

class OracleRelationUpdateStatementBuilder>(
    private val dialect: BuilderDialect,
    private val context: RelationUpdateContext,
) : RelationUpdateStatementBuilder {

    private val buf = StatementBuffer()
    private val builder = RelationUpdateStatementBuilder(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()
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy