registerFactory<TResponse extends Object?, TRequest extends Request<TResponse>> method

void registerFactory<TResponse extends Object?, TRequest extends Request<TResponse>>(
  1. PipelineBehaviorFactory<TResponse, TRequest> factory
)

Registers the given factory.

This will create a factory based PipelineBehavior. This factory will be resolved into an actual PipelineBehavior at request time.

See PipelineBehavior.factory.

Implementation

void registerFactory<TResponse extends Object?,
    TRequest extends Request<TResponse>>(
  PipelineBehaviorFactory<TResponse, TRequest> factory,
) {
  register(PipelineBehavior.factory(factory));
}