Adaptable data source connection strings
摘要:
Various embodiments of the invention provide methods, systems, and computer-program products for converting a connection string configured to use a first API to connect to a data source of a data source type to using a second, different API to connect to the data source. The data source type is identified as being associated with the string and the string is parsed and stored in a key-value dictionary. An object is instantiated for a subclass designed for the data source type. This subclass inherits from a base class that includes an abstract version of a method defined for the second API and the subclass includes a non-abstract version of this method. A string is generated by calling the method associated with the object, causing the non-abstract version to be executed, which uses the dictionary to generate the string configured to use the second API to connect to the data source.
信息查询
0/0