Provide the size of the data once base64 encoded
When data is encoded in Base64, it is packed in groups of 3 bytes, which are then encoded in 4 bytes (by groups of 6 bytes). In case length is not a multiple of 3, we add padding. It means we need length / 3 * 4 + length % 3 ? 4 : 0.
Number of bytes to be encoded
The size needed to encode a data of the provided length
See Implementation
Provide the size of the data once base64 encoded
When data is encoded in Base64, it is packed in groups of 3 bytes, which are then encoded in 4 bytes (by groups of 6 bytes). In case length is not a multiple of 3, we add padding. It means we need length / 3 * 4 + length % 3 ? 4 : 0.