Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
}
onModuleInit() {
const scanner = new core_2.Scanner(this.moduleRef, this.modulesContainer, this.handlerContainer);
scanner.scanAndRegisterHandlers();
}
configure(consumer) {
return consumer.apply(dialog_flow_authorization_middleware_1.DialogFlowAuthorizationMiddleware).forRoutes(dialog_flow_controller_1.DialogFlowController);
}
};
DialogFlowModule = DialogFlowModule_1 = __decorate([
common_1.Module({
providers: [dialog_flow_component_1.DialogFlowComponent, core_2.HandlerContainer],
controllers: [dialog_flow_controller_1.DialogFlowController],
}),
__metadata("design:paramtypes", [core_1.ModuleRef,
injector_1.ModulesContainer,
core_2.HandlerContainer])
], DialogFlowModule);
exports.DialogFlowModule = DialogFlowModule;
identification: Reflect.getMetadata(this.identification, metatype),
};
if (isWorkflow && workflowMeta.identification) {
workflowMeta.target = instance;
return [
workflowMeta,
];
}
else {
return [];
}
}
};
WorkflowExplorerService = __decorate([
common_1.Injectable(),
__metadata("design:paramtypes", [injector_1.ModulesContainer,
metadata_scanner_1.MetadataScanner,
setting_service_1.SettingService])
], WorkflowExplorerService);
exports.WorkflowExplorerService = WorkflowExplorerService;
//# sourceMappingURL=workflow-explorer.service.js.map
if (instance.schema.name) {
pageMetadata.schema = instance.schema;
}
});
return [
pageMetadata,
];
}
else {
return [];
}
}
};
PageExplorerService = __decorate([
common_1.Injectable(),
__metadata("design:paramtypes", [injector_1.ModulesContainer,
metadata_scanner_1.MetadataScanner])
], PageExplorerService);
exports.PageExplorerService = PageExplorerService;
//# sourceMappingURL=page-explorer.service.js.map
return components
.filter(dashboard => dashboard.name && dashboard.methodName)
.map(dashboard => {
const callback = instance[dashboard.methodName].bind(instance);
return Object.assign({ callback }, dashboard);
});
}
flatMap(components, callback) {
return lodash_1.flattenDeep(components.map(component => {
return [...component.values()].map(({ instance }) => callback(instance));
}));
}
};
DashboardExplorerService = __decorate([
common_1.Injectable(),
__metadata("design:paramtypes", [injector_1.ModulesContainer,
metadata_scanner_1.MetadataScanner])
], DashboardExplorerService);
exports.DashboardExplorerService = DashboardExplorerService;
//# sourceMappingURL=dashboard-explorer.service.js.map
components.map(component => {
const reflectedMetadata = metadataScanner
.scanFromPrototype(null, component.prototype, method => {
const intentOrAction = Reflect.getMetadata(constant_1.DIALOG_FLOW_INTENT, Reflect.getOwnPropertyDescriptor(component.prototype, method).value) ||
Reflect.getMetadata(constant_1.DIALOG_FLOW_ACTION, Reflect.getOwnPropertyDescriptor(component.prototype, method).value);
return intentOrAction ? { handler: component.prototype[method], intentOrAction } : null;
})
.filter(v => v);
[...reflectedMetadata].forEach(metadata => {
handlers.set(metadata.intentOrAction, metadata.handler);
});
});
});
return handlers;
},
inject: [injector_1.ModulesContainer],
};
return components
.filter(dashboard => {
return dashboard.name && dashboard.methodName;
})
.map(dashboard => {
const callback = instance[dashboard.methodName].bind(instance);
return Object.assign({ callback }, dashboard);
});
}
flatMap(components, callback) {
return lodash_1.flattenDeep(components.map(component => [...component.values()].map(({ instance }) => callback(instance))));
}
};
InternationalizationExplorerService = __decorate([
common_1.Injectable(),
__metadata("design:paramtypes", [injector_1.ModulesContainer,
metadata_scanner_1.MetadataScanner])
], InternationalizationExplorerService);
exports.InternationalizationExplorerService = InternationalizationExplorerService;
//# sourceMappingURL=internationalization-explorer.service.js.map