MCPcopy
hub / github.com/angular/angular-cli / newHandler

Function newHandler

packages/angular_devkit/architect/src/jobs/strategy.ts:50–58  ·  view source on GitHub ↗
(argument: A, context: JobHandlerContext<A, I, O>)

Source from the content-addressed store, hash-verified

48
49 return (handler, options) => {
50 const newHandler = (argument: A, context: JobHandlerContext<A, I, O>) => {
51 const previous = latest;
52 latest = concat(
53 previous.pipe(ignoreElements()),
54 new Observable<JobOutboundMessage<O>>((o) => handler(argument, context).subscribe(o)),
55 ).pipe(shareReplay(0));
56
57 return latest;
58 };
59
60 return Object.assign(newHandler, {
61 jobDescription: Object.assign({}, handler.jobDescription, options),

Callers

nothing calls this directly

Calls 6

isJsonObjectFunction · 0.90
subscribeMethod · 0.80
handlerFunction · 0.70
getMethod · 0.65
keysMethod · 0.45
setMethod · 0.45

Tested by

no test coverage detected