aboutsummaryrefslogtreecommitdiff
path: root/src/models/boil_types.go
diff options
context:
space:
mode:
authorAlexander Kavon <me+git@alexkavon.com>2024-01-22 00:35:44 -0500
committerAlexander Kavon <me+git@alexkavon.com>2024-01-22 00:35:44 -0500
commitd6fdb3a460eb228d7b1cd7870b7ef6c8c7391f0b (patch)
treef0fdc9963f9da9eae89e34ddbd401f8fc2cdd65c /src/models/boil_types.go
parent857a7dd47a42faeee4c91e8089905b2ba7135bb7 (diff)
sqlboiler and generated models
Diffstat (limited to 'src/models/boil_types.go')
-rw-r--r--src/models/boil_types.go52
1 files changed, 52 insertions, 0 deletions
diff --git a/src/models/boil_types.go b/src/models/boil_types.go
new file mode 100644
index 0000000..f1157ed
--- /dev/null
+++ b/src/models/boil_types.go
@@ -0,0 +1,52 @@
+// Code generated by SQLBoiler 4.16.1 (https://github.com/volatiletech/sqlboiler). DO NOT EDIT.
+// This file is meant to be re-generated in place and/or deleted at any time.
+
+package models
+
+import (
+ "strconv"
+
+ "github.com/friendsofgo/errors"
+ "github.com/volatiletech/sqlboiler/v4/boil"
+ "github.com/volatiletech/strmangle"
+)
+
+// M type is for providing columns and column values to UpdateAll.
+type M map[string]interface{}
+
+// ErrSyncFail occurs during insert when the record could not be retrieved in
+// order to populate default value information. This usually happens when LastInsertId
+// fails or there was a primary key configuration that was not resolvable.
+var ErrSyncFail = errors.New("models: failed to synchronize data after insert")
+
+type insertCache struct {
+ query string
+ retQuery string
+ valueMapping []uint64
+ retMapping []uint64
+}
+
+type updateCache struct {
+ query string
+ valueMapping []uint64
+}
+
+func makeCacheKey(cols boil.Columns, nzDefaults []string) string {
+ buf := strmangle.GetBuffer()
+
+ buf.WriteString(strconv.Itoa(cols.Kind))
+ for _, w := range cols.Cols {
+ buf.WriteString(w)
+ }
+
+ if len(nzDefaults) != 0 {
+ buf.WriteByte('.')
+ }
+ for _, nz := range nzDefaults {
+ buf.WriteString(nz)
+ }
+
+ str := buf.String()
+ strmangle.PutBuffer(buf)
+ return str
+}