MCPcopy
hub / github.com/uber/aresdb / Less

Method Less

memstore/archiving.go:181–192  ·  view source on GitHub ↗
(i, j int)

Source from the content-addressed store, hash-verified

179}
180
181func (ap archivingPatch) Less(i, j int) bool {
182 for _, columnID := range ap.sortColumns {
183 iValue := ap.GetDataValue(i, columnID)
184 jValue := ap.GetDataValue(j, columnID)
185 res := iValue.Compare(jValue)
186 if res != 0 {
187 return res < 0
188 }
189 // Tie, move on to next sort column.
190 }
191 return false
192}
193
194// GetDataValue reads value from underlying columns after sorted.
195func (ap *archivingPatch) GetDataValue(row, columnID int) memCom.DataValue {

Callers

nothing calls this directly

Calls 2

GetDataValueMethod · 0.95
CompareMethod · 0.80

Tested by

no test coverage detected