title: how AddSingleton<TService, TImplementation>() works
body: <p>I'm new to dependency injection,I've come across this line code in an asp.net core project</p>
  <pre><code>services.AddSingleton&lt;TService, TImplementation&gt;()
  </code></pre>
  <p>And I'm confused 'TService, TImplementation' is used to tell the compiler that the generic type that will be returned or/and passed to the method I'm i right ? but the method in question does not take any parameters what I'm missing ? should not the method look something like this :</p>
  <pre><code>services.AddSingleton&lt;TService, TImplementation&gt;(TService a,TImplementation b)
  </code></pre>
  <p>this question is already asked <a href="https://stackoverflow.com/questions/62078023/addsingleton-vs-addsingleton">AddSingleton&lt;&gt;() vs AddSingleton()</a> but the answers are not clear to me , can someone please explain how this work ?</p>