Desc sets a description on the last added call. If no calls exist yet, sets the top-level description.
(desc string)
| 84 | // Desc sets a description on the last added call. |
| 85 | // If no calls exist yet, sets the top-level description. |
| 86 | func (d *DryRunAPI) Desc(desc string) *DryRunAPI { |
| 87 | if n := len(d.calls); n > 0 { |
| 88 | d.calls[n-1].Desc = desc |
| 89 | } else { |
| 90 | d.desc = desc |
| 91 | } |
| 92 | return d |
| 93 | } |
| 94 | |
| 95 | // Set adds an extra context field. Values are also used to resolve :key placeholders in URLs. |
| 96 | func (d *DryRunAPI) Set(key string, value interface{}) *DryRunAPI { |
no outgoing calls