UNPKG

@litert/televoke

Version:
53 lines 1.95 kB
"use strict"; /** * Copyright 2025 Angus.Fenying <fenying@litert.org> * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * https://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.MAX_PACKET_SIZE = exports.DEFAULT_HOSTNAME = exports.DEFAULT_BACKLOG = exports.DEFAULT_SECURE_PORT = exports.DEFAULT_INSECURE_PORT = exports.EResponseCode = void 0; var EResponseCode; (function (EResponseCode) { /** * API was called succeed */ EResponseCode[EResponseCode["OK"] = 0] = "OK"; /** * The invoked API does not exist on the remote server. */ EResponseCode[EResponseCode["API_NOT_FOUND"] = 1] = "API_NOT_FOUND"; /** * Some unexpected error happened. */ EResponseCode[EResponseCode["SYSTEM_ERROR"] = 2] = "SYSTEM_ERROR"; /** * Logical error happened inside the API handler. */ EResponseCode[EResponseCode["FAILURE"] = 3] = "FAILURE"; /** * The arguments inside the request is malformed. */ EResponseCode[EResponseCode["MALFORMED_ARGUMENTS"] = 4] = "MALFORMED_ARGUMENTS"; })(EResponseCode || (exports.EResponseCode = EResponseCode = {})); /** * The default port for HTTP. */ exports.DEFAULT_INSECURE_PORT = 80; /** * The default port for HTTPS. */ exports.DEFAULT_SECURE_PORT = 443; exports.DEFAULT_BACKLOG = 511; exports.DEFAULT_HOSTNAME = 'localhost'; exports.MAX_PACKET_SIZE = 64 * 1024 * 1024; //# sourceMappingURL=Protocol.v1.decls.js.map