/*
 * This file is generated by jOOQ.
 */
package ervu_secret.ervu_secret.db_beans.pg_catalog.tables;


import ervu_secret.ervu_secret.db_beans.pg_catalog.PgCatalog;
import ervu_secret.ervu_secret.db_beans.pg_catalog.tables.records.TsDebugRecord;

import org.jooq.Condition;
import org.jooq.Field;
import org.jooq.Name;
import org.jooq.Schema;
import org.jooq.Table;
import org.jooq.TableField;
import org.jooq.TableOptions;
import org.jooq.impl.DSL;
import org.jooq.impl.DefaultDataType;
import org.jooq.impl.SQLDataType;
import org.jooq.impl.TableImpl;


/**
 * This class is generated by jOOQ.
 */
@SuppressWarnings({ "all", "unchecked", "rawtypes" })
public class TsDebug extends TableImpl<TsDebugRecord> {

    private static final long serialVersionUID = 1L;

    /**
     * The reference instance of <code>pg_catalog.ts_debug</code>
     */
    public static final TsDebug TS_DEBUG = new TsDebug();

    /**
     * The class holding records for this type
     */
    @Override
    public Class<TsDebugRecord> getRecordType() {
        return TsDebugRecord.class;
    }

    /**
     * The column <code>pg_catalog.ts_debug.alias</code>.
     */
    public final TableField<TsDebugRecord, String> ALIAS = createField(DSL.name("alias"), SQLDataType.CLOB, this, "");

    /**
     * The column <code>pg_catalog.ts_debug.description</code>.
     */
    public final TableField<TsDebugRecord, String> DESCRIPTION = createField(DSL.name("description"), SQLDataType.CLOB, this, "");

    /**
     * The column <code>pg_catalog.ts_debug.token</code>.
     */
    public final TableField<TsDebugRecord, String> TOKEN = createField(DSL.name("token"), SQLDataType.CLOB, this, "");

    /**
     * The column <code>pg_catalog.ts_debug.dictionaries</code>.
     */
    public final TableField<TsDebugRecord, Object[]> DICTIONARIES = createField(DSL.name("dictionaries"), DefaultDataType.getDefaultDataType("\"pg_catalog\".\"regdictionary\"").array(), this, "");

    /**
     * @deprecated Unknown data type. If this is a qualified, user-defined type,
     * it may have been excluded from code generation. If this is a built-in
     * type, you can define an explicit {@link org.jooq.Binding} to specify how
     * this type should be handled. Deprecation can be turned off using
     * {@literal <deprecationOnUnknownTypes/>} in your code generator
     * configuration.
     */
    @Deprecated
    public final TableField<TsDebugRecord, Object> DICTIONARY = createField(DSL.name("dictionary"), DefaultDataType.getDefaultDataType("\"pg_catalog\".\"regdictionary\""), this, "");

    /**
     * The column <code>pg_catalog.ts_debug.lexemes</code>.
     */
    public final TableField<TsDebugRecord, String[]> LEXEMES = createField(DSL.name("lexemes"), SQLDataType.CLOB.array(), this, "");

    private TsDebug(Name alias, Table<TsDebugRecord> aliased) {
        this(alias, aliased, new Field[] {
            DSL.val(null, DefaultDataType.getDefaultDataType("\"pg_catalog\".\"regconfig\"")),
            DSL.val(null, SQLDataType.CLOB)
        });
    }

    private TsDebug(Name alias, Table<TsDebugRecord> aliased, Field<?>[] parameters) {
        this(alias, aliased, parameters, null);
    }

    private TsDebug(Name alias, Table<TsDebugRecord> aliased, Field<?>[] parameters, Condition where) {
        super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.function(), where);
    }

    /**
     * Create an aliased <code>pg_catalog.ts_debug</code> table reference
     */
    public TsDebug(String alias) {
        this(DSL.name(alias), TS_DEBUG);
    }

    /**
     * Create an aliased <code>pg_catalog.ts_debug</code> table reference
     */
    public TsDebug(Name alias) {
        this(alias, TS_DEBUG);
    }

    /**
     * Create a <code>pg_catalog.ts_debug</code> table reference
     */
    public TsDebug() {
        this(DSL.name("ts_debug"), null);
    }

    @Override
    public Schema getSchema() {
        return aliased() ? null : PgCatalog.PG_CATALOG;
    }

    @Override
    public TsDebug as(String alias) {
        return new TsDebug(DSL.name(alias), this, parameters);
    }

    @Override
    public TsDebug as(Name alias) {
        return new TsDebug(alias, this, parameters);
    }

    @Override
    public TsDebug as(Table<?> alias) {
        return new TsDebug(alias.getQualifiedName(), this, parameters);
    }

    /**
     * Rename this table
     */
    @Override
    public TsDebug rename(String name) {
        return new TsDebug(DSL.name(name), null, parameters);
    }

    /**
     * Rename this table
     */
    @Override
    public TsDebug rename(Name name) {
        return new TsDebug(name, null, parameters);
    }

    /**
     * Rename this table
     */
    @Override
    public TsDebug rename(Table<?> name) {
        return new TsDebug(name.getQualifiedName(), null, parameters);
    }

    /**
     * Call this table-valued function
     */
    public TsDebug call(
          Object config
        , String document
    ) {
        TsDebug result = new TsDebug(DSL.name("ts_debug"), null, new Field[] {
            DSL.val(config, DefaultDataType.getDefaultDataType("\"pg_catalog\".\"regconfig\"")),
            DSL.val(document, SQLDataType.CLOB)
        });

        return aliased() ? result.as(getUnqualifiedName()) : result;
    }

    /**
     * Call this table-valued function
     */
    public TsDebug call(
          Field<Object> config
        , Field<String> document
    ) {
        TsDebug result = new TsDebug(DSL.name("ts_debug"), null, new Field[] {
            config,
            document
        });

        return aliased() ? result.as(getUnqualifiedName()) : result;
    }
}
