Skip to content

Romanets/EPiInterceptors

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

EPiInterceptors

The goal of project is provide an easy way to extend EpiServer's content data object's interception pipeline. You can register you own interceptor using "EPiInterceptors.ContentDataInterceptonRegistry" instance provided by EpiSercervers ServiceLocator component, see the following example:

...
var registry = ServiceLocator.Current.GetInstance<ContentDataInterceptonRegistry>()
...

and use it for instance in the following way:

...
registry.InterceptWith<DefaultPorpertyValueInterceptor>();
...

Also you can use abstract class "EPiInterceptors.InterceptionRegistrationModule" to implement you own initializable module for interceptors registration purpose:

using EPiInterceptors;
using EPiServer.Framework;

namespace EPiServerMvcSite.Interception.Sample
{
    [InitializableModule]
    public class DefaultInterceptorRegisterModule : InterceptionRegistrationInitModuleBase
    {
        public override void RegisterContentDataInterceptors(ContentDataInterceptonRegistry registry)
        {
           registry.InterceptWith<DefaultPropertyValueInterceptor>();
        }
    }
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors