ca.mint.mintchip.core

Interface IBase64Processor


public interface IBase64Processor

This interface represents a base64 processor capable of converting a byte array to the base64 string representation and back.

Methods
Modifier and Type Method and Description
byte[] decode(java.lang.String base64String)
Decodes a base64 encoded string to a byte array.
java.lang.String encode(byte[] data)
Encodes provided byte array to the base64 string.
Method Detail

decode

byte[] decode(java.lang.String base64String) throws java.io.IOException

Decodes a base64 encoded string to a byte array.

Parameters:
base64String - a string to be decoded
Returns:
a byte array
Throws:
java.io.IOException - if decoding fails

encode

java.lang.String encode(byte[] data) throws java.io.IOException

Encodes provided byte array to the base64 string.

Parameters:
data - a byte array to be encoded as the base64 string
Returns:
the base64 string representation of the data
Throws:
java.io.IOException - if encoding fails