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


import java.time.OffsetDateTime

import jooq.main.tables.Vacancy
import jooq.main.tables.records.VacancyRecord

import kotlin.collections.List

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


/**
 * This class is generated by jOOQ.
 */
@Suppress("UNCHECKED_CAST")
open class VacancyDao(configuration: Configuration?) : DAOImpl<VacancyRecord, jooq.main.tables.pojos.Vacancy, Long>(Vacancy.VACANCY, jooq.main.tables.pojos.Vacancy::class.java, configuration) {

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

    override fun getId(o: jooq.main.tables.pojos.Vacancy): 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.Vacancy> = fetchRange(Vacancy.VACANCY.ID, lowerInclusive, upperInclusive)

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

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

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

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

    /**
     * Fetch records that have <code>location BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfLocation(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Vacancy> = fetchRange(Vacancy.VACANCY.LOCATION, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>location IN (values)</code>
     */
    fun fetchByLocation(vararg values: String): List<jooq.main.tables.pojos.Vacancy> = fetch(Vacancy.VACANCY.LOCATION, *values)

    /**
     * Fetch records that have <code>company_id BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfCompanyId(lowerInclusive: Long?, upperInclusive: Long?): List<jooq.main.tables.pojos.Vacancy> = fetchRange(Vacancy.VACANCY.COMPANY_ID, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>company_id IN (values)</code>
     */
    fun fetchByCompanyId(vararg values: Long): List<jooq.main.tables.pojos.Vacancy> = fetch(Vacancy.VACANCY.COMPANY_ID, *values.toTypedArray())

    /**
     * Fetch records that have <code>kotliner_id BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfKotlinerId(lowerInclusive: Long?, upperInclusive: Long?): List<jooq.main.tables.pojos.Vacancy> = fetchRange(Vacancy.VACANCY.KOTLINER_ID, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>kotliner_id IN (values)</code>
     */
    fun fetchByKotlinerId(vararg values: Long): List<jooq.main.tables.pojos.Vacancy> = fetch(Vacancy.VACANCY.KOTLINER_ID, *values.toTypedArray())

    /**
     * Fetch records that have <code>workplace BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfWorkplace(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Vacancy> = fetchRange(Vacancy.VACANCY.WORKPLACE, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>workplace IN (values)</code>
     */
    fun fetchByWorkplace(vararg values: String): List<jooq.main.tables.pojos.Vacancy> = fetch(Vacancy.VACANCY.WORKPLACE, *values)

    /**
     * Fetch records that have <code>employment BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfEmployment(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Vacancy> = fetchRange(Vacancy.VACANCY.EMPLOYMENT, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>employment IN (values)</code>
     */
    fun fetchByEmployment(vararg values: String): List<jooq.main.tables.pojos.Vacancy> = fetch(Vacancy.VACANCY.EMPLOYMENT, *values)

    /**
     * Fetch records that have <code>salary BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfSalary(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Vacancy> = fetchRange(Vacancy.VACANCY.SALARY, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>salary IN (values)</code>
     */
    fun fetchBySalary(vararg values: String): List<jooq.main.tables.pojos.Vacancy> = fetch(Vacancy.VACANCY.SALARY, *values)

    /**
     * Fetch records that have <code>contact BETWEEN lowerInclusive AND
     * upperInclusive</code>
     */
    fun fetchRangeOfContact(lowerInclusive: String?, upperInclusive: String?): List<jooq.main.tables.pojos.Vacancy> = fetchRange(Vacancy.VACANCY.CONTACT, lowerInclusive, upperInclusive)

    /**
     * Fetch records that have <code>contact IN (values)</code>
     */
    fun fetchByContact(vararg values: String): List<jooq.main.tables.pojos.Vacancy> = fetch(Vacancy.VACANCY.CONTACT, *values)

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

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

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

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

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

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