[#BloombergLP-baltzo-ZoneinfoBinaryReader-read-05]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/baltzo.adoc[baltzo]::xref:BloombergLP/baltzo/ZoneinfoBinaryReader.adoc[ZoneinfoBinaryReader]::read
:relfileprefix: ../../../
:mrdocs:

Read well&hyphen;formed time zone information from a binary stream&period;

== Synopsis

Declared in `&lt;baltzo&lowbar;zoneinfobinaryreader&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
int
read(
    xref:BloombergLP/baltzo/Zoneinfo.adoc[Zoneinfo]* zoneinfoResult,
    std::istream& stream);
----

== Description

Read time zone information from the specified `stream`, and load the description into the specified `zoneinfoResult`&period; The `zoneinfoResult` will have a sentinel transition at 01&hyphen;01&hyphen;001, meeting the first two requirements for a &quot;well&hyphen;formed&quot; object (see `baltzo&colon;&colon;ZoneinfoUtil&colon;&colon;isWellFormed` documentation)&period; Return 0 on success and a non&hyphen;zero value if `stream` does not provide a sequence of bytes consistent with the Zoneinfo binary format&period; If an error occurs during the operation, `zoneinfoResult` is unspecified&period; Optionally specify a `headerResult` that, on success, will be populated with a summary of the `stream` contents&period;

== Return Value

0 on success, and a non&hyphen;zero value otherwise

== Parameters

[cols="1,4"]
|===
| Name| Description
| *zoneinfoResult*
| receives the loaded time zone information
| *stream*
| binary input stream providing Zoneinfo data
|===


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