| 1374 | }); |
| 1375 | |
| 1376 | function getExecOptions(options) { |
| 1377 | const result = ExecutionOptions.empty(); |
| 1378 | let routingKey = options.routingKey; |
| 1379 | result.setRoutingKey = v => routingKey = v; |
| 1380 | result.getRoutingKey = () => routingKey; |
| 1381 | result.getHints = () => options.hints; |
| 1382 | result.getRoutingIndexes = () => options.routingIndexes; |
| 1383 | return result; |
| 1384 | } |
| 1385 | |
| 1386 | function newInstance(protocolVersion, clientOptions) { |
| 1387 | return new Encoder(protocolVersion || types.protocolVersion.maxSupported, clientOptions || {}); |