1
-
2
1
export type DefaultErr = {
3
- log : string ,
4
- status : number ,
5
- message : string ,
2
+ log : string ;
3
+ status : number ;
4
+ message : string ;
6
5
} ;
7
6
8
7
export type Props = {
9
8
isActive : boolean ;
10
9
setIsActive : ( active : boolean ) => void ;
11
10
} ;
12
11
13
- export interface dbCredentials {
14
- database_name : string | number | null ;
15
- username : string | number | null ;
16
- password : string | number | null ;
17
- hostname : string | number | null ;
18
- port : string | number | null ;
19
- database_link : string | number | null ;
12
+ export interface dbCredentials {
13
+ database_name : string | number | null ;
14
+ username : string | number | null ;
15
+ password : string | number | null ;
16
+ hostname : string | number | null ;
17
+ port : string | number | null ;
18
+ database_link : string | number | null ;
20
19
db_type : string ;
21
20
}
22
21
23
- export interface Data {
22
+ export interface Data {
24
23
edges : RowsOfData [ ] ;
25
24
table : [ string , RowsOfData [ ] ] ;
26
25
}
27
26
28
27
export interface RefObj {
29
- IsDestination : boolean ,
30
- PrimaryKeyName : string ,
31
- PrimaryKeyTableName : string ,
32
- ReferencesPropertyName : string ,
33
- ReferencesTableName : string ,
34
- constraintName : string ,
35
- }
28
+ IsDestination : boolean ;
29
+ PrimaryKeyName : string ;
30
+ PrimaryKeyTableName : string ;
31
+ ReferencesPropertyName : string ;
32
+ ReferencesTableName : string ;
33
+ constraintName : string ;
34
+ }
36
35
37
36
export interface TableColumn {
38
37
Field ?: string ;
@@ -54,42 +53,42 @@ export interface TableColumn {
54
53
update_rule ?: string ;
55
54
delete_rule ?: string ;
56
55
default_type ?: string ;
57
- } ;
56
+ }
58
57
59
58
export interface OracleSchema {
60
- TABLE_NAME : string ,
61
- COLUMN_NAME : string ,
62
- DATA_TYPE : string ,
63
- DATA_DEFAULT : string | null ,
64
- CHARACTER_MAXIMUM_LENGTH : string | number | null ,
65
- IS_NULLABLE : string ,
66
- COLUMN_ID : number ,
67
- CONSTRAINT_NAME : string ,
68
- CONSTRAINT_TYPE : string ,
69
- R_TABLE_OWNER : string | null ,
70
- R_TABLE_NAME : string | null ,
71
- R_COLUMN_NAME : string | null
59
+ TABLE_NAME : string ;
60
+ COLUMN_NAME : string ;
61
+ DATA_TYPE : string ;
62
+ DATA_DEFAULT : string | null ;
63
+ CHARACTER_MAXIMUM_LENGTH : string | number | null ;
64
+ IS_NULLABLE : string ;
65
+ COLUMN_ID : number ;
66
+ CONSTRAINT_NAME : string ;
67
+ CONSTRAINT_TYPE : string ;
68
+ R_TABLE_OWNER : string | null ;
69
+ R_TABLE_NAME : string | null ;
70
+ R_COLUMN_NAME : string | null ;
72
71
}
73
72
74
73
export interface TableColumns {
75
74
[ columnName : string ] : TableColumn ;
76
- } ;
75
+ }
77
76
78
77
export interface TableSchema {
79
78
[ tableName : string ] : TableColumns ;
80
- } ;
79
+ }
81
80
82
81
export interface ReferenceType {
83
82
[ index : number ] : {
84
- IsDestination : boolean ,
85
- PrimaryKeyName : string ,
86
- PrimaryKeyTableName : string ,
87
- ReferencesPropertyName : string ,
88
- ReferencesTableName : string ,
89
- constraintName : string ,
90
- } ,
91
- length : number ,
92
- } ;
83
+ IsDestination : boolean ;
84
+ PrimaryKeyName : string ;
85
+ PrimaryKeyTableName : string ;
86
+ ReferencesPropertyName : string ;
87
+ ReferencesTableName : string ;
88
+ constraintName : string ;
89
+ } ;
90
+ length : number ;
91
+ }
93
92
94
93
export type Edge = {
95
94
id : string ;
@@ -99,6 +98,7 @@ export type Edge = {
99
98
targetHandle : string ;
100
99
animated : boolean ;
101
100
label : string ;
101
+ type : string ;
102
102
style : { strokeWidth : number ; stroke : string } ;
103
103
markerEnd : {
104
104
type : string ;
@@ -121,20 +121,21 @@ export interface DataNodeData {
121
121
edges : Edge [ ] ;
122
122
}
123
123
124
- export type TableTuple =
125
- [ TableKey : string ,
126
- ColumnData : { [ ColumnName : string ] : ColumnSchema } | RowsOfData [ ] | RowsOfData ] ;
127
-
128
- export interface dataSourceConnection {
129
- type : string ,
130
- host ?: string ,
131
- port ?: string | number ,
132
- username ?:string ,
133
- password ?: string ,
134
- database ?: string ,
135
- serviceName ?: string ,
136
- synchronize ?: boolean ,
137
- logging ?: boolean ,
124
+ export type TableTuple = [
125
+ TableKey : string ,
126
+ ColumnData : { [ ColumnName : string ] : ColumnSchema } | RowsOfData [ ] | RowsOfData
127
+ ] ;
128
+
129
+ export interface dataSourceConnection {
130
+ type : string ;
131
+ host ?: string ;
132
+ port ?: string | number ;
133
+ username ?: string ;
134
+ password ?: string ;
135
+ database ?: string ;
136
+ serviceName ?: string ;
137
+ synchronize ?: boolean ;
138
+ logging ?: boolean ;
138
139
}
139
140
140
141
// ---------------------------------------------------------------------
@@ -160,20 +161,20 @@ export type Reference = {
160
161
ReferencesTableName : string ;
161
162
IsDestination : boolean ;
162
163
constraintName : string ;
163
- }
164
+ } ;
164
165
} ;
165
166
166
167
// export type PrimaryKeyReference = {
167
168
// [tableName: string]: RowsOfData
168
169
// }
169
170
170
171
export type ForeignKeyData = {
171
- PrimaryKeyTableName : string ,
172
- PrimaryKeyColumnName : string ,
173
- ForeignKeyTableName : string ,
174
- ForeignKeyColumnName : string ,
175
- constraintName : string
176
- }
172
+ PrimaryKeyTableName : string ;
173
+ PrimaryKeyColumnName : string ;
174
+ ForeignKeyTableName : string ;
175
+ ForeignKeyColumnName : string ;
176
+ constraintName : string ;
177
+ } ;
177
178
178
179
export type InnerReference = {
179
180
PrimaryKeyName : string ;
@@ -182,9 +183,9 @@ export type InnerReference = {
182
183
ReferencesTableName : string ;
183
184
IsDestination : boolean ;
184
185
constraintName : string ;
185
- }
186
+ } ;
186
187
187
- export interface ColumnSchema {
188
+ export interface ColumnSchema {
188
189
Name : string ;
189
190
Value : string | null ;
190
191
TableName : string ;
@@ -193,25 +194,25 @@ export interface ColumnSchema{
193
194
IsForeignKey : boolean ;
194
195
field_name : string ;
195
196
data_type : SQLDataType ;
196
- additional_constraints : 'NULL' | 'NOT NULL' | 'PRIMARY' | 'UNIQUE' | '' ;
197
- } ;
197
+ additional_constraints : 'NULL' | 'NOT NULL' | 'PRIMARY' | 'UNIQUE' | '' ;
198
+ }
198
199
199
200
// these are for data tables ######################
200
201
export type RowsOfData = {
201
- [ key : string | number ] : string | number | boolean | null ,
202
+ [ key : string | number ] : string | number | boolean | null ;
202
203
} ;
203
204
204
205
export type DataStore = {
205
206
[ TableName : string ] : RowsOfData [ ] ;
206
- }
207
+ } ;
207
208
208
209
export type SchemaStore = {
209
210
[ TableName : string ] : {
210
211
[ ColumnName : string ] : ColumnSchema ;
211
212
} ;
212
213
} ;
213
214
214
- export type DataRowArray = Array < string | number | boolean >
215
+ export type DataRowArray = Array < string | number | boolean > ;
215
216
216
217
// export type DataState = {
217
218
// // DATA
@@ -220,8 +221,6 @@ export type DataRowArray = Array<string | number | boolean>
220
221
// history: DataStore[];
221
222
// historyCounter: number;
222
223
223
-
224
-
225
224
// // DATA SETTERS
226
225
// setDataStore: (dataInfo: DataStore) => void;
227
226
// setSystem: (system: DataStore) => void;
@@ -238,8 +237,7 @@ export type FlowState = {
238
237
} ;
239
238
240
239
export type ColumnDataForDataTable = {
241
- [ key : string | number ] : RowsOfData [ ] ,
242
-
240
+ [ key : string | number ] : RowsOfData [ ] ;
243
241
} ;
244
242
//######################
245
243
@@ -251,8 +249,8 @@ export interface SchemaObject {
251
249
[ key : string ] : Table ;
252
250
}
253
251
254
- export type SQLDataType =
255
- 'AUTO_INCREMENT'
252
+ export type SQLDataType =
253
+ | 'AUTO_INCREMENT'
256
254
| 'SERIAL'
257
255
| 'SMALLSERIAL'
258
256
| 'BIGSERIAL'
@@ -322,15 +320,15 @@ export type SQLDataType =
322
320
| 'CUBE'
323
321
| 'LTREE' ;
324
322
325
- export type PostgresDataTypes =
326
- 'bigint'
323
+ export type PostgresDataTypes =
324
+ | 'bigint'
327
325
| 'bigserial'
328
326
| 'bit'
329
327
| 'bit varying'
330
328
| 'boolean'
331
329
| 'bool'
332
- | 'box'
333
- | 'bytea'
330
+ | 'box'
331
+ | 'bytea'
334
332
| 'char'
335
333
| 'character'
336
334
| 'character varying'
0 commit comments