Packages

MySQL native client is written in Erlang and provides API that is very close to Connector/C library.

Current section

Files

Jump to
mysql_client doc packet_parser_binary.html
Raw

doc/packet_parser_binary.html

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Module packet_parser_binary</title>
<link rel="stylesheet" type="text/css" href="stylesheet.css" title="EDoc">
</head>
<body bgcolor="white">
<div class="navbar"><a name="#navbar_top"></a><table width="100%" border="0" cellspacing="0" cellpadding="2" summary="navigation bar"><tr><td><a href="overview-summary.html" target="overviewFrame">Overview</a></td><td><a href="http://www.erlang.org/"><img src="erlang.png" align="right" border="0" alt="erlang logo"></a></td></tr></table></div>
<hr>
<h1>Module packet_parser_binary</h1>
<ul class="index"><li><a href="#description">Description</a></li><li><a href="#index">Function Index</a></li><li><a href="#functions">Function Details</a></li></ul>This module contains functions these are responsible for parsing binary rows that was previously
exctructed from response packages.
<p>Copyright © 2010-2014 Alexei Krasnopolski</p>
<p><b>Version:</b> 1.2.8</p>
<p><b>Introduced in:</b> 2010-11-18</p>
<p><b>Authors:</b> Alexei Krasnopolski (<a href="mailto:krasnop@bellsouth.net"><tt>krasnop@bellsouth.net</tt></a>) [<em>web site:</em> <tt><a href="http://krasnopolski.org/" target="_top">http://krasnopolski.org/</a></tt>].</p>
<h2><a name="description">Description</a></h2>This module contains functions these are responsible for parsing binary rows that was previously
exctructed from response packages. The module works only with binary rows these usualy come in to
a client during a statement execution.
<h2><a name="index">Function Index</a></h2>
<table width="100%" border="1" cellspacing="0" cellpadding="2" summary="function index"><tr><td valign="top"><a href="#parse_binary_row-2">parse_binary_row/2</a></td><td>function converts binary representation of a packet to list of field values.</td></tr>
</table>
<h2><a name="functions">Function Details</a></h2>
<h3 class="function"><a name="parse_binary_row-2">parse_binary_row/2</a></h3>
<div class="spec">
<p><tt>parse_binary_row(Binary::binary(), Metadata::#metadata{}) -&gt; [integer() | float() | string() | binary() | #mysql_time{} | #mysql_decimal{}] | #mysql_error{}</tt><br></p>
<p> </p>
</div><p>function converts binary representation of a packet to list of field values.
First it extracts 'Null bit map' structure from binary. The map keeps information
about what fields of the response is NULL
(if a field is NULL the one is not present in the next part of the binary packet).
</p>
<hr>
<div class="navbar"><a name="#navbar_bottom"></a><table width="100%" border="0" cellspacing="0" cellpadding="2" summary="navigation bar"><tr><td><a href="overview-summary.html" target="overviewFrame">Overview</a></td><td><a href="http://www.erlang.org/"><img src="erlang.png" align="right" border="0" alt="erlang logo"></a></td></tr></table></div>
<p><i>Generated by EDoc</i></p>
</body>
</html>