signerInfoWrite writes the context.
(fmtCtx formatter.Context, signerInfoList []signerInfo)
| 79 | |
| 80 | // signerInfoWrite writes the context. |
| 81 | func signerInfoWrite(fmtCtx formatter.Context, signerInfoList []signerInfo) error { |
| 82 | signerInfoCtx := &signerInfoContext{ |
| 83 | HeaderContext: formatter.HeaderContext{ |
| 84 | Header: formatter.SubHeaderContext{ |
| 85 | "Signer": signerNameHeader, |
| 86 | "Keys": keysHeader, |
| 87 | }, |
| 88 | }, |
| 89 | } |
| 90 | return fmtCtx.Write(signerInfoCtx, func(format func(subContext formatter.SubContext) error) error { |
| 91 | for _, info := range signerInfoList { |
| 92 | if err := format(&signerInfoContext{ |
| 93 | trunc: fmtCtx.Trunc, |
| 94 | s: info, |
| 95 | }); err != nil { |
| 96 | return err |
| 97 | } |
| 98 | } |
| 99 | return nil |
| 100 | }) |
| 101 | } |
| 102 | |
| 103 | type signerInfoContext struct { |
| 104 | formatter.HeaderContext |
searching dependent graphs…