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


import java.time.OffsetDateTime

import jooq.main.tables.Bookmark
import jooq.main.tables.records.BookmarkRecord

import kotlin.collections.List

import org.jooq.Configuration
import org.jooq.impl.DAOImpl


/**
 * This class is generated by jOOQ.
 */
@Suppress("UNCHECKED_CAST")
open class BookmarkDao(configuration: Configuration?) : DAOImpl<BookmarkRecord, jooq.main.tables.pojos.Bookmark, Long>(Bookmark.BOOKMARK, jooq.main.tables.pojos.Bookmark::class.java, configuration) {

    /**
     * Create a new BookmarkDao without any configuration
     */
    constructor(): this(null)

    override fun getId(o: jooq.main.tables.pojos.Bookmark): Long? = o.id

    /**
     * Fetch records that have <code>id BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfId(lowerInclusive: Long?, upperInclusive: Long?): List<jooq.main.tables.pojos.Bookmark> = fetchRange(Bookmark.BOOKMARK.ID, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>id IN (values)</code>
     */
    fun fetchById(vararg values: Long): List<jooq.main.tables.pojos.Bookmark> = fetch(Bookmark.BOOKMARK.ID, *values.toTypedArray())

    /**
     * Fetch a unique record that has <code>id = value</code>
     */
    fun fetchOneById(value: Long): jooq.main.tables.pojos.Bookmark? = fetchOne(Bookmark.BOOKMARK.ID, value)

    /**
     * Fetch records that have <code>title BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfTitle(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Bookmark> = fetchRange(Bookmark.BOOKMARK.TITLE, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>title IN (values)</code>
     */
    fun fetchByTitle(vararg values: String): List<jooq.main.tables.pojos.Bookmark> = fetch(Bookmark.BOOKMARK.TITLE, *values)

    /**
     * Fetch records that have <code>description BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfDescription(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Bookmark> = fetchRange(Bookmark.BOOKMARK.DESCRIPTION, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>description IN (values)</code>
     */
    fun fetchByDescription(vararg values: String): List<jooq.main.tables.pojos.Bookmark> = fetch(Bookmark.BOOKMARK.DESCRIPTION, *values)

    /**
     * Fetch records that have <code>language BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfLanguage(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Bookmark> = fetchRange(Bookmark.BOOKMARK.LANGUAGE, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>language IN (values)</code>
     */
    fun fetchByLanguage(vararg values: String): List<jooq.main.tables.pojos.Bookmark> = fetch(Bookmark.BOOKMARK.LANGUAGE, *values)

    /**
     * Fetch records that have <code>url BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfUrl(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Bookmark> = fetchRange(Bookmark.BOOKMARK.URL, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>url IN (values)</code>
     */
    fun fetchByUrl(vararg values: String): List<jooq.main.tables.pojos.Bookmark> = fetch(Bookmark.BOOKMARK.URL, *values)

    /**
     * Fetch records that have <code>thumbnail BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfThumbnail(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Bookmark> = fetchRange(Bookmark.BOOKMARK.THUMBNAIL, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>thumbnail IN (values)</code>
     */
    fun fetchByThumbnail(vararg values: String): List<jooq.main.tables.pojos.Bookmark> = fetch(Bookmark.BOOKMARK.THUMBNAIL, *values)

    /**
     * Fetch records that have <code>created BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfCreated(lowerInclusive: OffsetDateTime?, upperInclusive: OffsetDateTime?): List<jooq.main.tables.pojos.Bookmark> = fetchRange(Bookmark.BOOKMARK.CREATED, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>created IN (values)</code>
     */
    fun fetchByCreated(vararg values: OffsetDateTime): List<jooq.main.tables.pojos.Bookmark> = fetch(Bookmark.BOOKMARK.CREATED, *values)

    /**
     * Fetch records that have <code>updated BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfUpdated(lowerInclusive: OffsetDateTime?, upperInclusive: OffsetDateTime?): List<jooq.main.tables.pojos.Bookmark> = fetchRange(Bookmark.BOOKMARK.UPDATED, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>updated IN (values)</code>
     */
    fun fetchByUpdated(vararg values: OffsetDateTime): List<jooq.main.tables.pojos.Bookmark> = fetch(Bookmark.BOOKMARK.UPDATED, *values)
}
