Skip to content
simonthorogood edited this page Dec 14, 2010 · 1 revision

Use ResourceSpace.Uses to define extra PipelineContributors, URI decorators, and Dependency Injection.

ResourceSpace.Uses.PipelineContributor()

Registers pipeline contributors. Use the titular form, where TPipelineContributor is a type which implements IPipelineContributor.

Example

ResourceSpace.Uses.PipelineContributor<StatisticsLoggerContributor>();

ResourceSpace.Uses.CustomDependency<TServiceType, TConcrete>()

Registers a custom dependency with the dependency injection engine. The TServiceType will then be available via constructor or setter injection to any OpenRasta object (handlers, pipeline contributors, URI decorators etc) that requests it.

Example

ResourceSpace.Uses.CustomDependency<IArticleRepository, ArticleRepository>()

ResourceSpace.Uses.UriDecorator

Registers a URI decorator with the resource space. TUriDecorator must implement IUriDecorator.

Example

ResourceSpace.Uses.UriDecorator<OpenRasta.Web.UriDecorators.ContentTypeExtensionUriDecorator>

Clone this wiki locally