mirror of
https://github.com/mrusme/neonmodem.git
synced 2024-11-03 04:27:16 -05:00
22 lines
294 B
Go
22 lines
294 B
Go
package adapter
|
|
|
|
type Capabilities []Capability
|
|
|
|
type Capability struct {
|
|
ID string
|
|
Name string
|
|
}
|
|
|
|
func (caps *Capabilities) IsCapableOf(capability string) bool {
|
|
var can bool = false
|
|
|
|
for _, capb := range *caps {
|
|
if capb.ID == capability {
|
|
can = true
|
|
break
|
|
}
|
|
}
|
|
|
|
return can
|
|
}
|