Skip to main content

Questions tagged [inversion-of-control]

Inversion of control (IoC) is an abstract principle describing an aspect of some software architecture designs in which the flow of control of a system is inverted in comparison to procedural programming.

-1 votes
7 answers
731 views

Consider a class that follows the obfuscated function call anti-pattern. I've also seen these called "stupid classes". The definition of such a class is that it only has one public method ...
J. Mini's user avatar
  • 1,015
1 vote
2 answers
222 views

With interface injection (wikpedia) we have a method to set the dependency on the client as part of an interfase. public interface ServiceSetter { public void setService(Service service); } Why ...
Nishant Chauhan's user avatar
2 votes
2 answers
334 views

I‘m working on making a legacy code base more testable and made good progress with (constructor)-injecting dependencies to classes. I noticed something in all classes that access the file system: they ...
Der_Reparator's user avatar
0 votes
2 answers
534 views

I am developing an application with ASP.NET Core with the ability to dynamically add new libraries that implement the necessary functions. They can be included at the start. I have already written ...
Ramir Gimaltdinov's user avatar
0 votes
6 answers
1k views

Okay, first of all I understand the concept of IoC container! It's used to implement automatic dependency injection so you won't have to manually inject dependencies to class. It can automatically ...
Jhe's user avatar
  • 17
-3 votes
2 answers
572 views

First, let me explain what I mean by inversion of control and tell, don't ask in this context. I have 4 classes MailController, UserData, Subscription and MailService. MailController is a consumer of ...
I Want Answers's user avatar
0 votes
2 answers
195 views

I have been reading about inversion of control and dependency injection and I was wondering the following. Is there a good way to tell when it is okay to initialise an object inside a method body of a ...
Andreas Andreou's user avatar
1 vote
1 answer
140 views

When using IoC in a code base, should one always stick strictly to the pattern without exception? That means there should be no "new" in any constructor, when the newed object has ...
TomatenSalat's user avatar

15 30 50 per page
1
2 3 4 5
10