public interface b64_encode
Encode numbers (integer and real) to base64.
This is an interface for encoding integer and real numbers of any kinds into a base64 string. This interface can encode both
scalar and array.
Warning The encoded string is returned as varying length character string, character(len=:), allocatable:: string
, thus the
compiler must support such a Fortran (2003) feature.
Note Before start to encode anything the library must be initialized. The procedure b64_init
must be called at first. The
global variable is_b64_initialized
can be used to check the status of the initialization.
For a practical example see the autotest
procedure.
character(len=:), allocatable:: code64 ! base64 encoded string
...
call b64_encode(n=12._R8P,code=code64)
character(len=:), allocatable:: code64 ! base64 encoded string
...
call b64_encode(n=[12_I4P,1_I4P],code=code64)
Note If you want to encode heterogenous data (e.g. integer and real numbers), you must use the auxiliary pack_data
procedure.
Warning The encoding of array of strings is admitted only if each string of the array has the same length.
Calls
interface~~b64_encode~~CallsGraph
interface~b64_encode
b64_encode
proc~b64_encode_r4_a
b64_encode_R4_a
interface~b64_encode->proc~b64_encode_r4_a
proc~b64_encode_r4
b64_encode_R4
interface~b64_encode->proc~b64_encode_r4
proc~b64_encode_i8_a
b64_encode_I8_a
interface~b64_encode->proc~b64_encode_i8_a
proc~b64_encode_i1
b64_encode_I1
interface~b64_encode->proc~b64_encode_i1
proc~b64_encode_r8
b64_encode_R8
interface~b64_encode->proc~b64_encode_r8
proc~b64_encode_string_a
b64_encode_string_a
interface~b64_encode->proc~b64_encode_string_a
proc~b64_encode_i2
b64_encode_I2
interface~b64_encode->proc~b64_encode_i2
proc~b64_encode_string
b64_encode_string
interface~b64_encode->proc~b64_encode_string
proc~b64_encode_i1_a
b64_encode_I1_a
interface~b64_encode->proc~b64_encode_i1_a
proc~b64_encode_i8
b64_encode_I8
interface~b64_encode->proc~b64_encode_i8
proc~b64_encode_i4_a
b64_encode_I4_a
interface~b64_encode->proc~b64_encode_i4_a
proc~b64_encode_r8_a
b64_encode_R8_a
interface~b64_encode->proc~b64_encode_r8_a
proc~b64_encode_i2_a
b64_encode_I2_a
interface~b64_encode->proc~b64_encode_i2_a
proc~b64_encode_i4
b64_encode_I4
interface~b64_encode->proc~b64_encode_i4
proc~encode_bits
encode_bits
proc~b64_encode_r4_a->proc~encode_bits
proc~b64_encode_r4->proc~encode_bits
proc~b64_encode_i8_a->proc~encode_bits
proc~b64_encode_i1->proc~encode_bits
proc~b64_encode_r8->proc~encode_bits
proc~b64_encode_string_a->proc~encode_bits
byte_size
byte_size
proc~b64_encode_string_a->byte_size
proc~b64_encode_i2->proc~encode_bits
proc~b64_encode_string->proc~encode_bits
proc~b64_encode_string->byte_size
proc~b64_encode_i1_a->proc~encode_bits
proc~b64_encode_i8->proc~encode_bits
proc~b64_encode_i4_a->proc~encode_bits
proc~b64_encode_r8_a->proc~encode_bits
proc~b64_encode_i2_a->proc~encode_bits
proc~b64_encode_i4->proc~encode_bits
Nodes of different colours represent the following:
Graph Key
Subroutine
Subroutine
Function
Function
Interface
Interface
Unknown Procedure Type
Unknown Procedure Type
Program
Program
This Page's Entity
This Page's Entity
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.
Called By
interface~~b64_encode~~CalledByGraph
interface~b64_encode
b64_encode
program~volatile_doctest~11
volatile_doctest
program~volatile_doctest~11->interface~b64_encode
program~volatile_doctest~34
volatile_doctest
program~volatile_doctest~34->interface~b64_encode
program~volatile_doctest~4
volatile_doctest
program~volatile_doctest~4->interface~b64_encode
program~volatile_doctest~10
volatile_doctest
program~volatile_doctest~10->interface~b64_encode
program~volatile_doctest~37
volatile_doctest
program~volatile_doctest~37->interface~b64_encode
program~volatile_doctest~5
volatile_doctest
program~volatile_doctest~5->interface~b64_encode
program~volatile_doctest~13
volatile_doctest
program~volatile_doctest~13->interface~b64_encode
program~volatile_doctest~9
volatile_doctest
program~volatile_doctest~9->interface~b64_encode
program~volatile_doctest~2
volatile_doctest
program~volatile_doctest~2->interface~b64_encode
program~volatile_doctest~35
volatile_doctest
program~volatile_doctest~35->interface~b64_encode
program~volatile_doctest~6
volatile_doctest
program~volatile_doctest~6->interface~b64_encode
program~volatile_doctest~14
volatile_doctest
program~volatile_doctest~14->interface~b64_encode
program~volatile_doctest~3
volatile_doctest
program~volatile_doctest~3->interface~b64_encode
program~volatile_doctest~36
volatile_doctest
program~volatile_doctest~36->interface~b64_encode
program~volatile_doctest~7
volatile_doctest
program~volatile_doctest~7->interface~b64_encode
program~volatile_doctest~8
volatile_doctest
program~volatile_doctest~8->interface~b64_encode
Nodes of different colours represent the following:
Graph Key
Subroutine
Subroutine
Function
Function
Interface
Interface
Unknown Procedure Type
Unknown Procedure Type
Program
Program
This Page's Entity
This Page's Entity
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.
Module Procedures
Encode scalar number to base64 (R8P).
Arguments
Type
Intent Optional
Attributes Name
real(kind=R8P),
intent(in)
::
n Number to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded scalar.
Encode array numbers to base64 (R8P).
Arguments
Type
Intent Optional
Attributes Name
real(kind=R8P),
intent(in)
::
n (1:)Array of numbers to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded array.
Encode scalar number to base64 (R4P).
Arguments
Type
Intent Optional
Attributes Name
real(kind=R4P),
intent(in)
::
n Number to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded scalar.
Encode array numbers to base64 (R4P).
Arguments
Type
Intent Optional
Attributes Name
real(kind=R4P),
intent(in)
::
n (1:)Array of numbers to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded array.
Encode scalar number to base64 (I8P).
Arguments
Type
Intent Optional
Attributes Name
integer(kind=I8P),
intent(in)
::
n Number to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded scalar.
Encode array numbers to base64 (I8P).
Arguments
Type
Intent Optional
Attributes Name
integer(kind=I8P),
intent(in)
::
n (1:)Array of numbers to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded array.
Encode scalar number to base64 (I4P).
Arguments
Type
Intent Optional
Attributes Name
integer(kind=I4P),
intent(in)
::
n Number to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded scalar.
Encode array numbers to base64 (I4P).
Arguments
Type
Intent Optional
Attributes Name
integer(kind=I4P),
intent(in)
::
n (1:)Array of numbers to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded array.
Encode scalar number to base64 (I2P).
Arguments
Type
Intent Optional
Attributes Name
integer(kind=I2P),
intent(in)
::
n Number to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded scalar.
Encode array numbers to base64 (I2P).
Arguments
Type
Intent Optional
Attributes Name
integer(kind=I2P),
intent(in)
::
n (1:)Array of numbers to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded array.
Encode scalar number to base64 (I1P).
Arguments
Type
Intent Optional
Attributes Name
integer(kind=I1P),
intent(in)
::
n Number to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded scalar.
Encode array numbers to base64 (I1P).
Arguments
Type
Intent Optional
Attributes Name
integer(kind=I1P),
intent(in)
::
n (1:)Array of numbers to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded array.
Encode scalar string to base64.
Arguments
Type
Intent Optional
Attributes Name
character(len=*),
intent(in)
::
s String to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded scalar.
Encode array string to base64.
Arguments
Type
Intent Optional
Attributes Name
character(len=*),
intent(in)
::
s (1:)String to be encoded.
character(len=:),
intent(out),
allocatable ::
code Encoded scalar.