B2G/gecko/dom/mobilemessage/src/ril/WspPduHelper.jsm
/**
   * @param data
   *        A wrapped object containing raw PDU data.
   *
   * @return Decoded character.
   *
   * @throws NullCharError if a NUL character read.
   * @throws CodeError if an invalid character read.
   */
@param data
A wrapped object containing raw PDU data.

@return Decoded character.

@throws NullCharError if a NUL character read.
@throws CodeError if an invalid character read.
@param data A wrapped object containing raw PDU data . @return Decoded character . @throws NullCharError if a NUL character read . @throws CodeError if an invalid character read .
function decode(data) {
    let code = Octet.decode(data);
    if (code == NUL) {
      throw new NullCharError();
    }
    if ((code <= CTLS) || (code >= ASCIIS) || (code == 34) || (code == 60)
        || (code == 62) || ((code >= 91) && (code <= 94)) || (code == 96)
        || ((code >= 123) && (code <= 125)) || (code == 127)) {
      throw new CodeError("URIC: invalid char code " + code);
    }
    return String.fromCharCode(code);
  }
function decode ( data ) { let code = Octet . decode ( data ) ; if ( code == NUL ) { throw new NullCharError ( ) ; } if ( ( code <= CTLS ) || ( code >= ASCIIS ) || ( code == 34 ) || ( code == 60 ) || ( code == 62 ) || ( ( code >= 91 ) && ( code <= 94 ) ) || ( code == 96 ) || ( ( code >= 123 ) && ( code <= 125 ) ) || ( code == 127 ) ) { throw new CodeError ( "URIC: invalid char code " + code ) ; } return String . fromCharCode ( code ) ; }
@param data
        A wrapped object containing raw PDU data.
@param data A wrapped object containing raw PDU data .