[#BloombergLP-bdlde-Base64Encoder-convert-06]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlde.adoc[bdlde]::xref:BloombergLP/bdlde/Base64Encoder.adoc[Base64Encoder]::convert
:relfileprefix: ../../../
:mrdocs:

`convert` overloads

== Synopses

Declared in `&lt;bdlde&lowbar;base64encoder&period;h&gt;`

Encode the sequence of input characters starting at the specified `begin` position up to, but not including, the specified `end` position, writing any resulting output characters to the specified `out` buffer&period; Optionally specify the `maxNumOut` limit on the number of bytes to output&semi; if `maxNumOut` is negative, no limit is imposed&period; If the `maxNumOut` limit is reached, no further input will be consumed&period; Load into the (optionally) specified `numOut` and `numIn` the number of output bytes produced and input bytes consumed, respectively&period; Return a non&hyphen;negative value on success and a negative value otherwise&period; A positive return status indicates the number of valid processed output bytes retained by this encoder and not written to `out` because `maxNumOut` has been reached&semi; these bytes are available for output if this method is called with appropriate input&period; Note that calling this method after `endConvert` has been invoked without an intervening `resetState` call will place this instance in an error state, and return an error status&period; Note also that it is recommended that after all calls to `convert` are finished, the `endConvert` method be called to complete the encoding of any unprocessed input characters that do not complete a 3&hyphen;byte sequence&period;


[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    class OUTPUT&lowbar;ITERATOR,
    class INPUT&lowbar;ITERATOR&gt;
int
xref:BloombergLP/bdlde/Base64Encoder/convert-04.adoc[convert](
    OUTPUT&lowbar;ITERATOR out,
    INPUT&lowbar;ITERATOR begin,
    INPUT&lowbar;ITERATOR end);
----

[.small]#xref:BloombergLP/bdlde/Base64Encoder/convert-04.adoc[_» more&period;&period;&period;_]#

Same as the preceding `convert` overload, also loading `numOut` and `numIn`&period;


[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    class OUTPUT&lowbar;ITERATOR,
    class INPUT&lowbar;ITERATOR&gt;
int
xref:BloombergLP/bdlde/Base64Encoder/convert-05.adoc[convert](
    OUTPUT&lowbar;ITERATOR out,
    int* numOut,
    int* numIn,
    INPUT&lowbar;ITERATOR begin,
    INPUT&lowbar;ITERATOR end,
    int maxNumOut = &hyphen;1);
----

[.small]#xref:BloombergLP/bdlde/Base64Encoder/convert-05.adoc[_» more&period;&period;&period;_]#


[.small]#Created with https://www.mrdocs.com[MrDocs]#
