|
64 | 64 | integer() |
|
65 | 65 | float() |
|
66 | 66 | boolean().
|
67 |
| --type tagged_prop() :: {uuid, binary()} | |
68 |
| - {utf8, binary()} | |
69 |
| - {binary, binary()} | |
70 |
| - {boolean, boolean()} | |
71 |
| - {double | float, float()} | |
72 |
| - {long | int | short | byte, integer()} | |
73 |
| - {ulong | uint | ushort | ubyte, non_neg_integer()} | |
74 |
| - {timestamp, non_neg_integer()} | |
75 |
| - {list, [tagged_prop()]} | |
76 |
| - {map, [{tagged_prop(), tagged_prop()}]} | |
77 |
| - null | |
78 |
| - undefined. |
| 67 | +-type tagged_value() :: {uuid, binary()} | |
| 68 | + {utf8, binary()} | |
| 69 | + {binary, binary()} | |
| 70 | + {boolean, boolean()} | |
| 71 | + {double | float, float()} | |
| 72 | + {long | int | short | byte, integer()} | |
| 73 | + {ulong | uint | ushort | ubyte, non_neg_integer()} | |
| 74 | + {timestamp, non_neg_integer()} | |
| 75 | + {list, [tagged_value()]} | |
| 76 | + {map, [{tagged_value(), tagged_value()}]} | |
| 77 | + null | |
| 78 | + undefined. |
79 | 79 |
|
80 | 80 | %% behaviour callbacks for protocol specific implementation
|
81 | 81 |
|
|
93 | 93 | %% retrieve and x- header from the protocol data
|
94 | 94 | %% the return value should be tagged with an AMQP 1.0 type
|
95 | 95 | -callback x_header(binary(), proto_state()) ->
|
96 |
| - tagged_prop(). |
| 96 | + tagged_value(). |
97 | 97 |
|
98 | 98 | %% retrieve a property field from the protocol data
|
99 | 99 | %% e.g. message_id, correlation_id
|
100 | 100 | -callback property(atom(), proto_state()) ->
|
101 |
| - tagged_prop(). |
| 101 | + tagged_value(). |
102 | 102 |
|
103 | 103 | %% return a map of header values used for message routing,
|
104 | 104 | %% optionally include x- headers and / or complex types (i.e. tables, arrays etc)
|
@@ -176,7 +176,7 @@ set_annotation(Key, Value, BasicMessage) ->
|
176 | 176 | mc_compat:set_annotation(Key, Value, BasicMessage).
|
177 | 177 |
|
178 | 178 | -spec x_header(Key :: binary(), state()) ->
|
179 |
| - tagged_prop(). |
| 179 | + tagged_value(). |
180 | 180 | x_header(Key, #?MODULE{protocol = Proto,
|
181 | 181 | annotations = Anns,
|
182 | 182 | data = Data}) ->
|
|
0 commit comments