()
| 1627 | } |
| 1628 | |
| 1629 | func (ann annotated) String() string { |
| 1630 | var sb strings.Builder |
| 1631 | sb.WriteString("fx.Annotate(") |
| 1632 | sb.WriteString(fxreflect.FuncName(ann.Target)) |
| 1633 | if tags := ann.ParamTags; len(tags) > 0 { |
| 1634 | fmt.Fprintf(&sb, ", fx.ParamTags(%q)", tags) |
| 1635 | } |
| 1636 | if tags := ann.ResultTags; len(tags) > 0 { |
| 1637 | fmt.Fprintf(&sb, ", fx.ResultTags(%q)", tags) |
| 1638 | } |
| 1639 | if as := ann.As; len(as) > 0 { |
| 1640 | fmt.Fprintf(&sb, ", fx.As(%v)", as) |
| 1641 | } |
| 1642 | if from := ann.From; len(from) > 0 { |
| 1643 | fmt.Fprintf(&sb, ", fx.From(%v)", from) |
| 1644 | } |
| 1645 | return sb.String() |
| 1646 | } |
| 1647 | |
| 1648 | // Build builds and returns a constructor based on fx.In/fx.Out params and |
| 1649 | // results wrapping the original constructor passed to fx.Annotate. |
nothing calls this directly
no test coverage detected