mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2026-02-06 13:05:09 +00:00
Add service handler registration and DI support
Introduces dependency injection via Inversify and reflect-metadata, adds a service handler registry for packet handling, and updates core initialization to auto-register and bind service handlers. Also updates Vite configs and auto-include logic to support protocol service files.
This commit is contained in:
8
packages/napcat-core/protocol/OlpushSerivce.ts
Normal file
8
packages/napcat-core/protocol/OlpushSerivce.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import { ReceiveService, ServiceBase } from "../packet/handler/serviceRegister";
|
||||
|
||||
// @ReceiveService('trpc.msg.olpush.OlPushService.MsgPush')
|
||||
// export class OlPushService extends ServiceBase {
|
||||
// async handler(seq: number, hex_data: string) {
|
||||
// console.log(`OlPushService handler called with seq: ${seq} and data: ${hex_data}`);
|
||||
// }
|
||||
// }
|
||||
Reference in New Issue
Block a user