oceanbase
32 строки · 1.6 Кб
1// Code generated by entc, DO NOT EDIT.
2
3package ent4
5import (6"time"7
8"github.com/oceanbase/configserver/ent/obcluster"9"github.com/oceanbase/configserver/ent/schema"10)
11
12// The init function reads all schema descriptors with runtime code
13// (default values, validators, hooks and policies) and stitches it
14// to their package variables.
15func init() {16obclusterFields := schema.ObCluster{}.Fields()17_ = obclusterFields18// obclusterDescCreateTime is the schema descriptor for create_time field.19obclusterDescCreateTime := obclusterFields[0].Descriptor()20// obcluster.DefaultCreateTime holds the default value on creation for the create_time field.21obcluster.DefaultCreateTime = obclusterDescCreateTime.Default.(func() time.Time)22// obclusterDescUpdateTime is the schema descriptor for update_time field.23obclusterDescUpdateTime := obclusterFields[1].Descriptor()24// obcluster.DefaultUpdateTime holds the default value on creation for the update_time field.25obcluster.DefaultUpdateTime = obclusterDescUpdateTime.Default.(func() time.Time)26// obcluster.UpdateDefaultUpdateTime holds the default value on update for the update_time field.27obcluster.UpdateDefaultUpdateTime = obclusterDescUpdateTime.UpdateDefault.(func() time.Time)28// obclusterDescObClusterID is the schema descriptor for ob_cluster_id field.29obclusterDescObClusterID := obclusterFields[3].Descriptor()30// obcluster.ObClusterIDValidator is a validator for the "ob_cluster_id" field. It is called by the builders before save.31obcluster.ObClusterIDValidator = obclusterDescObClusterID.Validators[0].(func(int64) error)32}
33