//
// Code generated by go-jet DO NOT EDIT.
// Generated at Wednesday, 17-Jul-19 13:11:01 CEST
//
// WARNING: Changes to this file may cause incorrect behavior
// and will be lost if the code is regenerated
//

package table

import (
	"github.com/go-jet/jet"
)

var Language = newLanguageTable()

type LanguageTable struct {
	jet.Table

	//Columns
	LanguageID jet.ColumnInteger
	Name       jet.ColumnString
	LastUpdate jet.ColumnTimestamp

	AllColumns     jet.ColumnList
	MutableColumns jet.ColumnList
}

// creates new LanguageTable with assigned alias
func (a *LanguageTable) AS(alias string) *LanguageTable {
	aliasTable := newLanguageTable()

	aliasTable.Table.AS(alias)

	return aliasTable
}

func newLanguageTable() *LanguageTable {
	var (
		LanguageIDColumn = jet.IntegerColumn("language_id")
		NameColumn       = jet.StringColumn("name")
		LastUpdateColumn = jet.TimestampColumn("last_update")
	)

	return &LanguageTable{
		Table: jet.NewTable("dvds", "language", LanguageIDColumn, NameColumn, LastUpdateColumn),

		//Columns
		LanguageID: LanguageIDColumn,
		Name:       NameColumn,
		LastUpdate: LastUpdateColumn,

		AllColumns:     jet.ColumnList{LanguageIDColumn, NameColumn, LastUpdateColumn},
		MutableColumns: jet.ColumnList{NameColumn, LastUpdateColumn},
	}
}
