_write(type, chunk, is_binary, compress, callback) {
        // Ensure websocket still exists before attempting to write
        if (this.#ws) {
            // Attempt to send this fragment using the appropriate fragment method from uWS
            let sent;
            switch (type) {
                case FRAGMENTS.FIRST:
                    sent = this.#ws.sendFirstFragment(chunk, is_binary, compress);
                    break;
                case FRAGMENTS.MIDDLE:
                    sent = this.#ws.sendFragment(chunk, is_binary, compress);
                    break;
                case FRAGMENTS.LAST:
                    sent = this.#ws.sendLastFragment(chunk, is_binary, compress);
                    break;
                default:
                    throw new Error('Websocket._write() -> Invalid Fragment type constant provided.');
            }

            if (sent) {
                // Invoke the callback if chunk was sent successfully
                if (callback) callback();
            } else {
                // Wait for this connection to drain before retrying this chunk
                this.once('drain', () => this._write(type, chunk, is_binary, compress, callback));
            }

            // Return the sent status for consumer
            return sent;
        }

        // Throw an error with NOT_CONNECTED message to be caught by executor
        throw new Error('Websocket is no longer connected.');
    }
Initiates fragment based message writing with uWS and writes appropriate chunk based on provided type parameter.

@param {String} type
@param {String|Buffer|ArrayBuffer} chunk
@param {Boolean=} is_binary
@param {Boolean=} compress
@param {Function=} callback
@returns {Boolean}