delphi - Is it possible to register the same class / interface multiple times in Spring4D? -


i'm playing around spring4d framework , think it's pretty cool. i'm trying achieve following

  globalcontainer.registercomponent<tperson>.implements<iperson>('normal');   globalcontainer.registercomponent<tperson>.implements<iperson>('testdata').delegateto(     function: tperson     begin       result := tperson.create;       result.setfirstname('bob');       result.setsurname('smith');     end   ); 

with tperson/iperson having obvious definitions. regardless if try

  person := servicelocator.getservice<iperson>('normal'); 

or

  person := servicelocator.getservice<iperson>('testdata'); 

i bob, possible or doing wrong?

this fixed in latest version of spring4d


Comments

Popular posts from this blog

java - How to Configure JAXRS and Spring With Annotations -

visual studio - TFS will not accept changes I've made to a Java project -

php - Create image in codeigniter on the fly -