This function converts a sequence of numbers in to an alphanumeric string in Data-URI format (click here fore more details).
The numbers are seen as byte values and are Base64 encoded.
The syntax of the returned alphanumeric string is:
data:<media type>;base64,<data>
with:
- media type: MIME type deduced from the number sequence value analysis,
- data: series of Base64-encoded numbers.
The automatic MIME-type deduction is performed via javax.ImageIO APIs. These natively support the following formats:
- BMP: Bitmap
- WBMP: Wireless Bitmap
- PNG: Portable Network Graphics
- GIF: Graphics Interchange Format
- JPEG: Joint Photographic Experts Group
To specify an unrecognized MIME type, enter the mimeType parameter with an alphanumeric string representing the MIME type. Click here for more details.
Parameters
Number sequence |
byteTab |
Sequence of numbers to encode in Base64 format. |
Mandatory |
String |
mimeType |
Mime type of the data represented by byteTab |
Optional |
For example
<@hardisFo.foExternalGraphic src=hardisCore.blobToBase64DataURI(.data_model.photo147) contentWidth="500px"/> <fo:external-graphic src=hardisCore.blobToBase64DataURI(.data_model.photo147, "image/tiff") content-width="500px"/>