init
TypeScriptstatic init(rawValue: number): NWProtocolWebSocket_CloseCodeSwift declarationinit(rawValue: UInt16) throwsCreate a WebSocket close code from a UInt16 value. - Parameter rawValue: The raw value of the close code. The close code ranges are: 0-999 Status codes in the range 0-999 are not used. 1000-2999 Status codes in the range 1000-2999 are reserved for definition by WebSocket, its future revisions, and extensions specified in a permanent and readily available public specification. 3000-3999 Status codes in the range 3000-3999 are reserved for use by libraries, frameworks, and applications. These close codes are registered directly with IANA. The interpretation of these codes is undefined by WebSocket. 4000-4999 Status codes in the range 4000-4999 are reserved for private use and thus can't be registered. Such codes can be used by prior agreements between WebSocket applications. The interpretation of these codes is undefined by WebSocket.