MCPcopy Create free account
hub / github.com/actiontech/dtle / StringElse

Function StringElse

g/util.go:121–127  ·  view source on GitHub ↗

Return s1 if it is not empty, or else s2.

(s1 string, s2 string)

Source from the content-addressed store, hash-verified

119
120// Return s1 if it is not empty, or else s2.
121func StringElse(s1 string, s2 string) string {
122 if s1 != "" {
123 return s1
124 } else {
125 return s2
126 }
127}
128
129func CurrentTimeMillis() int64 {
130 return time.Now().UnixNano() / 1000000

Callers 10

oracleDumpMethod · 0.92
inspectTablesMethod · 0.92
readTableColumnsMethod · 0.92
mysqlDumpMethod · 0.92
getChunkDataMethod · 0.92
handleQueryEventMethod · 0.92
loadMappingMethod · 0.92
resolveQueryMethod · 0.92
addFKChildrenMethod · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected