Skip to content

Instantly share code, notes, and snippets.

@msbukkuri
Created January 6, 2012 08:17
Show Gist options
  • Save msbukkuri/1569648 to your computer and use it in GitHub Desktop.
Save msbukkuri/1569648 to your computer and use it in GitHub Desktop.
SimpleProjectManagementRegisttry.cs
public class SimpleProjectManagementRegistry : FubuRegistry
{
public SimpleProjectManagementRegistry()
{
// This line turns on the basic diagnostics and request tracing
IncludeDiagnostics(true);
Applies.
ToThisAssembly();
this.UseSpark();
ApplyHandlerConventions(typeof(FeaturesMarker));
// All public methods from concrete classes ending in "Controller"
// in this assembly are assumed to be action methods
Actions.IncludeClassesSuffixedWithController();
// Policies
Routes
.IgnoreControllerNamesEntirely()
.IgnoreMethodSuffix("Html")
.RootAtAssemblyNamespace();
// Match views to action methods by matching
// on model type, view name, and namespace
Views.TryToAttachWithDefaultConventions();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment