major API change

View: New views
3 Messages — Rating Filter:   Alert me  

major API change

by Alan Baljeu :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Our application's platform API has just been revamped to replace all instances of CString and wchar_t* with std::wstring, and all instances of CArray with std::vector.  They also refactored and eliminated some of their old classes replacing them with new ones.

This affects a dozen of their classes and hundreds of their methods, and thousands of our calls and constructions.  Oh and the compiler changed from VC2005 to VC2008.  We're currently attempting to retro-change their API just to get our app compiling (but not linking), and then somehow gradually upgrade their API and refactor our code to fit.

We will NOT be able to link the program until lots and lots of changes happen, (legacy app, Gordian knot) so I guess we just plug away.

We did however replicate one major chunk of their API in our own program so that we respecting this we only need to rewrite 400 methods to call their 400 methods, (but it's still 400 conversions we have to write). In other areas we're dealing with magic classes (proprietary memory management scheme) that I haven't figured out a good way to proxy (besides which proxying would involve a TON of rewrites)

Anybody have a good idea?

 Alan Baljeu


      __________________________________________________________________
Be smarter than spam. See how smart SpamGuard is at giving junk email the boot with the All-new Yahoo! Mail.  Click on Options in Mail and switch to New Mail today or register for free at http://mail.yahoo.ca


Re: major API change

by Alan Baljeu :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

It's C++ so we discovered we can re-add all the methods with the old signatures, just sneak them into the vendor's header files, and Bingo it compiles!
If we make them NULL methods, we can link it all up!

 Alan Baljeu

________________________________
From: Alan Baljeu <alanbaljeu@...>
To: testdrivendevelopment@...
Sent: Fri, October 23, 2009 11:51:40 AM
Subject: [TDD] major API change

 
Our application' s platform API has just been revamped to replace all instances of CString and wchar_t* with std::wstring, and all instances of CArray with std::vector.  They also refactored and eliminated some of their old classes replacing them with new ones.


      __________________________________________________________________
The new Internet Explorer® 8 - Faster, safer, easier.  Optimized for Yahoo!  Get it Now for Free! at http://downloads.yahoo.com/ca/internetexplorer/


RE: major API change

by Donaldson, John (GEO) :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Alan,

Well, I'm sure you asked yourself this, but could you provide a wrapper, so that your app keeps compiling and linking? Then slowly remove the wrapper.

John D.

-----Original Message-----
From: testdrivendevelopment@... [mailto:testdrivendevelopment@...] On Behalf Of Alan Baljeu
Sent: 23 October 2009 17:52
To: testdrivendevelopment@...
Subject: [TDD] major API change

Our application's platform API has just been revamped to replace all instances of CString and wchar_t* with std::wstring, and all instances of CArray with std::vector.  They also refactored and eliminated some of their old classes replacing them with new ones.

This affects a dozen of their classes and hundreds of their methods, and thousands of our calls and constructions.  Oh and the compiler changed from VC2005 to VC2008.  We're currently attempting to retro-change their API just to get our app compiling (but not linking), and then somehow gradually upgrade their API and refactor our code to fit.

We will NOT be able to link the program until lots and lots of changes happen, (legacy app, Gordian knot) so I guess we just plug away.

We did however replicate one major chunk of their API in our own program so that we respecting this we only need to rewrite 400 methods to call their 400 methods, (but it's still 400 conversions we have to write). In other areas we're dealing with magic classes (proprietary memory management scheme) that I haven't figured out a good way to proxy (besides which proxying would involve a TON of rewrites)

Anybody have a good idea?

 Alan Baljeu


      __________________________________________________________________
Be smarter than spam. See how smart SpamGuard is at giving junk email the boot with the All-new Yahoo! Mail.  Click on Options in Mail and switch to New Mail today or register for free at http://mail.yahoo.ca



------------------------------------

Yahoo! Groups Links