// Code generated by BobGen psql v0.42.5. DO NOT EDIT.
// This file is meant to be re-generated in place and/or deleted at any time.

package dbinfo

import "github.com/aarondl/opt/null"

var Pools = Table[
	poolColumns,
	poolIndexes,
	poolForeignKeys,
	poolUniques,
	poolChecks,
]{
	Schema: "",
	Name:   "pool",
	Columns: poolColumns{
		Condition: column{
			Name:      "condition",
			DBType:    "public.poolconditiontype",
			Default:   "",
			Comment:   "",
			Nullable:  false,
			Generated: false,
			AutoIncr:  false,
		},
		Created: column{
			Name:      "created",
			DBType:    "timestamp without time zone",
			Default:   "",
			Comment:   "",
			Nullable:  false,
			Generated: false,
			AutoIncr:  false,
		},
		CreatorID: column{
			Name:      "creator_id",
			DBType:    "integer",
			Default:   "",
			Comment:   "",
			Nullable:  false,
			Generated: false,
			AutoIncr:  false,
		},
		ID: column{
			Name:      "id",
			DBType:    "integer",
			Default:   "nextval('pool_id_seq'::regclass)",
			Comment:   "",
			Nullable:  false,
			Generated: false,
			AutoIncr:  false,
		},
		SiteID: column{
			Name:      "site_id",
			DBType:    "integer",
			Default:   "",
			Comment:   "",
			Nullable:  false,
			Generated: false,
			AutoIncr:  false,
		},
		SiteVersion: column{
			Name:      "site_version",
			DBType:    "integer",
			Default:   "",
			Comment:   "",
			Nullable:  false,
			Generated: false,
			AutoIncr:  false,
		},
	},
	Indexes: poolIndexes{
		PoolPkey: index{
			Type: "btree",
			Name: "pool_pkey",
			Columns: []indexColumn{
				{
					Name:         "id",
					Desc:         null.FromCond(false, true),
					IsExpression: false,
				},
			},
			Unique:        true,
			Comment:       "",
			NullsFirst:    []bool{false},
			NullsDistinct: false,
			Where:         "",
			Include:       []string{},
		},
	},
	PrimaryKey: &constraint{
		Name:    "pool_pkey",
		Columns: []string{"id"},
		Comment: "",
	},
	ForeignKeys: poolForeignKeys{
		PoolPoolCreatorIDFkey: foreignKey{
			constraint: constraint{
				Name:    "pool.pool_creator_id_fkey",
				Columns: []string{"creator_id"},
				Comment: "",
			},
			ForeignTable:   "user_",
			ForeignColumns: []string{"id"},
		},
		PoolPoolSiteIDSiteVersionFkey: foreignKey{
			constraint: constraint{
				Name:    "pool.pool_site_id_site_version_fkey",
				Columns: []string{"site_id", "site_version"},
				Comment: "",
			},
			ForeignTable:   "site",
			ForeignColumns: []string{"id", "version"},
		},
	},

	Comment: "",
}

type poolColumns struct {
	Condition   column
	Created     column
	CreatorID   column
	ID          column
	SiteID      column
	SiteVersion column
}

func (c poolColumns) AsSlice() []column {
	return []column{
		c.Condition, c.Created, c.CreatorID, c.ID, c.SiteID, c.SiteVersion,
	}
}

type poolIndexes struct {
	PoolPkey index
}

func (i poolIndexes) AsSlice() []index {
	return []index{
		i.PoolPkey,
	}
}

type poolForeignKeys struct {
	PoolPoolCreatorIDFkey         foreignKey
	PoolPoolSiteIDSiteVersionFkey foreignKey
}

func (f poolForeignKeys) AsSlice() []foreignKey {
	return []foreignKey{
		f.PoolPoolCreatorIDFkey, f.PoolPoolSiteIDSiteVersionFkey,
	}
}

type poolUniques struct{}

func (u poolUniques) AsSlice() []constraint {
	return []constraint{}
}

type poolChecks struct{}

func (c poolChecks) AsSlice() []check {
	return []check{}
}
