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

dev.bannmann.anansi.postgresql.generated.tables.Fingerprint Maven / Gradle / Ivy

The newest version!
/*
 * This file is generated by jOOQ.
 */
package dev.bannmann.anansi.postgresql.generated.tables;


import dev.bannmann.anansi.postgresql.generated.DefaultSchema;
import dev.bannmann.anansi.postgresql.generated.Keys;
import dev.bannmann.anansi.postgresql.generated.tables.records.FingerprintRecord;

import java.util.function.Function;

import org.jooq.Field;
import org.jooq.ForeignKey;
import org.jooq.Function5;
import org.jooq.Name;
import org.jooq.Record;
import org.jooq.Records;
import org.jooq.Row5;
import org.jooq.Schema;
import org.jooq.SelectField;
import org.jooq.Table;
import org.jooq.TableField;
import org.jooq.TableOptions;
import org.jooq.UniqueKey;
import org.jooq.impl.DSL;
import org.jooq.impl.SQLDataType;
import org.jooq.impl.TableImpl;


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

    private static final long serialVersionUID = 1L;

    /**
     * The reference instance of fingerprint
     */
    public static final Fingerprint FINGERPRINT = new Fingerprint();

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

    /**
     * The column fingerprint.id.
     */
    public final TableField ID = createField(DSL.name("id"), SQLDataType.VARCHAR(8).nullable(false), this, "");

    /**
     * The column fingerprint.name.
     */
    public final TableField NAME = createField(DSL.name("name"), SQLDataType.VARCHAR(256).nullable(false), this, "");

    /**
     * The column fingerprint.location.
     */
    public final TableField LOCATION = createField(DSL.name("location"), SQLDataType.VARCHAR(512), this, "");

    /**
     * The column fingerprint.frames.
     */
    public final TableField FRAMES = createField(DSL.name("frames"), SQLDataType.VARCHAR(8192).nullable(false), this, "");

    /**
     * The column fingerprint.extra_data.
     */
    public final TableField EXTRA_DATA = createField(DSL.name("extra_data"), SQLDataType.VARCHAR(4096).nullable(false), this, "");

    private Fingerprint(Name alias, Table aliased) {
        this(alias, aliased, null);
    }

    private Fingerprint(Name alias, Table aliased, Field[] parameters) {
        super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table());
    }

    /**
     * Create an aliased fingerprint table reference
     */
    public Fingerprint(String alias) {
        this(DSL.name(alias), FINGERPRINT);
    }

    /**
     * Create an aliased fingerprint table reference
     */
    public Fingerprint(Name alias) {
        this(alias, FINGERPRINT);
    }

    /**
     * Create a fingerprint table reference
     */
    public Fingerprint() {
        this(DSL.name("fingerprint"), null);
    }

    public  Fingerprint(Table child, ForeignKey key) {
        super(child, key, FINGERPRINT);
    }

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

    @Override
    public UniqueKey getPrimaryKey() {
        return Keys.FINGERPRINT_PK;
    }

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

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

    @Override
    public Fingerprint as(Table alias) {
        return new Fingerprint(alias.getQualifiedName(), this);
    }

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

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

    /**
     * Rename this table
     */
    @Override
    public Fingerprint rename(Table name) {
        return new Fingerprint(name.getQualifiedName(), null);
    }

    // -------------------------------------------------------------------------
    // Row5 type methods
    // -------------------------------------------------------------------------

    @Override
    public Row5 fieldsRow() {
        return (Row5) super.fieldsRow();
    }

    /**
     * Convenience mapping calling {@link SelectField#convertFrom(Function)}.
     */
    public  SelectField mapping(Function5 from) {
        return convertFrom(Records.mapping(from));
    }

    /**
     * Convenience mapping calling {@link SelectField#convertFrom(Class,
     * Function)}.
     */
    public  SelectField mapping(Class toType, Function5 from) {
        return convertFrom(toType, Records.mapping(from));
    }
}