typeioc

Home > typeioc > IInterceptor

IInterceptor interface

Represents interceptor specification interface

Signature:

export interface IInterceptor 

Methods

Method Description
intercept(subject, substitutes) Create a subject with members substituted by given parameters. For the instances of an object - interceptInstance method is used, for prototypical/constructible functions - interceptPrototype is used
interceptInstance(subject, substitutes) Creates intercepted instance representative
interceptPrototype(subject, substitutes) Creates intercepted prototype representative
withSubstitute(substitute) Represents an entry point in fluent cascading API substitutes specification

Remarks

Interceptors are used to intercept calls to methods/getters/setters/fields of provided component