/*
 * This file is generated by jOOQ.
 */
package jj.tech.paolu.repository.jooq.tables.records;


import jj.tech.paolu.repository.jooq.tables.SysOrg;

import org.jooq.Field;
import org.jooq.Record1;
import org.jooq.Record4;
import org.jooq.Row4;
import org.jooq.impl.UpdatableRecordImpl;


/**
 * This class is generated by jOOQ.
 */
@SuppressWarnings({ "all", "unchecked", "rawtypes", "this-escape" })
public class SysOrgRecord extends UpdatableRecordImpl<SysOrgRecord> implements Record4<String, String, Integer, String> {

    private static final long serialVersionUID = 1L;

    /**
     * Setter for <code>yx.sys_org.id</code>.
     */
    public void setId(String value) {
        set(0, value);
    }

    /**
     * Getter for <code>yx.sys_org.id</code>.
     */
    public String getId() {
        return (String) get(0);
    }

    /**
     * Setter for <code>yx.sys_org.pid</code>.
     */
    public void setPid(String value) {
        set(1, value);
    }

    /**
     * Getter for <code>yx.sys_org.pid</code>.
     */
    public String getPid() {
        return (String) get(1);
    }

    /**
     * Setter for <code>yx.sys_org.status</code>.
     */
    public void setStatus(Integer value) {
        set(2, value);
    }

    /**
     * Getter for <code>yx.sys_org.status</code>.
     */
    public Integer getStatus() {
        return (Integer) get(2);
    }

    /**
     * Setter for <code>yx.sys_org.org_type</code>.
     */
    public void setOrgType(String value) {
        set(3, value);
    }

    /**
     * Getter for <code>yx.sys_org.org_type</code>.
     */
    public String getOrgType() {
        return (String) get(3);
    }

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

    @Override
    public Record1<String> key() {
        return (Record1) super.key();
    }

    // -------------------------------------------------------------------------
    // Record4 type implementation
    // -------------------------------------------------------------------------

    @Override
    public Row4<String, String, Integer, String> fieldsRow() {
        return (Row4) super.fieldsRow();
    }

    @Override
    public Row4<String, String, Integer, String> valuesRow() {
        return (Row4) super.valuesRow();
    }

    @Override
    public Field<String> field1() {
        return SysOrg.SYS_ORG.ID;
    }

    @Override
    public Field<String> field2() {
        return SysOrg.SYS_ORG.PID;
    }

    @Override
    public Field<Integer> field3() {
        return SysOrg.SYS_ORG.STATUS;
    }

    @Override
    public Field<String> field4() {
        return SysOrg.SYS_ORG.ORG_TYPE;
    }

    @Override
    public String component1() {
        return getId();
    }

    @Override
    public String component2() {
        return getPid();
    }

    @Override
    public Integer component3() {
        return getStatus();
    }

    @Override
    public String component4() {
        return getOrgType();
    }

    @Override
    public String value1() {
        return getId();
    }

    @Override
    public String value2() {
        return getPid();
    }

    @Override
    public Integer value3() {
        return getStatus();
    }

    @Override
    public String value4() {
        return getOrgType();
    }

    @Override
    public SysOrgRecord value1(String value) {
        setId(value);
        return this;
    }

    @Override
    public SysOrgRecord value2(String value) {
        setPid(value);
        return this;
    }

    @Override
    public SysOrgRecord value3(Integer value) {
        setStatus(value);
        return this;
    }

    @Override
    public SysOrgRecord value4(String value) {
        setOrgType(value);
        return this;
    }

    @Override
    public SysOrgRecord values(String value1, String value2, Integer value3, String value4) {
        value1(value1);
        value2(value2);
        value3(value3);
        value4(value4);
        return this;
    }

    // -------------------------------------------------------------------------
    // Constructors
    // -------------------------------------------------------------------------

    /**
     * Create a detached SysOrgRecord
     */
    public SysOrgRecord() {
        super(SysOrg.SYS_ORG);
    }

    /**
     * Create a detached, initialised SysOrgRecord
     */
    public SysOrgRecord(String id, String pid, Integer status, String orgType) {
        super(SysOrg.SYS_ORG);

        setId(id);
        setPid(pid);
        setStatus(status);
        setOrgType(orgType);
        resetChangedOnNotNull();
    }

    /**
     * Create a detached, initialised SysOrgRecord
     */
    public SysOrgRecord(jj.tech.paolu.repository.jooq.tables.pojos.SysOrg value) {
        super(SysOrg.SYS_ORG);

        if (value != null) {
            setId(value.getId());
            setPid(value.getPid());
            setStatus(value.getStatus());
            setOrgType(value.getOrgType());
            resetChangedOnNotNull();
        }
    }
}
