‎2010 Dec 20 5:17 PM
In case anyone's interested in dependency injection in ABAP. Since we couldn't find any such library, we started to code it ourselves. First usable piece of code is available at: http://code.google.com/p/abap-di/
‎2010 Dec 20 8:01 PM
Thanks for Sharing. Looks interesting. I'll give a try and let you know how it goes.
Regards,
Naimesh Patel
‎2010 Dec 20 8:05 PM
Great,
I would be especially interested in the status of the download - whether it's installable and runnable. Any pitfalls or inconsistencies you'll find, please report them (on project wiki if possible). I'll then be able to correct the package.
Thanks
‎2010 Dec 20 9:08 PM
Hi Dominik,
Getting Couple of errors:
1. Syntax error while activating the test program. Parameter INSTANCE of the method GETINSTANCE of the interface YDIINJECTOR, must be TYPE REF TO OBJECT. Currently it is TYPE REF TO DATA.
2. Getting a runtime error while accessing the statements in method GETELEMENTS of class YDIELEMENTS.
LOOP AT modules INTO module.
binder->YDIBINDER~INSTALL( module ). " <<
ENDLOOP.
I also left the same message on the WIKI.
Regards,
Naimesh Patel
‎2010 Dec 21 8:11 PM
Dear Naimesh,
could I have a request to you?
Turns out that at the time when I was about to do the change you made me realize I should do, I lost access to the system I was implementing the library on. It will take me probably until after Christmas to find a development environment where I can further work on the library.
Because I don't want to leave the library in such a state as is right now I made a change to the NUGGET file directly.
Would it be a problem for you to download the file named 2010-12-21-NUGG_ABAP-DI.zip, install it on your system and verify whether it compiles?
If so, then could you also try to change the example that is on the site and to obtain the reference from injector use
log ?= injector->getinstance( ... )
Let me know
‎2010 Dec 21 10:37 PM
Not able to import the nugget as it ends up in the short dump - Null Object reference.
Regards,
Naimesh Patel
‎2010 Dec 21 10:47 PM
I am sorry but this is not really the correct forum for having such a discussion. I have moved this thread to the Coffee Corner.
Also, Dominik, you might want too consider creating a project in Code Exchange.
Cheers,
Neil.
‎2010 Dec 22 9:27 AM
Not able to import the nugget as it ends up in the short dump - Null Object reference.
Looks like I'm unable to make the change without SAP system. Thanks for your time.
‎2010 Dec 22 9:29 AM
I am sorry but this is not really the correct forum for having such a discussion. I have moved this thread to the Coffee Corner.
Totally agree. I was looking for a better fit in the first place, but I was not aware of the coffee corner. Thanks for reassigning.
Also, Dominik, you might want too consider creating a project in Code Exchange.
I was thinking about it in the first place, but what bothered me is the licensing. Code Exchange has a very strict policy about who owns (SAP) the code published there. That's why I went for code.google.com/p/abap-di with the project.
‎2010 Dec 21 1:15 AM
‎2010 Dec 28 3:35 PM
Here's stage #2. I've corrected the bugs that prevented you from downloading or using the package. I also updated the site User's Guide and Installation Guide to reflect the changes.
[Ready to give it a second try?|http://genijusz.com/?page_id=98]
‎2012 Jul 06 11:26 AM
New version 1.1 is released. This includes bugfixes and ability to bind providers. By introducing providers you no longer need a wrapper for objects that cannot be bind directly to the injector.
Give it a try !