def EncodeData(self, raw_text_data, encoding):
    if encoding != 'base64url':
      raise ValueError('Unknown encoding %s' % encoding)

    return base64.urlsafe_b64encode(
        unicode(raw_text_data).encode('utf-8')).encode('utf-8')
Encodes raw data into an armored form.
dataset/ETHPy150Open mimecuvalo/helloworld/packages/magicsig/__init__.py/MagicEnvelopeProtocol.EncodeData