Skip to content

Instantly share code, notes, and snippets.

@scionwest
Created January 4, 2015 04:16
Show Gist options
  • Save scionwest/2d442cf9b2fa7b283bdd to your computer and use it in GitHub Desktop.
Save scionwest/2d442cf9b2fa7b283bdd to your computer and use it in GitHub Desktop.
private static void RegisterContainerTypes()
{
var builder = new ContainerBuilder();
builder.RegisterType<LoggingService>().As<ILoggingService>();
builder.RegisterType<FileStorageService>().As<IFileStorageService>();
// Engine runtime types
builder.RegisterType<DefaultGame>().As<DefaultGame>();
builder.RegisterType<WorldService>().As<IWorldService>();
// Flat File data store types
builder.RegisterType<WorldRepository>().As<IWorldRepository>();
builder.RegisterType<TimeOfDayStateRepository>().As<ITimeOfDayStateRepository>();
this.container = builder.Build();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment