...
1 package jwx
2
3 import "github.com/lestrrat-go/option"
4
5 type identUseNumber struct{}
6
7 type Option = option.Interface
8
9 type JSONOption interface {
10 Option
11 isJSONOption()
12 }
13
14 type jsonOption struct {
15 Option
16 }
17
18 func (o *jsonOption) isJSONOption() {}
19
20 func newJSONOption(n interface{}, v interface{}) JSONOption {
21 return &jsonOption{option.New(n, v)}
22 }
23
24
25
26
27
28 func WithUseNumber(b bool) JSONOption {
29 return newJSONOption(identUseNumber{}, b)
30 }
31
View as plain text