Skip to content

Commit

Permalink
Edited README.md via GitHub
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeminutillo committed May 9, 2011
1 parent 02baf63 commit e43e097
Showing 1 changed file with 16 additions and 11 deletions.
27 changes: 16 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,23 @@ conventional
============

Conventional is a library for adding type-based conventions to you projects. The simplest way to add the library to your project is with Nuget:

Install-Package Conventional

Once installed you need to define some Conventions and then Configure the conventions engine:
class Services : IConvention {
public bool Matches(Type t) {
return t.Namespace.Contains("Services");
}
}

//... during app start up
Conventions.Configure(c => {
c.Install<Services>(t => IoC.RegisterService(t));
class Services : IConvention {
public bool Matches(Type t) {
return t.Namespace.Contains("Services");
}
}

//... during app start up
Conventions.Configure(c => {
c.Install<Services>(t => IoC.RegisterService(t));

c.Scan("MyProject.Services").For<Services>();
c.ScanThisAssembly().For<Services>();
});

c.Scan("MyProject.Services").For<Services>();
c.ScanThisAssembly().For<Services>();
});
See https://github.com/wolfbyte/conventional/wiki for more info

0 comments on commit e43e097

Please sign in to comment.