title: How can a templated "ResourceCache" load/create resources of type T, if they require different creation parameters/methods?
body: <p>I just dont know how to do it..</p>
  
  <p>Basically, if each template specialization type (T) have different parameters for its initialization, how can a generalized ResourceCache load/create a resource?</p>
  
  <pre><code>template&lt; class T&gt;
  class ResourceCache{
  
    T* cache[100];
  
    T* LoadResource(different parameters for different  T  ){//used in a cache miss..
  
            Create( different parameters for different  T );
  
    }
  }
  </code></pre>
  
  <p>If I use abstraction for, i.e., a IResourceParams class, my ResourceCache will not be able to use its own known type resource data without using polymorphism, its kinda stupid, since at runtime he knows what the type is, id be tottaly doing shit at runtime in prol of a compile time facility...I guess..</p>
  
  <p>On my current try I created a templated IResourceDesc  that have a virtual T* Create() method, so you need to derive for add data and specialize the Create method, but it sucks, because I cant have a collection of IResourceDesc in the ResourceCache class ( for  comparing current loaded ones, acquiring cached resources by desc, etc)...</p>