@re-ai/inner-tool-sdk
Advanced tools
Comparing version 0.2.15 to 0.2.16
@@ -7,2 +7,4 @@ export * from './types/sms'; | ||
export * from './types/hd/message'; | ||
export * from './types/bridge'; | ||
export * from './types/seamless'; | ||
export * from './entrys'; |
@@ -23,2 +23,4 @@ "use strict"; | ||
__exportStar(require("./types/hd/message"), exports); | ||
__exportStar(require("./types/bridge"), exports); | ||
__exportStar(require("./types/seamless"), exports); | ||
__exportStar(require("./entrys"), exports); |
@@ -36,2 +36,3 @@ /// <reference types="node" /> | ||
private floatArrayTo16BitPcmBuffer; | ||
close(): void; | ||
} |
@@ -41,2 +41,5 @@ "use strict"; | ||
this.ws = undefined; | ||
this.callback && this.callback({ | ||
hook: seamless_1.SeamlessHooks.CLOSE | ||
}); | ||
this.callback = undefined; | ||
@@ -255,3 +258,6 @@ }; | ||
} | ||
close() { | ||
this.ws?.close(); | ||
} | ||
} | ||
exports.Seamless = Seamless; |
@@ -43,3 +43,4 @@ /// <reference types="node" /> | ||
TRANSLATION_TEXT = "translation_text", | ||
TRANSLATION_SPEECH = "translation_speech" | ||
TRANSLATION_SPEECH = "translation_speech", | ||
CLOSE = "close" | ||
} | ||
@@ -46,0 +47,0 @@ export declare enum SeamlessMsgSendNo { |
@@ -12,2 +12,3 @@ "use strict"; | ||
SeamlessHooks["TRANSLATION_SPEECH"] = "translation_speech"; | ||
SeamlessHooks["CLOSE"] = "close"; | ||
})(SeamlessHooks || (exports.SeamlessHooks = SeamlessHooks = {})); | ||
@@ -14,0 +15,0 @@ var SeamlessMsgSendNo; |
{ | ||
"name": "@re-ai/inner-tool-sdk", | ||
"version": "0.2.15", | ||
"version": "0.2.16", | ||
"description": "ReAI内部接口sdk", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -7,3 +7,5 @@ export * from './types/sms' | ||
export * from './types/hd/message' | ||
export * from './types/bridge' | ||
export * from './types/seamless' | ||
export * from './entrys' |
@@ -46,2 +46,6 @@ import WebSocket, { CloseEvent, Data, ErrorEvent, MessageEvent, OpenEvent } from "ws"; | ||
this.ws = undefined | ||
this.callback && this.callback({ | ||
hook: SeamlessHooks.CLOSE | ||
}) | ||
this.callback = undefined | ||
@@ -287,2 +291,6 @@ } | ||
close() { | ||
this.ws?.close() | ||
} | ||
} |
@@ -51,3 +51,4 @@ export type SeamlessOptions = { | ||
TRANSLATION_TEXT = "translation_text", | ||
TRANSLATION_SPEECH = "translation_speech" | ||
TRANSLATION_SPEECH = "translation_speech", | ||
CLOSE = "close" | ||
} | ||
@@ -54,0 +55,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
190318
4980