MCPcopy
hub / github.com/go-gorm/gorm / Build

Method Build

clause/from.go:15–32  ·  view source on GitHub ↗

Build build from clause

(builder Builder)

Source from the content-addressed store, hash-verified

13
14// Build build from clause
15func (from From) Build(builder Builder) {
16 if len(from.Tables) > 0 {
17 for idx, table := range from.Tables {
18 if idx > 0 {
19 builder.WriteByte(',')
20 }
21
22 builder.WriteQuoted(table)
23 }
24 } else {
25 builder.WriteQuoted(currentTable)
26 }
27
28 for _, join := range from.Joins {
29 builder.WriteByte(' ')
30 join.Build(builder)
31 }
32}
33
34// MergeClause merge from clause
35func (from From) MergeClause(clause *Clause) {

Callers

nothing calls this directly

Calls 3

WriteByteMethod · 0.65
WriteQuotedMethod · 0.65
BuildMethod · 0.65

Tested by

no test coverage detected