Description
The Create
method is a static method of the ResourceGenerator
class within the Sandbox.Resources
namespace. It is used to create a new instance of a ResourceGenerator
for a specific type T
using a specified generator name. This method is useful for initializing resource generators that can be used to produce resources based on the provided generator name.
Usage
To use the Create
method, call it statically from the ResourceGenerator
class, passing the desired generator name as a string parameter. The method will return a ResourceGenerator<T>
instance that can be used to generate resources of type T
.
Example
// Example of using the Create method
var myResourceGenerator = ResourceGenerator.Create<MyResourceType>("MyGeneratorName");
// Use the resource generator to generate resources
var resource = myResourceGenerator.Generate();