44 * the "for the sake of extensibility" comment in messages.ts.
55 */
66// eslint-disable-next-line @typescript-eslint/no-namespace
7- export namespace ColumnKindCode {
7+ export namespace BqrsColumnKindCode {
88 export const FLOAT = "f" ;
99 export const INTEGER = "i" ;
1010 export const STRING = "s" ;
@@ -13,70 +13,70 @@ export namespace ColumnKindCode {
1313 export const ENTITY = "e" ;
1414}
1515
16- export type ColumnKind =
17- | typeof ColumnKindCode . FLOAT
18- | typeof ColumnKindCode . INTEGER
19- | typeof ColumnKindCode . STRING
20- | typeof ColumnKindCode . BOOLEAN
21- | typeof ColumnKindCode . DATE
22- | typeof ColumnKindCode . ENTITY ;
16+ export type BqrsColumnKind =
17+ | typeof BqrsColumnKindCode . FLOAT
18+ | typeof BqrsColumnKindCode . INTEGER
19+ | typeof BqrsColumnKindCode . STRING
20+ | typeof BqrsColumnKindCode . BOOLEAN
21+ | typeof BqrsColumnKindCode . DATE
22+ | typeof BqrsColumnKindCode . ENTITY ;
2323
24- interface Column {
24+ interface BqrsSchemaColumn {
2525 name ?: string ;
26- kind : ColumnKind ;
26+ kind : BqrsColumnKind ;
2727}
2828
29- export interface ResultSetSchema {
29+ export interface BqrsResultSetSchema {
3030 name : string ;
3131 rows : number ;
32- columns : Column [ ] ;
33- pagination ?: PaginationInfo ;
32+ columns : BqrsSchemaColumn [ ] ;
33+ pagination ?: BqrsPaginationInfo ;
3434}
3535
36- interface PaginationInfo {
36+ interface BqrsPaginationInfo {
3737 "step-size" : number ;
3838 offsets : number [ ] ;
3939}
4040
41- export interface BQRSInfo {
42- "result-sets" : ResultSetSchema [ ] ;
41+ export interface BqrsInfo {
42+ "result-sets" : BqrsResultSetSchema [ ] ;
4343}
4444
4545export type BqrsId = number ;
4646
47- export interface EntityValue {
48- url ?: UrlValue ;
47+ export interface BqrsEntityValue {
48+ url ?: BqrsUrlValue ;
4949 label ?: string ;
5050 id ?: BqrsId ;
5151}
5252
53- export interface LineColumnLocation {
53+ export interface BqrsLineColumnLocation {
5454 uri : string ;
5555 startLine : number ;
5656 startColumn : number ;
5757 endLine : number ;
5858 endColumn : number ;
5959}
6060
61- export interface WholeFileLocation {
61+ export interface BqrsWholeFileLocation {
6262 uri : string ;
6363 startLine : never ;
6464 startColumn : never ;
6565 endLine : never ;
6666 endColumn : never ;
6767}
6868
69- type ResolvableLocationValue = WholeFileLocation | LineColumnLocation ;
69+ export type BqrsUrlValue =
70+ | BqrsWholeFileLocation
71+ | BqrsLineColumnLocation
72+ | string ;
7073
71- export type UrlValue = ResolvableLocationValue | string ;
72-
73- export type CellValue = EntityValue | number | string | boolean ;
74+ export type BqrsCellValue = BqrsEntityValue | number | string | boolean ;
7475
7576export type BqrsKind =
7677 | "String"
7778 | "Float"
7879 | "Integer"
79- | "String"
8080 | "Boolean"
8181 | "Date"
8282 | "Entity" ;
@@ -85,8 +85,9 @@ interface BqrsColumn {
8585 name ?: string ;
8686 kind : BqrsKind ;
8787}
88+
8889export interface DecodedBqrsChunk {
89- tuples : CellValue [ ] [ ] ;
90+ tuples : BqrsCellValue [ ] [ ] ;
9091 next ?: number ;
9192 columns : BqrsColumn [ ] ;
9293}
0 commit comments