(tableRow, columnRows, indexRows, protocolVersion = 4)
| 2565 | }); |
| 2566 | |
| 2567 | function getControlConnectionForTable(tableRow, columnRows, indexRows, protocolVersion = 4) { |
| 2568 | return getControlConnectionForResponse(q => { |
| 2569 | if (q.indexOf('system.schema_columnfamilies') >= 0 || q.indexOf('system_schema.tables') >= 0) { |
| 2570 | return { rows: [tableRow] }; |
| 2571 | } |
| 2572 | if (q.indexOf('system_schema.indexes') >= 0) { |
| 2573 | return { rows: (indexRows || []) }; |
| 2574 | } |
| 2575 | |
| 2576 | return {rows: columnRows}; |
| 2577 | }, null, protocolVersion); |
| 2578 | } |
| 2579 | |
| 2580 | function getControlConnectionForRows(rows, protocolVersion = 4) { |
| 2581 | return getControlConnectionForResponse({ rows }, null, protocolVersion); |
no test coverage detected