/*
 * This file is generated by jOOQ.
 */
package jooq.main.tables.records


import java.time.OffsetDateTime

import jooq.main.tables.DmLikes

import org.jooq.Record1
import org.jooq.impl.UpdatableRecordImpl


/**
 * This class is generated by jOOQ.
 */
@Suppress("UNCHECKED_CAST")
open class DmLikesRecord() : UpdatableRecordImpl<DmLikesRecord>(DmLikes.DM_LIKES) {

    open var entityId: Long?
        set(value): Unit = set(0, value)
        get(): Long? = get(0) as Long?

    open var likes: Int?
        set(value): Unit = set(1, value)
        get(): Int? = get(1) as Int?

    open var dislikes: Int?
        set(value): Unit = set(2, value)
        get(): Int? = get(2) as Int?

    open var updated: OffsetDateTime?
        set(value): Unit = set(3, value)
        get(): OffsetDateTime? = get(3) as OffsetDateTime?

    // -------------------------------------------------------------------------
    // Primary key information
    // -------------------------------------------------------------------------

    override fun key(): Record1<Long?> = super.key() as Record1<Long?>

    /**
     * Create a detached, initialised DmLikesRecord
     */
    constructor(entityId: Long? = null, likes: Int? = null, dislikes: Int? = null, updated: OffsetDateTime? = null): this() {
        this.entityId = entityId
        this.likes = likes
        this.dislikes = dislikes
        this.updated = updated
        resetChangedOnNotNull()
    }

    /**
     * Create a detached, initialised DmLikesRecord
     */
    constructor(value: jooq.main.tables.pojos.DmLikes?): this() {
        if (value != null) {
            this.entityId = value.entityId
            this.likes = value.likes
            this.dislikes = value.dislikes
            this.updated = value.updated
            resetChangedOnNotNull()
        }
    }
}
