apache / iotdb-client-go

Apache IoTDB Client for Go
https://iotdb.apache.org/
Apache License 2.0
56 stars 33 forks source link

iotdb-client-go github actions #6

Closed manlge closed 3 years ago

manlge commented 3 years ago

https://github.com/manlge/iotdb-client-go/actions/runs/437344648

manlge commented 3 years ago

@jixuan1989 @JackieTien97 PTAL

jixuan1989 commented 3 years ago

Hi, sorry for reply late.

Why adding a method GetValueAt ?

manlge commented 3 years ago

e.g.

func validate(tablet *client.Tablet) (err error) {
    temperatureColumn := 2
    for i := 0; i < tablet.GetRowCount(); i++ {
        if v, err := tablet.GetValueAt(temperatureColumn, i); err == nil {
            temperature := v.(float32)
            if temperature > 42.5 || temperature < 35.1 {
                return errors.New("The temperature must be in [35..42]")
            }
        }
    }
    return err
}