Søren Rasmussen
07a23c1845
Some checks reported errors
continuous-integration/drone/push Build encountered an error
20 lines
349 B
Go
20 lines
349 B
Go
package ble
|
|
|
|
import "strings"
|
|
|
|
// Addr represents a network end point address.
|
|
// It's MAC address on Linux or Device UUID on OS X.
|
|
type Addr interface {
|
|
String() string
|
|
}
|
|
|
|
// NewAddr creates an Addr from string
|
|
func NewAddr(s string) Addr {
|
|
return addr(strings.ToLower(s))
|
|
}
|
|
|
|
type addr string
|
|
|
|
func (a addr) String() string {
|
|
return string(a)
|
|
}
|