Skip to content

Commit 4cffc3c

Browse files
committed
implement composability suggestion with regards to interface design
1 parent 4b08c01 commit 4cffc3c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

propagation/propagation.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,12 @@ type TextMapCarrier interface {
3232
// MultiTextMapCarrier is a TextMapCarrier that can return multiple values for a single key.
3333
type MultiTextMapCarrier interface {
3434
TextMapCarrier
35+
MultiGetter
36+
}
37+
38+
// MultiGetter can return multiple values for a single key,
39+
// with contrast to TextMapCarrier.Get which returns a single value.
40+
type MultiGetter interface {
3541
// GetAll returns all values associated with the passed key.
3642
GetAll(key string) []string
3743
// DO NOT CHANGE: any modification will not be backwards compatible and

0 commit comments

Comments
 (0)