performCharTranslate (codePoint, index, content, isEncode) {
    let variant = this.getSettingValue('variant')

    if (variant === 'rot5' || variant === 'rot18') {
      // rotate numbers 0-9
      codePoint = this._rotateCodePoint(codePoint, 48, 57)
    }

    if (variant === 'rot13' || variant === 'rot18') {
      // rotate lowercase letters a-z
      codePoint = this._rotateCodePoint(codePoint, 97, 122)
      // rotate uppercase letters A-Z
      codePoint = this._rotateCodePoint(codePoint, 65, 90)
    }

    if (variant === 'rot47') {
      // rotate characters !-~
      codePoint = this._rotateCodePoint(codePoint, 33, 126)
    }

    return codePoint
  }
/**
   * Performs encode or decode on given character, index and content.
   * @protected
   * @param {number} codePoint Unicode code point
   * @param {number} index Unicode code point index inside content.
   * @param {Chain} content Content to be translated.
   * @param {boolean} isEncode True for encoding, false for decoding.
   * @return {number} Resulting Unicode code point
   */
Performs encode or decode on given character, index and content.
@protected
@param {number} codePoint Unicode code point
@param {number} index Unicode code point index inside content.
@param {Chain} content Content to be translated.
@param {boolean} isEncode True for encoding, false for decoding.
@return {number} Resulting Unicode code point
Performs encode or decode on given character index and content . @protected @param { number } codePoint Unicode code point @param { number } index Unicode code point index inside content . @param { Chain } content Content to be translated . @param { boolean } isEncode True for encoding false for decoding . @return { number } Resulting Unicode code point
performCharTranslate (codePoint, index, content, isEncode) {
    let variant = this.getSettingValue('variant')
    if (variant === 'rot5' || variant === 'rot18') {
      codePoint = this._rotateCodePoint(codePoint, 48, 57)
    }
    if (variant === 'rot13' || variant === 'rot18') {
      codePoint = this._rotateCodePoint(codePoint, 97, 122)
      codePoint = this._rotateCodePoint(codePoint, 65, 90)
    }
    if (variant === 'rot47') {
      codePoint = this._rotateCodePoint(codePoint, 33, 126)
    }
    return codePoint
  }
performCharTranslate ( codePoint , index , content , isEncode ) { let variant = this . getSettingValue ( 'variant' ) if ( variant === 'rot5' || variant === 'rot18' ) { codePoint = this . _rotateCodePoint ( codePoint , 48 , 57 ) } if ( variant === 'rot13' || variant === 'rot18' ) { codePoint = this . _rotateCodePoint ( codePoint , 97 , 122 ) codePoint = this . _rotateCodePoint ( codePoint , 65 , 90 ) } if ( variant === 'rot47' ) { codePoint = this . _rotateCodePoint ( codePoint , 33 , 126 ) } return codePoint }
Performs encode or decode on given character, index and content.
Performs encode or decode on given character index and content .
// rotate numbers 0-9 // rotate lowercase letters a-z // rotate uppercase letters A-Z // rotate characters !-~