MCPcopy Create free account
hub / github.com/LissaGreense/GO4SQL / isGreaterThan

Method isGreaterThan

engine/generic_value.go:129–141  ·  view source on GitHub ↗
(secondValue ValueInterface)

Source from the content-addressed store, hash-verified

127 return value.Value > secondValueAsInteger.Value
128}
129func (value StringValue) isGreaterThan(secondValue ValueInterface) bool {
130 nullValue, isNull := secondValue.(NullValue)
131 if isNull {
132 return nullValue.isSmallerThan(value)
133 }
134
135 secondValueAsString, isString := secondValue.(StringValue)
136 if !isString {
137 log.Fatal("Can't compare String with other type")
138 }
139
140 return value.Value > secondValueAsString.Value
141}
142
143func (value NullValue) isGreaterThan(_ ValueInterface) bool {
144 return false

Callers 1

TestIsGreaterThanFunction · 0.95

Calls 1

isSmallerThanMethod · 0.65

Tested by 1

TestIsGreaterThanFunction · 0.76