Class UtilsBase64


  • public class UtilsBase64
    extends java.lang.Object

    Utility class for encoding in base 64.

    Project:

    Library for the integration with the services of @Firma, eVisor and TS@.

    Version:
    1.0, 25/08/2020.
    • Constructor Summary

      Constructors 
      Constructor Description
      UtilsBase64()
      Constructor method for the class UtilsBase64.java.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      byte[] decode​(byte[] abyte0, int i, int j)
      Decodes the supplied bytes.
      byte[] decode​(java.lang.String s)
      Decodes the supplied string.
      java.lang.String encodeBytes​(byte[] abyte0)
      Encodes the supplied bytes.
      java.lang.String encodeBytes​(byte[] abyte0, int i, int j)
      Encodes the supplied bytes in the specified range.
      java.lang.String encodeObject​(java.io.Serializable serializable)
      Encodes the supplied object.
      java.lang.String encodeString​(java.lang.String s)
      Encodes the supplied string.
      boolean isBase64​(java.lang.String encodedStr)  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • UtilsBase64

        public UtilsBase64()
        Constructor method for the class UtilsBase64.java.
    • Method Detail

      • encodeObject

        public java.lang.String encodeObject​(java.io.Serializable serializable)
        Encodes the supplied object.
        Parameters:
        serializable - Serializable object.
        Returns:
        Encoded result.
      • encodeBytes

        public java.lang.String encodeBytes​(byte[] abyte0)
        Encodes the supplied bytes.
        Parameters:
        abyte0 - Arrays of bytes.
        Returns:
        Encoded result.
      • encodeBytes

        public java.lang.String encodeBytes​(byte[] abyte0,
                                            int i,
                                            int j)
        Encodes the supplied bytes in the specified range.
        Parameters:
        abyte0 - Array of bytes to encode.
        i - Started index.
        j - Finished index.
        Returns:
        Encoded result.
      • encodeString

        public java.lang.String encodeString​(java.lang.String s)
        Encodes the supplied string.
        Parameters:
        s - string.
        Returns:
        Encoded result.
      • decode

        public byte[] decode​(java.lang.String s)
        Decodes the supplied string.
        Parameters:
        s - Encoded string.
        Returns:
        Arrays of bytes.
      • decode

        public byte[] decode​(byte[] abyte0,
                             int i,
                             int j)
        Decodes the supplied bytes.
        Parameters:
        abyte0 - Bytes to decode.
        i - Started index.
        j - Finished index.
        Returns:
        Decoded bytes.
      • isBase64

        public boolean isBase64​(java.lang.String encodedStr)