MCPcopy
hub / github.com/alibaba/pont / command

Function command

packages/vscode-pont/src/commands/index.ts:74–81  ·  view source on GitHub ↗
(commandId: CommandId, type: CommandType = 'command')

Source from the content-addressed store, hash-verified

72const pollingManage = new PollingManage();
73
74function command(commandId: CommandId, type: CommandType = 'command'): Function {
75 return (_target: any, key: string, descriptor: any) => {
76 if (!(typeof descriptor.value === 'function')) {
77 throw new Error('not supported');
78 }
79 Commands.push({ commandId, key, type, method: descriptor.value });
80 };
81}
82
83export class CommandCenter {
84 private manager: Manager;

Callers 1

CommandCenterClass · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected