Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » DTP » creating an IConnectionProfile using ConnectionProfileFactory.createConnection
creating an IConnectionProfile using ConnectionProfileFactory.createConnection [message #597604] Tue, 06 July 2010 06:15 Go to next message
shikhar is currently offline shikhar
Messages: 4
Registered: July 2010
Junior Member
Hello Developers,

I was wondering if I could get some help regarding the createConnection function in the ConnectionProfileFactory class.
An example of a Hard Coded call to this function would be
IConnectionProfile connectionProfile = connectionProfileFactory.createConnection(name, "org.eclipse.datatools.enablement.oracle.driverCategory", "org.eclipse.datatools.enablement.oracle.10.driverCategory", "org.eclipse.datatools.enablement.oracle.10.driverTemplate", properties);

Now I don't want this to be hard coded. What if I have some information say DB2 version 9 passed to it. Can I find the values of constants org.eclipse.datatools.enablement... for this database for all the parameters?
If yes, how can I do so?

please do reply if the context is not clear. I will elaborate more.


thanks and regards
Shikhar
Re: creating an IConnectionProfile using ConnectionProfileFactory.createConnection [message #597611 is a reply to message #597604] Wed, 07 July 2010 16:36 Go to previous message
Brian Fitzpatrick is currently offline Brian Fitzpatrick
Messages: 495
Registered: July 2009
Senior Member
Hi Shikhar...

I need a little more information. :)

So are you trying to get from the "vendor" and "version" strings to a
connection profile factory? Or to a connection profile instance?

And what do you expect your vendor and version strings to look like?

--Fitz

shikhar wrote:
> Hello Developers,
> I was wondering if I could get some help regarding the createConnection
> function in the ConnectionProfileFactory class. An example of a Hard
> Coded call to this function would be IConnectionProfile
> connectionProfile = connectionProfileFactory.createConnection(name,
> "org.eclipse.datatools.enablement.oracle.driverCategory",
> "org.eclipse.datatools.enablement.oracle.10.driverCategory",
> "org.eclipse.datatools.enablement.oracle.10.driverTemplate", properties);
>
> Now I don't want this to be hard coded. What if I have some information
> say DB2 version 9 passed to it. Can I find the values of constants
> org.eclipse.datatools.enablement... for this database for all the
> parameters? If yes, how can I do so?
>
> please do reply if the context is not clear. I will elaborate more.
>
> thanks and regards Shikhar
>
>
>
Previous Topic:How to provide my own Result Set Viewer
Next Topic:connection with sql server 2000 using DTP
Goto Forum:
  


Current Time: Wed Aug 20 03:01:45 EDT 2014

Powered by FUDForum. Page generated in 0.01575 seconds