0

Errai is a GWT library that ,among other things, implements CDI.

Usuallly CDI API is implemented by an IOC container, Can you help to understand how a GWT library can implement it on client side, i.e. on the browser ?

I'm really having hard time making sense of it.

GionJh
  • 2,742
  • 2
  • 29
  • 68
  • What exactly don't you understand? An IOC container can also be implemented in JavaScript. – dunni Jun 19 '16 at 20:32
  • maybe it's just this that I don't getis Errai a kind of Ioc container for gwt classes ? – GionJh Jun 19 '16 at 20:37
  • also on server side an IOC container makes extensive use of reflection, in js ther's no such a concept I think.. – GionJh Jun 19 '16 at 20:38

1 Answers1

0

Errai implements dependency injection by generating java code for it. Basically some code that provides manual reflection/instantiation.

If you have a project you can look at the java code in "target.generated\org\jboss\errai\ioc\client"

k5_
  • 5,450
  • 2
  • 19
  • 27