You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I propose we allow iConn constructor to accept a single object for configuration
This would serve as the recommended v1.0.0 of creating a new iConn object.
The current signature allowing of (database, user, password [,restOptions]) will still be compatible.
Benefits:
We can add an option transport to allow new transports to be specified see Add New Transports #26
We can add an option returnError to allow for errors for errors to be set within the user passed call back to iConn.run function see Callback function should receive error parameter #2. By default this would be set to true when using single object signature.
We can added an option returnXml to allow for raw xml output when set to true and output from xmlToJson when set to false. By default this would be set to false so that users don't have to call xmlToJson after run()
We can addnew options as needed in the future.
We do not have to care about positional parameters.
The text was updated successfully, but these errors were encountered:
abmusse
changed the title
Allow the iConn() constructor to accept a single object for configuration.
Allow the ~~iConn()~~ constructor to accept a single object for configuration.
Mar 5, 2019
abmusse
changed the title
Allow the ~~iConn()~~ constructor to accept a single object for configuration.
Allow the ~iConn()~ constructor to accept a single object for configuration.
Mar 5, 2019
abmusse
changed the title
Allow the ~iConn()~ constructor to accept a single object for configuration.
Allow the ~~iConn()~~ constructor to accept a single object for configuration.
Mar 5, 2019
abmusse
changed the title
Allow the ~~iConn()~~ constructor to accept a single object for configuration.
Allow the Connection constructor to accept a single object for configuration.
Mar 5, 2019
Allow Connection.js Constuctor to accept a single object see #25
Allow Connection.run() function to return error as first param of callback see #2
Establish one code path in Connection Constructor
- when pre v1.0 signature is used create an options object
- add properties to this options object
- this mimics the current v1.0 way of passing a signle object
- that way constructor follows on code path
Options object contain sub object transportOptions
- This contains properties such as databse, username, etc
- This sub object is passed to the transport
Rename variables away from I_* prefix
Rename getConnection() -> getTransportOptions()
Rename cmd -> commandList
Moved verbose to be a property of Connection
- verbose is added to transportOptions during run()
- this is because verbose can be adjusted with debug()
- add print of xmlOutput also when in verbose mode
I propose we allow iConn constructor to accept a single object for configuration
This would serve as the recommended v1.0.0 of creating a new iConn object.
The current signature allowing of
(database, user, password [,restOptions])
will still be compatible.Benefits:
We can add an option
transport
to allow new transports to be specified see Add New Transports #26We can add an option
returnError
to allow for errors for errors to be set within the user passed call back toiConn.run
function see Callback function should receive error parameter #2. By default this would be set to true when using single object signature.We can added an option
returnXml
to allow for raw xml output when set to true and output from xmlToJson when set to false. By default this would be set to false so that users don't have to call xmlToJson afterrun()
We can addnew options as needed in the future.
We do not have to care about positional parameters.
The text was updated successfully, but these errors were encountered: