(w io.Writer, svc interface{}, level int)
| 459 | } |
| 460 | |
| 461 | func printService(w io.Writer, svc interface{}, level int) { |
| 462 | type errorer interface{ Error() error } |
| 463 | |
| 464 | t := "-" |
| 465 | if _, ok := svc.(supervisor); ok { |
| 466 | t = "+" |
| 467 | } |
| 468 | fmt.Fprintln(w, strings.Repeat(" ", level), t, svc) |
| 469 | if es, ok := svc.(errorer); ok { |
| 470 | if err := es.Error(); err != nil { |
| 471 | fmt.Fprintln(w, strings.Repeat(" ", level), " ->", err) |
| 472 | } |
| 473 | } |
| 474 | } |
| 475 | |
| 476 | type lateAddressLister struct { |
| 477 | discover.AddressLister |
no test coverage detected