@databricks/sql
Version:
Driver for connection to Databricks SQL via Thrift API.
1,962 lines (1,882 loc) • 124 kB
JavaScript
//
// Autogenerated by Thrift Compiler (0.19.0)
//
// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
//
"use strict";
var thrift = require('thrift');
var Thrift = thrift.Thrift;
var Q = thrift.Q;
var Int64 = require('node-int64');
var ttypes = require('./TCLIService_types');
//HELPER FUNCTIONS AND STRUCTURES
var TCLIService_OpenSession_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TOpenSessionReq(args.req);
}
}
};
TCLIService_OpenSession_args.prototype = {};
TCLIService_OpenSession_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TOpenSessionReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_OpenSession_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_OpenSession_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_OpenSession_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TOpenSessionResp(args.success);
}
}
};
TCLIService_OpenSession_result.prototype = {};
TCLIService_OpenSession_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TOpenSessionResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_OpenSession_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_OpenSession_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_CloseSession_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TCloseSessionReq(args.req);
}
}
};
TCLIService_CloseSession_args.prototype = {};
TCLIService_CloseSession_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TCloseSessionReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_CloseSession_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_CloseSession_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_CloseSession_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TCloseSessionResp(args.success);
}
}
};
TCLIService_CloseSession_result.prototype = {};
TCLIService_CloseSession_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TCloseSessionResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_CloseSession_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_CloseSession_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetInfo_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetInfoReq(args.req);
}
}
};
TCLIService_GetInfo_args.prototype = {};
TCLIService_GetInfo_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetInfoReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetInfo_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetInfo_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetInfo_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetInfoResp(args.success);
}
}
};
TCLIService_GetInfo_result.prototype = {};
TCLIService_GetInfo_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetInfoResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetInfo_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetInfo_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_ExecuteStatement_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TExecuteStatementReq(args.req);
}
}
};
TCLIService_ExecuteStatement_args.prototype = {};
TCLIService_ExecuteStatement_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TExecuteStatementReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_ExecuteStatement_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_ExecuteStatement_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_ExecuteStatement_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TExecuteStatementResp(args.success);
}
}
};
TCLIService_ExecuteStatement_result.prototype = {};
TCLIService_ExecuteStatement_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TExecuteStatementResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_ExecuteStatement_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_ExecuteStatement_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetTypeInfo_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetTypeInfoReq(args.req);
}
}
};
TCLIService_GetTypeInfo_args.prototype = {};
TCLIService_GetTypeInfo_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetTypeInfoReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetTypeInfo_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetTypeInfo_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetTypeInfo_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetTypeInfoResp(args.success);
}
}
};
TCLIService_GetTypeInfo_result.prototype = {};
TCLIService_GetTypeInfo_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetTypeInfoResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetTypeInfo_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetTypeInfo_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetCatalogs_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetCatalogsReq(args.req);
}
}
};
TCLIService_GetCatalogs_args.prototype = {};
TCLIService_GetCatalogs_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetCatalogsReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetCatalogs_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetCatalogs_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetCatalogs_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetCatalogsResp(args.success);
}
}
};
TCLIService_GetCatalogs_result.prototype = {};
TCLIService_GetCatalogs_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetCatalogsResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetCatalogs_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetCatalogs_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetSchemas_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetSchemasReq(args.req);
}
}
};
TCLIService_GetSchemas_args.prototype = {};
TCLIService_GetSchemas_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetSchemasReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetSchemas_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetSchemas_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetSchemas_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetSchemasResp(args.success);
}
}
};
TCLIService_GetSchemas_result.prototype = {};
TCLIService_GetSchemas_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetSchemasResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetSchemas_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetSchemas_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetTables_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetTablesReq(args.req);
}
}
};
TCLIService_GetTables_args.prototype = {};
TCLIService_GetTables_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetTablesReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetTables_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetTables_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetTables_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetTablesResp(args.success);
}
}
};
TCLIService_GetTables_result.prototype = {};
TCLIService_GetTables_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetTablesResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetTables_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetTables_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetTableTypes_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetTableTypesReq(args.req);
}
}
};
TCLIService_GetTableTypes_args.prototype = {};
TCLIService_GetTableTypes_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetTableTypesReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetTableTypes_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetTableTypes_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetTableTypes_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetTableTypesResp(args.success);
}
}
};
TCLIService_GetTableTypes_result.prototype = {};
TCLIService_GetTableTypes_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetTableTypesResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetTableTypes_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetTableTypes_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetColumns_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetColumnsReq(args.req);
}
}
};
TCLIService_GetColumns_args.prototype = {};
TCLIService_GetColumns_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetColumnsReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetColumns_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetColumns_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetColumns_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetColumnsResp(args.success);
}
}
};
TCLIService_GetColumns_result.prototype = {};
TCLIService_GetColumns_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetColumnsResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetColumns_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetColumns_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetFunctions_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetFunctionsReq(args.req);
}
}
};
TCLIService_GetFunctions_args.prototype = {};
TCLIService_GetFunctions_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetFunctionsReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetFunctions_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetFunctions_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetFunctions_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetFunctionsResp(args.success);
}
}
};
TCLIService_GetFunctions_result.prototype = {};
TCLIService_GetFunctions_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetFunctionsResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetFunctions_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetFunctions_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetPrimaryKeys_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetPrimaryKeysReq(args.req);
}
}
};
TCLIService_GetPrimaryKeys_args.prototype = {};
TCLIService_GetPrimaryKeys_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetPrimaryKeysReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetPrimaryKeys_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetPrimaryKeys_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetPrimaryKeys_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetPrimaryKeysResp(args.success);
}
}
};
TCLIService_GetPrimaryKeys_result.prototype = {};
TCLIService_GetPrimaryKeys_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetPrimaryKeysResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetPrimaryKeys_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetPrimaryKeys_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetCrossReference_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetCrossReferenceReq(args.req);
}
}
};
TCLIService_GetCrossReference_args.prototype = {};
TCLIService_GetCrossReference_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetCrossReferenceReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetCrossReference_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetCrossReference_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetCrossReference_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetCrossReferenceResp(args.success);
}
}
};
TCLIService_GetCrossReference_result.prototype = {};
TCLIService_GetCrossReference_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetCrossReferenceResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetCrossReference_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetCrossReference_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetOperationStatus_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetOperationStatusReq(args.req);
}
}
};
TCLIService_GetOperationStatus_args.prototype = {};
TCLIService_GetOperationStatus_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetOperationStatusReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetOperationStatus_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetOperationStatus_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetOperationStatus_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetOperationStatusResp(args.success);
}
}
};
TCLIService_GetOperationStatus_result.prototype = {};
TCLIService_GetOperationStatus_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetOperationStatusResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetOperationStatus_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetOperationStatus_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_CancelOperation_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TCancelOperationReq(args.req);
}
}
};
TCLIService_CancelOperation_args.prototype = {};
TCLIService_CancelOperation_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TCancelOperationReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_CancelOperation_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_CancelOperation_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_CancelOperation_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TCancelOperationResp(args.success);
}
}
};
TCLIService_CancelOperation_result.prototype = {};
TCLIService_CancelOperation_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TCancelOperationResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_CancelOperation_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_CancelOperation_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_CloseOperation_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TCloseOperationReq(args.req);
}
}
};
TCLIService_CloseOperation_args.prototype = {};
TCLIService_CloseOperation_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TCloseOperationReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_CloseOperation_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_CloseOperation_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_CloseOperation_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TCloseOperationResp(args.success);
}
}
};
TCLIService_CloseOperation_result.prototype = {};
TCLIService_CloseOperation_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TCloseOperationResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_CloseOperation_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_CloseOperation_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetResultSetMetadata_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetResultSetMetadataReq(args.req);
}
}
};
TCLIService_GetResultSetMetadata_args.prototype = {};
TCLIService_GetResultSetMetadata_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetResultSetMetadataReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetResultSetMetadata_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetResultSetMetadata_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetResultSetMetadata_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetResultSetMetadataResp(args.success);
}
}
};
TCLIService_GetResultSetMetadata_result.prototype = {};
TCLIService_GetResultSetMetadata_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetResultSetMetadataResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetResultSetMetadata_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetResultSetMetadata_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_FetchResults_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TFetchResultsReq(args.req);
}
}
};
TCLIService_FetchResults_args.prototype = {};
TCLIService_FetchResults_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TFetchResultsReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_FetchResults_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_FetchResults_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_FetchResults_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TFetchResultsResp(args.success);
}
}
};
TCLIService_FetchResults_result.prototype = {};
TCLIService_FetchResults_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TFetchResultsResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_FetchResults_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_FetchResults_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetDelegationToken_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TGetDelegationTokenReq(args.req);
}
}
};
TCLIService_GetDelegationToken_args.prototype = {};
TCLIService_GetDelegationToken_args.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 1:
if (ftype == Thrift.Type.STRUCT) {
this.req = new ttypes.TGetDelegationTokenReq();
this.req.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetDelegationToken_args.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetDelegationToken_args');
if (this.req !== null && this.req !== undefined) {
output.writeFieldBegin('req', Thrift.Type.STRUCT, 1);
this.req.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_GetDelegationToken_result = function(args) {
this.success = null;
if (args) {
if (args.success !== undefined && args.success !== null) {
this.success = new ttypes.TGetDelegationTokenResp(args.success);
}
}
};
TCLIService_GetDelegationToken_result.prototype = {};
TCLIService_GetDelegationToken_result.prototype.read = function(input) {
input.readStructBegin();
while (true) {
var ret = input.readFieldBegin();
var ftype = ret.ftype;
var fid = ret.fid;
if (ftype == Thrift.Type.STOP) {
break;
}
switch (fid) {
case 0:
if (ftype == Thrift.Type.STRUCT) {
this.success = new ttypes.TGetDelegationTokenResp();
this.success.read(input);
} else {
input.skip(ftype);
}
break;
case 0:
input.skip(ftype);
break;
default:
input.skip(ftype);
}
input.readFieldEnd();
}
input.readStructEnd();
return;
};
TCLIService_GetDelegationToken_result.prototype.write = function(output) {
output.writeStructBegin('TCLIService_GetDelegationToken_result');
if (this.success !== null && this.success !== undefined) {
output.writeFieldBegin('success', Thrift.Type.STRUCT, 0);
this.success.write(output);
output.writeFieldEnd();
}
output.writeFieldStop();
output.writeStructEnd();
return;
};
var TCLIService_CancelDelegationToken_args = function(args) {
this.req = null;
if (args) {
if (args.req !== undefined && args.req !== null) {
this.req = new ttypes.TCancelDelegationTokenReq(args.req);
}
}
}