// Status implements the api.Charger interface
Status implements the api.Charger interface
// Status implements the api . Charger interface
func (c *GoE) Status() (api.ChargeStatus, error) {
	resp, err := c.api.Status()
	if err != nil {
		return api.StatusNone, err
	}
	switch car := resp.Status(); car {
	case 1:
		return api.StatusA, nil
	case 2:
		return api.StatusC, nil
	case 3, 4:
		return api.StatusB, nil
	default:
		return api.StatusNone, fmt.Errorf("car unknown result: %d", car)
	}
}
func ( c * GoE ) Status ( ) ( api . ChargeStatus , error ) { resp , err := c . api . Status ( ) if err != nil { return api . StatusNone , err } switch car := resp . Status ( ) ; car { case 1 : return api . StatusA , nil case 2 : return api . StatusC , nil case 3 , 4 : return api . StatusB , nil default : return api . StatusNone , fmt . Errorf ( " " , car ) } }
Status implements the api.Charger interface
Status implements the api . Charger interface