Skip to content

Commit d218b1d

Browse files
committed
Moving ALL deprecated functions into Deprecated.js. They import the new classes and use them. Can be easily removed later. Also removed CommandGenerator class and just have 3 const functions exported now
1 parent a73d031 commit d218b1d

File tree

7 files changed

+598
-584
lines changed

7 files changed

+598
-584
lines changed

lib/Connection.js

-55
Original file line numberDiff line numberDiff line change
@@ -176,59 +176,4 @@ class Connection {
176176
}
177177
}
178178

179-
// Deprecated
180-
class iConn {
181-
constructor(db, user, pwd, option) {
182-
this.connection = new Connection(db, user, pwd, option);
183-
}
184-
185-
/**
186-
* @description override the default timeout value for sync mode.
187-
* @param {number} seconds
188-
*/
189-
setTimeout(seconds) {
190-
this.connection.setTimeout(seconds);
191-
}
192-
193-
/**
194-
* @description
195-
* enables or disables the verbose mode for debugging
196-
* returns the current state of debug flag
197-
* @param {boolean} [flag]
198-
* @returns {boolean} the current state of the debug flag
199-
*/
200-
debug(flag) {
201-
return this.connection.debug(flag);
202-
}
203-
204-
205-
/**
206-
* @description returns conn property from iConn object.
207-
* @returns {object} the conn property from iConn object.
208-
*/
209-
getConnection() {
210-
return this.connection.getConnection();
211-
}
212-
213-
/**
214-
* @description adds XML request to command list
215-
* @param {string | object} xml
216-
*/
217-
add(xml) {
218-
this.connection.add(xml);
219-
}
220-
221-
/**
222-
* @description
223-
* Invokes transport with XML input from command list
224-
* Calls user provided callback with the XML output
225-
* @param {fuction} callback
226-
* @param {boolean} sync
227-
*/
228-
run(callback) {
229-
this.connection.run(callback);
230-
}
231-
}
232-
233179
module.exports.Connection = Connection;
234-
module.exports.iConn = iConn;

0 commit comments

Comments
 (0)