<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version="1.8.14">
  <compounddef id="AsciiTable_8h" kind="file" language="C++">
    <compoundname>AsciiTable.h</compoundname>
    <includes refid="tools_8h" local="no">../tools.h</includes>
    <includes refid="AsciiFile_8h" local="yes">AsciiFile.h</includes>
    <includedby refid="AsciiFileComm_8h" local="no">/root/cis_interface/cis_interface/cis_interface/communication/AsciiFileComm.h</includedby>
    <includedby refid="AsciiTableComm_8h" local="no">/root/cis_interface/cis_interface/cis_interface/communication/AsciiTableComm.h</includedby>
    <includedby refid="comm__header_8h" local="no">/root/cis_interface/cis_interface/cis_interface/communication/comm_header.h</includedby>
    <includedby refid="CisInterface_8h" local="no">/root/cis_interface/cis_interface/cis_interface/interface/CisInterface.h</includedby>
    <includedby refid="PsiInterface_8h" local="no">/root/cis_interface/cis_interface/cis_interface/interface/PsiInterface.h</includedby>
    <includedby refid="AsciiTableSerialize_8h" local="no">/root/cis_interface/cis_interface/cis_interface/serialize/AsciiTableSerialize.h</includedby>
    <includedby refid="FormatSerialize_8h" local="no">/root/cis_interface/cis_interface/cis_interface/serialize/FormatSerialize.h</includedby>
    <incdepgraph>
      <node id="335">
        <label>stdint.h</label>
        <link refid="stdint_8h_source"/>
        <childnode refid="336" relation="include">
        </childnode>
        <childnode refid="337" relation="include">
        </childnode>
      </node>
      <node id="330">
        <label>stdarg.h</label>
      </node>
      <node id="325">
        <label>/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h</label>
        <link refid="AsciiTable_8h"/>
        <childnode refid="326" relation="include">
        </childnode>
        <childnode refid="339" relation="include">
        </childnode>
      </node>
      <node id="329">
        <label>stdlib.h</label>
      </node>
      <node id="331">
        <label>errno.h</label>
      </node>
      <node id="337">
        <label>stddef.h</label>
      </node>
      <node id="326">
        <label>../tools.h</label>
        <link refid="tools_8h_source"/>
        <childnode refid="327" relation="include">
        </childnode>
        <childnode refid="328" relation="include">
        </childnode>
        <childnode refid="329" relation="include">
        </childnode>
        <childnode refid="330" relation="include">
        </childnode>
        <childnode refid="331" relation="include">
        </childnode>
        <childnode refid="332" relation="include">
        </childnode>
        <childnode refid="333" relation="include">
        </childnode>
        <childnode refid="335" relation="include">
        </childnode>
        <childnode refid="338" relation="include">
        </childnode>
      </node>
      <node id="339">
        <label>AsciiFile.h</label>
        <link refid="AsciiFile_8h_source"/>
        <childnode refid="326" relation="include">
        </childnode>
      </node>
      <node id="336">
        <label>wchar.h</label>
      </node>
      <node id="327">
        <label>string.h</label>
      </node>
      <node id="338">
        <label>unistd.h</label>
      </node>
      <node id="333">
        <label>regex_posix.h</label>
        <link refid="regex__posix_8h_source"/>
        <childnode refid="334" relation="include">
        </childnode>
        <childnode refid="335" relation="include">
        </childnode>
      </node>
      <node id="332">
        <label>time.h</label>
      </node>
      <node id="334">
        <label>regex.h</label>
      </node>
      <node id="328">
        <label>stdio.h</label>
      </node>
    </incdepgraph>
    <invincdepgraph>
      <node id="347">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/AsciiTableComm.h</label>
        <link refid="AsciiTableComm_8h_source"/>
        <childnode refid="342" relation="include">
        </childnode>
      </node>
      <node id="340">
        <label>/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h</label>
        <link refid="AsciiTable_8h"/>
        <childnode refid="341" relation="include">
        </childnode>
        <childnode refid="347" relation="include">
        </childnode>
        <childnode refid="348" relation="include">
        </childnode>
        <childnode refid="343" relation="include">
        </childnode>
        <childnode refid="346" relation="include">
        </childnode>
        <childnode refid="354" relation="include">
        </childnode>
        <childnode refid="356" relation="include">
        </childnode>
      </node>
      <node id="341">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/AsciiFileComm.h</label>
        <link refid="AsciiFileComm_8h_source"/>
        <childnode refid="342" relation="include">
        </childnode>
      </node>
      <node id="354">
        <label>/root/cis_interface/cis_interface/cis_interface/serialize/AsciiTableSerialize.h</label>
        <link refid="AsciiTableSerialize_8h_source"/>
        <childnode refid="355" relation="include">
        </childnode>
      </node>
      <node id="345">
        <label>/root/cis_interface/cis_interface/cis_interface/interface/PsiInterface.hpp</label>
        <link refid="PsiInterface_8hpp_source"/>
      </node>
      <node id="356">
        <label>/root/cis_interface/cis_interface/cis_interface/serialize/FormatSerialize.h</label>
        <link refid="FormatSerialize_8h_source"/>
        <childnode refid="355" relation="include">
        </childnode>
      </node>
      <node id="351">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/ServerComm.h</label>
        <link refid="ServerComm_8h_source"/>
        <childnode refid="342" relation="include">
        </childnode>
      </node>
      <node id="343">
        <label>/root/cis_interface/cis_interface/cis_interface/interface/CisInterface.h</label>
        <link refid="CisInterface_8h_source"/>
        <childnode refid="344" relation="include">
        </childnode>
        <childnode refid="346" relation="include">
        </childnode>
      </node>
      <node id="355">
        <label>/root/cis_interface/cis_interface/cis_interface/serialize/serialize.h</label>
        <link refid="serialize_8h_source"/>
        <childnode refid="342" relation="include">
        </childnode>
      </node>
      <node id="348">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/comm_header.h</label>
        <link refid="comm__header_8h_source"/>
        <childnode refid="349" relation="include">
        </childnode>
        <childnode refid="342" relation="include">
        </childnode>
        <childnode refid="350" relation="include">
        </childnode>
        <childnode refid="351" relation="include">
        </childnode>
        <childnode refid="352" relation="include">
        </childnode>
      </node>
      <node id="350">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/RPCComm.h</label>
        <link refid="RPCComm_8h_source"/>
        <childnode refid="342" relation="include">
        </childnode>
      </node>
      <node id="346">
        <label>/root/cis_interface/cis_interface/cis_interface/interface/PsiInterface.h</label>
        <link refid="PsiInterface_8h_source"/>
      </node>
      <node id="352">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/ZMQComm.h</label>
        <link refid="ZMQComm_8h_source"/>
        <childnode refid="342" relation="include">
        </childnode>
        <childnode refid="353" relation="include">
        </childnode>
      </node>
      <node id="344">
        <label>/root/cis_interface/cis_interface/cis_interface/interface/CisInterface.hpp</label>
        <link refid="CisInterface_8hpp_source"/>
        <childnode refid="345" relation="include">
        </childnode>
      </node>
      <node id="353">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/DefaultComm.h</label>
        <link refid="DefaultComm_8h_source"/>
        <childnode refid="349" relation="include">
        </childnode>
        <childnode refid="342" relation="include">
        </childnode>
        <childnode refid="350" relation="include">
        </childnode>
        <childnode refid="351" relation="include">
        </childnode>
      </node>
      <node id="349">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/ClientComm.h</label>
        <link refid="ClientComm_8h_source"/>
        <childnode refid="342" relation="include">
        </childnode>
      </node>
      <node id="342">
        <label>/root/cis_interface/cis_interface/cis_interface/communication/communication.h</label>
        <link refid="communication_8h_source"/>
        <childnode refid="343" relation="include">
        </childnode>
        <childnode refid="346" relation="include">
        </childnode>
      </node>
    </invincdepgraph>
    <innerclass refid="structasciiTable__t" prot="public">asciiTable_t</innerclass>
      <sectiondef kind="define">
      <memberdef kind="define" id="AsciiTable_8h_1a1bd3cdb7e51b850ce251f02c38c7739a" prot="public" static="no">
        <name>FMT_LEN</name>
        <initializer>100</initializer>
        <briefdescription>
<para>Flag for checking if <ref refid="AsciiTable_8h_source" kindref="compound">AsciiTable.h</ref> has already been included. </para>        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="12" column="9" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="12" bodyend="-1"/>
      </memberdef>
      </sectiondef>
      <sectiondef kind="enum">
      <memberdef kind="enum" id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790fa" prot="public" static="no" strong="no">
        <type></type>
        <name>fmt_types</name>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faa9c0d90abd7ce90f6784960a4aed5cea7" prot="public">
          <name>AT_STRING</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faac1eda2d616ec5fe5677472a1d2014da9" prot="public">
          <name>AT_FLOAT</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faa5b9e08c50d43dd49e26ab317642697ca" prot="public">
          <name>AT_DOUBLE</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faa5406a83b253a43a8b620ec5bd0659b3c" prot="public">
          <name>AT_COMPLEX</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faaaa8c9118161e27e2e2a7f9ce7b4cc299" prot="public">
          <name>AT_SHORTSHORT</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faaa7050c90450432c07586846df96d11b9" prot="public">
          <name>AT_SHORT</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faae5b0ec5e9ff711a8fa6617669146cba6" prot="public">
          <name>AT_INT</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faac73e80534a4bdd66f6a148006a72ef41" prot="public">
          <name>AT_LONG</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faab5724038f1500cc5453960691aee9de3" prot="public">
          <name>AT_LONGLONG</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faabf05bf89d239151f75dc47ce6b7dbf5f" prot="public">
          <name>AT_USHORTSHORT</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faaa30191b2842b1c59928c330e2546ffe3" prot="public">
          <name>AT_USHORT</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faa3c99e219af0532a5a07462ba714a1ca0" prot="public">
          <name>AT_UINT</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faa96dbc8a6f96c7a731c35496f406c9857" prot="public">
          <name>AT_ULONG</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <enumvalue id="AsciiTable_8h_1ae0bb117f17ab81d1efd74b0e4ff790faaac84b03321bc02c753c5efbc4627bda2" prot="public">
          <name>AT_ULONGLONG</name>
          <briefdescription>
          </briefdescription>
          <detaileddescription>
          </detaileddescription>
        </enumvalue>
        <briefdescription>
<para>Enumerated types to be used for interpreting formats. </para>        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="15" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="15" bodyend="17"/>
      </memberdef>
      </sectiondef>
      <sectiondef kind="typedef">
      <memberdef kind="typedef" id="AsciiTable_8h_1ac239c9dc53457dcb09bffb7dd0f1474e" prot="public" static="no">
        <type>struct <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
        <definition>typedef struct asciiTable_t  asciiTable_t</definition>
        <argsstring></argsstring>
        <name>asciiTable_t</name>
        <briefdescription>
<para>Structure containing information about an ASCII table. </para>        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="89" column="1"/>
      </memberdef>
      </sectiondef>
      <sectiondef kind="func">
      <memberdef kind="function" id="AsciiTable_8h_1aaec1ba2d1988e74fe162386f0677fcf2" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int count_complex_formats</definition>
        <argsstring>(const char *fmt_str)</argsstring>
        <name>count_complex_formats</name>
        <param>
          <type>const char *</type>
          <declname>fmt_str</declname>
        </param>
        <briefdescription>
<para>Count format specifiers for complex numbers. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">fmt_str</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to string that should be searched for format specifiers. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int Number of complex format specifiers found. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="26" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="26" bodyend="32"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a2059b2fabbacee5e6de895822beb99cd" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int count_formats</definition>
        <argsstring>(const char *fmt_str)</argsstring>
        <name>count_formats</name>
        <param>
          <type>const char *</type>
          <declname>fmt_str</declname>
        </param>
        <briefdescription>
<para>Count how many % format specifiers there are in format string. Formats are found by counting the number of matches to the regular expression adapted from <ulink url="https://stackoverflow.com/questions/446285/validate-sprintf-format-from-input-field-with-regex">https://stackoverflow.com/questions/446285/validate-sprintf-format-from-input-field-with-regex</ulink>. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">fmt_str</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to string that should be searched for format specifiers. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int Number of format specifiers found. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="43" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="43" bodyend="48"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a9d0443ed02f7b09068f88be2a00f4dd9" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int simplify_formats</definition>
        <argsstring>(char *fmt_str, const size_t fmt_len)</argsstring>
        <name>simplify_formats</name>
        <param>
          <type>char *</type>
          <declname>fmt_str</declname>
        </param>
        <param>
          <type>const size_t</type>
          <declname>fmt_len</declname>
        </param>
        <briefdescription>
<para>Remove extra format characters that confusing sscanf. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">fmt_str</parametername>
</parameternamelist>
<parameterdescription>
<para>character pointer to string that should be modified. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">fmt_len</parametername>
</parameternamelist>
<parameterdescription>
<para>constant size_t, length of the fmt_str buffer. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int -1 on failure if the regex could not be compiled or the buffer is not big enough to contain the result. If succesful, the new length of buf is returned. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="59" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="59" bodyend="77"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1aa392a2b640022f5fc7f928660f3d4859" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_open</definition>
        <argsstring>(asciiTable_t *t)</argsstring>
        <name>at_open</name>
        <param>
          <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> *</type>
          <declname>t</declname>
        </param>
        <briefdescription>
<para>Open the file. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int 0 if opened successfully, -1 otherwise. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="97" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="97" bodyend="99"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1aafdce9672f7a9645a1a7b9af886727ea" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>void</type>
        <definition>static void at_close</definition>
        <argsstring>(asciiTable_t *t)</argsstring>
        <name>at_close</name>
        <param>
          <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> *</type>
          <declname>t</declname>
        </param>
        <briefdescription>
<para>Close the file. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int 0 if ocloseded successfully, -1 otherwise. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="107" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="107" bodyend="109"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1ae9ea1b6f4cc50b7cd38a10b52c065c23" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_readline_full_realloc</definition>
        <argsstring>(const asciiTable_t t, char **buf, const size_t len_buf, const int allow_realloc)</argsstring>
        <name>at_readline_full_realloc</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>char **</type>
          <declname>buf</declname>
        </param>
        <param>
          <type>const size_t</type>
          <declname>len_buf</declname>
        </param>
        <param>
          <type>const int</type>
          <declname>allow_realloc</declname>
        </param>
        <briefdescription>
<para>Read a line from the file until one is returned that is not a comment. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">buf</parametername>
</parameternamelist>
<parameterdescription>
<para>pointer to memory where read line should be stored. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">len_buf</parametername>
</parameternamelist>
<parameterdescription>
<para>Size of buffer where line should be stored. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">allow_realloc</parametername>
</parameternamelist>
<parameterdescription>
<para>const int If 1, the buffer will be realloced if it is not large enought. Otherwise an error will be returned. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters read. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="121" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="121" bodyend="162"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a155a43f52185fe1a3ac93c5e00cc9f2d" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_readline_full</definition>
        <argsstring>(const asciiTable_t t, char *buf, const size_t len_buf)</argsstring>
        <name>at_readline_full</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>char *</type>
          <declname>buf</declname>
        </param>
        <param>
          <type>const size_t</type>
          <declname>len_buf</declname>
        </param>
        <briefdescription>
<para>Read a line from the file until one is returned that is not a comment. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">buf</parametername>
</parameternamelist>
<parameterdescription>
<para>pointer to memory where read line should be stored. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">len_buf</parametername>
</parameternamelist>
<parameterdescription>
<para>Size of buffer where line should be stored. The the message is larger than len_buf, an error will be returned. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters read. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="173" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="173" bodyend="176"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a5b94012427bf984488a3b569dd497c94" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_writeline_full</definition>
        <argsstring>(const asciiTable_t t, const char *line)</argsstring>
        <name>at_writeline_full</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>line</declname>
        </param>
        <briefdescription>
<para>Write a line to the file. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">line</parametername>
</parameternamelist>
<parameterdescription>
<para>Pointer to line that should be written. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters written. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="185" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="185" bodyend="189"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a15cc80a333c1f3b387261829b099c7bf" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_vbytes_to_row</definition>
        <argsstring>(const asciiTable_t t, const char *line, va_list ap)</argsstring>
        <name>at_vbytes_to_row</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>line</declname>
        </param>
        <param>
          <type>va_list</type>
          <declname>ap</declname>
        </param>
        <briefdescription>
<para>Parse a line to get row columns. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">line</parametername>
</parameternamelist>
<parameterdescription>
<para>Pointer to memory containing the line to be parsed. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">ap</parametername>
</parameternamelist>
<parameterdescription>
<para>va_list Pointers to variables where parsed arguments should be stored. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of arguments filled. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="200" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="200" bodyend="217"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a86b717123c59f37e39cabe1d5e4d9f94" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_vrow_to_bytes</definition>
        <argsstring>(const asciiTable_t t, char *buf, const size_t buf_siz, va_list ap)</argsstring>
        <name>at_vrow_to_bytes</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>char *</type>
          <declname>buf</declname>
        </param>
        <param>
          <type>const size_t</type>
          <declname>buf_siz</declname>
        </param>
        <param>
          <type>va_list</type>
          <declname>ap</declname>
        </param>
        <briefdescription>
<para>Format arguments to form a line. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">buf</parametername>
</parameternamelist>
<parameterdescription>
<para>Pointer to memory where the formated row should be stored. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">buf_siz</parametername>
</parameternamelist>
<parameterdescription>
<para>size_t Size of buf. If the formatted message will exceed the size of the buffer, an error will be returned. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">ap</parametername>
</parameternamelist>
<parameterdescription>
<para>va_list Variables that should be formatted using the format string to create a line in the table. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters written. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="230" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="230" bodyend="233"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a5d3bdde3a0beb050a8699e7d7907d4e6" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_vreadline</definition>
        <argsstring>(const asciiTable_t t, va_list ap)</argsstring>
        <name>at_vreadline</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>va_list</type>
          <declname>ap</declname>
        </param>
        <briefdescription>
<para>Read a line from the file and parse it. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">ap</parametername>
</parameternamelist>
<parameterdescription>
<para>va_list Pointers to variables where parsed arguments should be stored. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters read. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="243" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="243" bodyend="263"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a2ad380bc74295b4f561d5d496c558843" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_vwriteline</definition>
        <argsstring>(const asciiTable_t t, va_list ap)</argsstring>
        <name>at_vwriteline</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>va_list</type>
          <declname>ap</declname>
        </param>
        <briefdescription>
<para>Format arguments to form a line and write it to the file. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">ap</parametername>
</parameternamelist>
<parameterdescription>
<para>va_list Variables that should be formatted using the format string to create a line in the table. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters written. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="273" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="273" bodyend="276"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1ae69d8028086c1dfbc9d1f3c47d2b58cd" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_readline</definition>
        <argsstring>(const asciiTable_t t,...)</argsstring>
        <name>at_readline</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>...</type>
        </param>
        <briefdescription>
<para>Read a line from the file and parse it. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">...</parametername>
</parameternamelist>
<parameterdescription>
<para>Pointers to variables where parsed arguments should be stored. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters read. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="286" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="286" bodyend="292"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a3537e4479c4c6146115a606c4be89fb0" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_writeline</definition>
        <argsstring>(const asciiTable_t t,...)</argsstring>
        <name>at_writeline</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>...</type>
        </param>
        <briefdescription>
<para>Format arguments to form a line and write it to the file. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">...</parametername>
</parameternamelist>
<parameterdescription>
<para>Variables that should be formatted using the format string to create a line in the table. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters written. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="302" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="302" bodyend="308"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a99cf4e10276fa57632a44489ce1883ce" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_writeformat</definition>
        <argsstring>(const asciiTable_t t)</argsstring>
        <name>at_writeformat</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <briefdescription>
<para>Write the format string the the file, prepending it with a comment. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int On success, the number of characters written. -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="316" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="316" bodyend="325"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a065c972ea3d12c9c0b3b18f60ae2fb67" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_discover_format_str</definition>
        <argsstring>(asciiTable_t *t)</argsstring>
        <name>at_discover_format_str</name>
        <param>
          <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> *</type>
          <declname>t</declname>
        </param>
        <briefdescription>
<para>Try to find the format string in the file. The format string is assumed to start with a comment. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>0 on success, -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="334" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="334" bodyend="357"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a0603f9b3c88d350047d07d7ae1be7885" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_set_ncols</definition>
        <argsstring>(asciiTable_t *t)</argsstring>
        <name>at_set_ncols</name>
        <param>
          <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> *</type>
          <declname>t</declname>
        </param>
        <briefdescription>
<para>Set the number of columns by counting the format specifiers. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int The number of columns counted. Negative values indicate errors. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="365" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="365" bodyend="371"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1aaf2ff73c9e5029825d7da00efc5d37c4" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_set_format_siz</definition>
        <argsstring>(asciiTable_t *t)</argsstring>
        <name>at_set_format_siz</name>
        <param>
          <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> *</type>
          <declname>t</declname>
        </param>
        <briefdescription>
<para>Determine the column sizes based on the types. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure that sizes will be added to. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int 0 on success, -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="380" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="380" bodyend="412"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1ab0a82f6cbb7d372d6ea2fbab1da2d4af" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_set_format_typ</definition>
        <argsstring>(asciiTable_t *t)</argsstring>
        <name>at_set_format_typ</name>
        <param>
          <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> *</type>
          <declname>t</declname>
        </param>
        <briefdescription>
<para>Determine the column types by parsing the format string. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure that types will be added to. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int 0 on success, -1 on failure. TODO: switch to regex </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="421" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="421" bodyend="508"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a3238694543600c033723a12a910b8671" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_vbytes_to_array</definition>
        <argsstring>(const asciiTable_t t, const char *data, const size_t data_siz, va_list ap)</argsstring>
        <name>at_vbytes_to_array</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>data</declname>
        </param>
        <param>
          <type>const size_t</type>
          <declname>data_siz</declname>
        </param>
        <param>
          <type>va_list</type>
          <declname>ap</declname>
        </param>
        <briefdescription>
<para>Convert data into arrays for columns. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">data</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to memory containing data that should be parsed. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">data_siz</parametername>
</parameternamelist>
<parameterdescription>
<para>constant size_t Size of data in bytes. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">ap</parametername>
</parameternamelist>
<parameterdescription>
<para>va_list Pointers to pointers to memory where columns should be stored. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int Number of rows read on success, -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="521" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="521" bodyend="560"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1aa847c52c2fc553e909e1f3e64c6683de" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_varray_to_bytes</definition>
        <argsstring>(const asciiTable_t t, char *data, const size_t data_siz, va_list ap)</argsstring>
        <name>at_varray_to_bytes</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>char *</type>
          <declname>data</declname>
        </param>
        <param>
          <type>const size_t</type>
          <declname>data_siz</declname>
        </param>
        <param>
          <type>va_list</type>
          <declname>ap</declname>
        </param>
        <briefdescription>
<para>Encode a set of arrays as bytes. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">data</parametername>
</parameternamelist>
<parameterdescription>
<para>Pointer to memory where encoded arrays should be stored. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">data_siz</parametername>
</parameternamelist>
<parameterdescription>
<para>Integer size of data. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">ap</parametername>
</parameternamelist>
<parameterdescription>
<para>va_list Pointers to memory where column data is stored. The first argument in this set should be an integer, the number of rows in each column array. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int Number of bytes written. If larger than data_siz, the message will not be written to data and data should be resized first. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="574" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="574" bodyend="593"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1abb03c7592c2a72561831107582c3abb0" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_bytes_to_array</definition>
        <argsstring>(const asciiTable_t t, char *data, size_t data_siz,...)</argsstring>
        <name>at_bytes_to_array</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>char *</type>
          <declname>data</declname>
        </param>
        <param>
          <type>size_t</type>
          <declname>data_siz</declname>
        </param>
        <param>
          <type>...</type>
        </param>
        <briefdescription>
<para>Convert data into arrays for columns. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">data</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to memory containing data that should be parsed. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">data_siz</parametername>
</parameternamelist>
<parameterdescription>
<para>constant size_t Size of data in bytes. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">...</parametername>
</parameternamelist>
<parameterdescription>
<para>Pointers to pointers to memory where columns should be stored. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int Number of rows read on success, -1 on failure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="606" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="606" bodyend="612"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a8ea70b93e3bdcfe6c8f6861b023e60c1" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_array_to_bytes</definition>
        <argsstring>(const asciiTable_t t, char *data, const size_t data_siz,...)</argsstring>
        <name>at_array_to_bytes</name>
        <param>
          <type>const <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
          <declname>t</declname>
        </param>
        <param>
          <type>char *</type>
          <declname>data</declname>
        </param>
        <param>
          <type>const size_t</type>
          <declname>data_siz</declname>
        </param>
        <param>
          <type>...</type>
        </param>
        <briefdescription>
<para>Encode a set of arrays as bytes. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>constant <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="out">data</parametername>
</parameternamelist>
<parameterdescription>
<para>Pointer to memory where encoded arrays should be stored. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">data_siz</parametername>
</parameternamelist>
<parameterdescription>
<para>Integer size of data. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">...</parametername>
</parameternamelist>
<parameterdescription>
<para>Pointers to memory where column data is stored. The first argument in this set should be an integer, the number of rows in each column array. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int Number of bytes written. If larger than data_siz, the message will not be written to data and data should be resized first. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="626" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="626" bodyend="632"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a4334fe77589dbea1626482da3fa54abb" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>void</type>
        <definition>static void at_cleanup</definition>
        <argsstring>(asciiTable_t *t)</argsstring>
        <name>at_cleanup</name>
        <param>
          <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> *</type>
          <declname>t</declname>
        </param>
        <briefdescription>
<para>Deallocate and clean up <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> structure. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></parameterdescription>
</parameteritem>
</parameterlist>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="639" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="639" bodyend="646"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a634dcd21905d98fe7550716a06c6bf82" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type>int</type>
        <definition>static int at_update</definition>
        <argsstring>(asciiTable_t *t, const char *filepath, const char *io_mode)</argsstring>
        <name>at_update</name>
        <param>
          <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> *</type>
          <declname>t</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>filepath</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>io_mode</declname>
        </param>
        <briefdescription>
<para>Update an existing <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> structure. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">t</parametername>
</parameternamelist>
<parameterdescription>
<para>asciiTable_t* Address of table structure to update. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">filepath</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to file path. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">io_mode</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to I/O mode. &quot;r&quot; for read, &quot;w&quot; for write. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>int -1 if there is an error, 0 otherwise. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="657" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="657" bodyend="671"/>
      </memberdef>
      <memberdef kind="function" id="AsciiTable_8h_1a2cc033a42c5436c373793d378b806e9c" prot="public" static="yes" const="no" explicit="no" inline="yes" virt="non-virtual">
        <type><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref></type>
        <definition>static asciiTable_t asciiTable</definition>
        <argsstring>(const char *filepath, const char *io_mode, const char *format_str, const char *comment, const char *column, const char *newline)</argsstring>
        <name>asciiTable</name>
        <param>
          <type>const char *</type>
          <declname>filepath</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>io_mode</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>format_str</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>comment</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>column</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>newline</declname>
        </param>
        <briefdescription>
<para>Constructor for <ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> structure. </para>        </briefdescription>
        <detaileddescription>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername direction="in">filepath</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to file path. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">io_mode</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to I/O mode. &quot;r&quot; for read, &quot;w&quot; for write. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">format_str</parametername>
</parameternamelist>
<parameterdescription>
<para>constant character pointer to string describing the format of the table roads. Required for io_mode == &quot;w&quot;, but if set to NULL for io_mode == &quot;r&quot;, it will attempt to be read from the table. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">comment</parametername>
</parameternamelist>
<parameterdescription>
<para>const character pointer to character(s) that should indicate a comment. If NULL, comment is set to &quot;# &quot;. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">column</parametername>
</parameternamelist>
<parameterdescription>
<para>const character pointer to character(s) that should separate columns in the table. If NULL, column is set to &quot;\t&quot;. </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername direction="in">newline</parametername>
</parameternamelist>
<parameterdescription>
<para>const character pointer to character(s) that should indicate a newline. If NULL, newline is set to &quot;\n&quot;. </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref> table structure. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" line="690" column="1" bodyfile="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h" bodystart="690" bodyend="725"/>
      </memberdef>
      </sectiondef>
    <briefdescription>
    </briefdescription>
    <detaileddescription>
    </detaileddescription>
    <programlisting>
<codeline lineno="1"></codeline>
<codeline lineno="2"><highlight class="preprocessor">#ifndef<sp/>ASCIITABLE_H_</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="3"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>ASCIITABLE_H_</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="4"><highlight class="normal"></highlight></codeline>
<codeline lineno="5"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/>&lt;../tools.h&gt;</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="6"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/>&quot;AsciiFile.h&quot;</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="7"><highlight class="normal"></highlight></codeline>
<codeline lineno="8"><highlight class="normal"></highlight><highlight class="preprocessor">#ifdef<sp/>__cplusplus<sp/></highlight><highlight class="comment">/*<sp/>If<sp/>this<sp/>is<sp/>a<sp/>C++<sp/>compiler,<sp/>use<sp/>C<sp/>linkage<sp/>*/</highlight><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="9"><highlight class="normal"></highlight><highlight class="keyword">extern</highlight><highlight class="normal"><sp/></highlight><highlight class="stringliteral">&quot;C&quot;</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="10"><highlight class="normal"></highlight><highlight class="preprocessor">#endif</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="11"><highlight class="normal"></highlight></codeline>
<codeline lineno="12"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>FMT_LEN<sp/>100</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="13"><highlight class="normal"></highlight></codeline>
<codeline lineno="15"><highlight class="keyword">enum</highlight><highlight class="normal"><sp/>fmt_types<sp/>{<sp/>AT_STRING,<sp/>AT_FLOAT,<sp/>AT_DOUBLE,<sp/>AT_COMPLEX,</highlight></codeline>
<codeline lineno="16"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>AT_SHORTSHORT,<sp/>AT_SHORT,<sp/>AT_INT,<sp/>AT_LONG,<sp/>AT_LONGLONG,</highlight></codeline>
<codeline lineno="17"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>AT_USHORTSHORT,<sp/>AT_USHORT,<sp/>AT_UINT,<sp/>AT_ULONG,<sp/>AT_ULONGLONG<sp/>};</highlight></codeline>
<codeline lineno="18"><highlight class="normal"></highlight></codeline>
<codeline lineno="25"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="26"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>count_complex_formats(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>fmt_str)<sp/>{</highlight></codeline>
<codeline lineno="27"><highlight class="normal"><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<sp/>fmt_regex<sp/>=<sp/></highlight><highlight class="stringliteral">&quot;%([[:digit:]]+\\$)?[+-]?([<sp/>0]|\&apos;.{1})?-?[[:digit:]]*(\\.[[:digit:]]+)?[lhjztL]*[eEfFgG]&quot;</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="28"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="stringliteral">&quot;%([[:digit:]]+\\$)?[+-]([<sp/>0]|\&apos;.{1})?-?[[:digit:]]*(\\.[[:digit:]]+)?[lhjztL]*[eEfFgG]j&quot;</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="29"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>count_matches(fmt_regex,<sp/>fmt_str);</highlight></codeline>
<codeline lineno="30"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>printf(&quot;%d,<sp/>%s\n&quot;,<sp/>ret,<sp/>fmt_str);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="31"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="32"><highlight class="normal">};</highlight></codeline>
<codeline lineno="33"><highlight class="normal"></highlight></codeline>
<codeline lineno="42"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="43"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>count_formats(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>fmt_str)<sp/>{</highlight></codeline>
<codeline lineno="44"><highlight class="normal"><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<sp/>fmt_regex<sp/>=<sp/></highlight><highlight class="stringliteral">&quot;%([[:digit:]]+\\$)?[+-]?([<sp/>0]|\&apos;.{1})?-?[[:digit:]]*(\\.[[:digit:]]+)?[lhjztL]*(64)?[bcdeEufFgGosxX]&quot;</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="45"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>count_matches(fmt_regex,<sp/>fmt_str);</highlight></codeline>
<codeline lineno="46"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>printf(&quot;%d,<sp/>%s\n&quot;,<sp/>ret,<sp/>fmt_str);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="47"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="48"><highlight class="normal">};</highlight></codeline>
<codeline lineno="49"><highlight class="normal"></highlight></codeline>
<codeline lineno="58"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="59"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>simplify_formats(</highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*fmt_str,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>fmt_len)<sp/>{</highlight></codeline>
<codeline lineno="60"><highlight class="normal"><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<sp/>fmt_regex1<sp/>=<sp/></highlight><highlight class="stringliteral">&quot;%([[:digit:]]+\\$)?[+-]?([<sp/>0]|\&apos;.{1})?-?[[:digit:]]*(\\.[[:digit:]]+)?([lhjztL]*)([eEfFgG])&quot;</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="61"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>&quot;%([[:digit:]]+\\$)?[+-]?([<sp/>0]|\&apos;.{1})?-?[[:digit:]]*(\\.[[:digit:]]+)?([lhjztL]*)([eEfFgG])&quot;;</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="62"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>&quot;%([[:digit:]]+\\$)?[+-]?([<sp/>0]|&apos;.{1})?-?[[:digit:]]*(\\.[[:digit:]]+)?([lhjztL])*([eEfFgG])&quot;;</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="63"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>regex_replace_sub(fmt_str,<sp/>fmt_len,<sp/>fmt_regex1,</highlight></codeline>
<codeline lineno="64"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="stringliteral">&quot;%$4$5&quot;</highlight><highlight class="normal">,<sp/>0);</highlight></codeline>
<codeline lineno="65"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>&gt;<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="66"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<sp/>fmt_regex2<sp/>=<sp/></highlight><highlight class="stringliteral">&quot;%[lhjztL]*([fF])&quot;</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="67"><highlight class="normal"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>regex_replace_sub(fmt_str,<sp/>fmt_len,<sp/>fmt_regex2,</highlight></codeline>
<codeline lineno="68"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="stringliteral">&quot;%l$1&quot;</highlight><highlight class="normal">,<sp/>0);</highlight></codeline>
<codeline lineno="69"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="70"><highlight class="normal"></highlight><highlight class="comment">/*#ifdef<sp/>_WIN32</highlight></codeline>
<codeline lineno="71"><highlight class="comment"><sp/><sp/>if<sp/>(ret<sp/>&gt;<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="72"><highlight class="comment"><sp/><sp/><sp/><sp/>const<sp/>char<sp/>*<sp/>fmt_regex3<sp/>=<sp/>&quot;%l64([du])&quot;;</highlight></codeline>
<codeline lineno="73"><highlight class="comment"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>regex_replace_sub(fmt_str,<sp/>fmt_len,<sp/>fmt_regex3,<sp/>&quot;%l$1&quot;,<sp/>0);</highlight></codeline>
<codeline lineno="74"><highlight class="comment"><sp/><sp/>}</highlight></codeline>
<codeline lineno="75"><highlight class="comment">#endif*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="76"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="77"><highlight class="normal">};</highlight></codeline>
<codeline lineno="78"><highlight class="normal"></highlight></codeline>
<codeline lineno="80" refid="structasciiTable__t" refkind="compound"><highlight class="keyword">typedef</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>{</highlight></codeline>
<codeline lineno="81" refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" refkind="member"><highlight class="normal"><sp/><sp/><ref refid="structasciiFile__t" kindref="compound">asciiFile_t</ref><sp/><ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>;<sp/></highlight></codeline>
<codeline lineno="82" refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" refkind="member"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" kindref="member">format_str</ref>[LINE_SIZE_MAX];<sp/></highlight></codeline>
<codeline lineno="83" refid="structasciiTable__t_1a4c09956acb7a76e0431d9deb6f27be7e" refkind="member"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t_1a4c09956acb7a76e0431d9deb6f27be7e" kindref="member">column</ref>[64];<sp/></highlight></codeline>
<codeline lineno="84" refid="structasciiTable__t_1a837095bd2a245987e98f2bdd1fccaa94" refkind="member"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t_1a837095bd2a245987e98f2bdd1fccaa94" kindref="member">ncols</ref>;<sp/></highlight></codeline>
<codeline lineno="85" refid="structasciiTable__t_1aaa59065a52a15e3dd33c6e043941ed8b" refkind="member"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>*<ref refid="structasciiTable__t_1aaa59065a52a15e3dd33c6e043941ed8b" kindref="member">format_typ</ref>;<sp/></highlight></codeline>
<codeline lineno="86" refid="structasciiTable__t_1a807c3654eee6e0cedc1d8ce1d3e73b17" refkind="member"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>*<ref refid="structasciiTable__t_1a807c3654eee6e0cedc1d8ce1d3e73b17" kindref="member">format_siz</ref>;<sp/></highlight></codeline>
<codeline lineno="87" refid="structasciiTable__t_1aaa2f0c09c59e6b4cdad4e3845552da35" refkind="member"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t_1aaa2f0c09c59e6b4cdad4e3845552da35" kindref="member">row_siz</ref>;<sp/></highlight></codeline>
<codeline lineno="88" refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" refkind="member"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref>;<sp/></highlight></codeline>
<codeline lineno="89"><highlight class="normal">}<sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref>;</highlight></codeline>
<codeline lineno="90"><highlight class="normal"></highlight></codeline>
<codeline lineno="96"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="97"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_open(<ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>*t)<sp/>{</highlight></codeline>
<codeline lineno="98"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>af_open(&amp;((*t).f));</highlight></codeline>
<codeline lineno="99"><highlight class="normal">};</highlight></codeline>
<codeline lineno="100"><highlight class="normal"></highlight></codeline>
<codeline lineno="106"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="107"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>at_close(<ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>*t)<sp/>{</highlight></codeline>
<codeline lineno="108"><highlight class="normal"><sp/><sp/>af_close(&amp;((*t).f));</highlight></codeline>
<codeline lineno="109"><highlight class="normal">};</highlight></codeline>
<codeline lineno="110"><highlight class="normal"></highlight></codeline>
<codeline lineno="120"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="121"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_readline_full_realloc(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>**buf,</highlight></codeline>
<codeline lineno="122"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>len_buf,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>allow_realloc)<sp/>{</highlight></codeline>
<codeline lineno="123"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Read<sp/>lines<sp/>until<sp/>there&apos;s<sp/>one<sp/>that&apos;s<sp/>not<sp/>a<sp/>comment</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="124"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>0,<sp/>com<sp/>=<sp/>1;</highlight></codeline>
<codeline lineno="125"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>nread<sp/>=<sp/>LINE_SIZE_MAX;</highlight></codeline>
<codeline lineno="126"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*line<sp/>=<sp/>(</highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*)malloc(nread);</highlight></codeline>
<codeline lineno="127"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(line<sp/>==<sp/>NULL)<sp/>{</highlight></codeline>
<codeline lineno="128"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_readline_full_realloc:<sp/>Failed<sp/>to<sp/>malloc<sp/>line.&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="129"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="130"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="131"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>((ret<sp/>&gt;=<sp/>0)<sp/>&amp;&amp;<sp/>(com<sp/>==<sp/>1))<sp/>{</highlight></codeline>
<codeline lineno="132"><highlight class="normal"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>af_readline_full(t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>,<sp/>&amp;line,<sp/>&amp;nread);</highlight></codeline>
<codeline lineno="133"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>&lt;<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="134"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>free(line);</highlight></codeline>
<codeline lineno="135"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="136"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="137"><highlight class="normal"><sp/><sp/><sp/><sp/>com<sp/>=<sp/>af_is_comment(t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>,<sp/>line);</highlight></codeline>
<codeline lineno="138"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="139"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>&gt;<sp/>(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">)len_buf)<sp/>{</highlight></codeline>
<codeline lineno="140"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(allow_realloc)<sp/>{</highlight></codeline>
<codeline lineno="141"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>cislog_debug(</highlight><highlight class="stringliteral">&quot;at_readline_full_realloc:<sp/>reallocating<sp/>buffer<sp/>from<sp/>%d<sp/>to<sp/>%d<sp/>bytes.&quot;</highlight><highlight class="normal">,</highlight></codeline>
<codeline lineno="142"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">)len_buf,<sp/>ret<sp/>+<sp/>1);</highlight></codeline>
<codeline lineno="143"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*temp_buf<sp/>=<sp/>(</highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*)realloc(*buf,<sp/>ret<sp/>+<sp/>1);</highlight></codeline>
<codeline lineno="144"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(temp_buf<sp/>==<sp/>NULL)<sp/>{</highlight></codeline>
<codeline lineno="145"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_readline_full_realloc:<sp/>Failed<sp/>to<sp/>realloc<sp/>buffer.&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="146"><highlight class="normal"><sp/><sp/><sp/><sp/>free(*buf);</highlight></codeline>
<codeline lineno="147"><highlight class="normal"><sp/><sp/><sp/><sp/>free(line);</highlight></codeline>
<codeline lineno="148"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="149"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="150"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>*buf<sp/>=<sp/>temp_buf;</highlight></codeline>
<codeline lineno="151"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="152"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_readline_full_realloc:<sp/>line<sp/>(%d<sp/>bytes)<sp/>is<sp/>larger<sp/>than<sp/>destination<sp/>buffer<sp/>(%d<sp/>bytes)&quot;</highlight><highlight class="normal">,</highlight></codeline>
<codeline lineno="153"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>ret,<sp/>(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">)len_buf);</highlight></codeline>
<codeline lineno="154"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="155"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>free(line);</highlight></codeline>
<codeline lineno="156"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="157"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="158"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="159"><highlight class="normal"><sp/><sp/>strcpy(*buf,<sp/>line);</highlight></codeline>
<codeline lineno="160"><highlight class="normal"><sp/><sp/>free(line);</highlight></codeline>
<codeline lineno="161"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="162"><highlight class="normal">};</highlight></codeline>
<codeline lineno="163"><highlight class="normal"></highlight></codeline>
<codeline lineno="172"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="173"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_readline_full(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*buf,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>len_buf)<sp/>{</highlight></codeline>
<codeline lineno="174"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Read<sp/>but<sp/>don&apos;t<sp/>realloc<sp/>buf</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="175"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>at_readline_full_realloc(t,<sp/>&amp;buf,<sp/>len_buf,<sp/>0);</highlight></codeline>
<codeline lineno="176"><highlight class="normal">};</highlight></codeline>
<codeline lineno="177"><highlight class="normal"></highlight></codeline>
<codeline lineno="184"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="185"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_writeline_full(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>line)<sp/>{</highlight></codeline>
<codeline lineno="186"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="187"><highlight class="normal"><sp/><sp/>ret<sp/>=<sp/>af_writeline_full(t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>,<sp/>line);</highlight></codeline>
<codeline lineno="188"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="189"><highlight class="normal">};</highlight></codeline>
<codeline lineno="190"><highlight class="normal"></highlight></codeline>
<codeline lineno="199"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="200"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_vbytes_to_row(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>line,<sp/>va_list<sp/>ap)<sp/>{</highlight></codeline>
<codeline lineno="201"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Simplify<sp/>format<sp/>for<sp/>vsscanf</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="202"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>fmt[LINE_SIZE_MAX];</highlight></codeline>
<codeline lineno="203"><highlight class="normal"><sp/><sp/>strcpy(fmt,<sp/>t.<ref refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" kindref="member">format_str</ref>);</highlight></codeline>
<codeline lineno="204"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>sret<sp/>=<sp/>simplify_formats(fmt,<sp/>LINE_SIZE_MAX);</highlight></codeline>
<codeline lineno="205"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(sret<sp/>&lt;<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="206"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_debug(</highlight><highlight class="stringliteral">&quot;at_vbytes_to_row:<sp/>simplify_formats<sp/>returned<sp/>%d&quot;</highlight><highlight class="normal">,<sp/>sret);</highlight></codeline>
<codeline lineno="207"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="208"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="209"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Interpret<sp/>line</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="210"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>vsscanf(line,<sp/>fmt,<sp/>ap);</highlight></codeline>
<codeline lineno="211"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>!=<sp/>t.<ref refid="structasciiTable__t_1a837095bd2a245987e98f2bdd1fccaa94" kindref="member">ncols</ref>)<sp/>{</highlight></codeline>
<codeline lineno="212"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_vbytes_to_row:<sp/>%d<sp/>arguments<sp/>filled,<sp/>but<sp/>%d<sp/>were<sp/>expected&quot;</highlight><highlight class="normal">,</highlight></codeline>
<codeline lineno="213"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>sret,<sp/>t.<ref refid="structasciiTable__t_1a837095bd2a245987e98f2bdd1fccaa94" kindref="member">ncols</ref>);</highlight></codeline>
<codeline lineno="214"><highlight class="normal"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="215"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="216"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="217"><highlight class="normal">};</highlight></codeline>
<codeline lineno="218"><highlight class="normal"></highlight></codeline>
<codeline lineno="229"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="230"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_vrow_to_bytes(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*buf,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>buf_siz,<sp/>va_list<sp/>ap)<sp/>{</highlight></codeline>
<codeline lineno="231"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>vsnprintf(buf,<sp/>buf_siz,<sp/>t.<ref refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" kindref="member">format_str</ref>,<sp/>ap);</highlight></codeline>
<codeline lineno="232"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="233"><highlight class="normal">};</highlight></codeline>
<codeline lineno="234"><highlight class="normal"></highlight></codeline>
<codeline lineno="242"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="243"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_vreadline(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/>va_list<sp/>ap)<sp/>{</highlight></codeline>
<codeline lineno="244"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="245"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Read<sp/>lines<sp/>until<sp/>there&apos;s<sp/>one<sp/>that&apos;s<sp/>not<sp/>a<sp/>comment</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="246"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>nread<sp/>=<sp/>LINE_SIZE_MAX;</highlight></codeline>
<codeline lineno="247"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*line<sp/>=<sp/>(</highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*)malloc(nread);</highlight></codeline>
<codeline lineno="248"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(line<sp/>==<sp/>NULL)<sp/>{</highlight></codeline>
<codeline lineno="249"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_vreadline:<sp/>Failed<sp/>to<sp/>malloc<sp/>line.&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="250"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="251"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="252"><highlight class="normal"><sp/><sp/>ret<sp/>=<sp/>at_readline_full(t,<sp/>line,<sp/>nread);</highlight></codeline>
<codeline lineno="253"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>&lt;<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="254"><highlight class="normal"><sp/><sp/><sp/><sp/>free(line);</highlight></codeline>
<codeline lineno="255"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="256"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="257"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Parse<sp/>line</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="258"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>sret<sp/>=<sp/>at_vbytes_to_row(t,<sp/>line,<sp/>ap);</highlight></codeline>
<codeline lineno="259"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(sret<sp/>&lt;<sp/>0)</highlight></codeline>
<codeline lineno="260"><highlight class="normal"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="261"><highlight class="normal"><sp/><sp/>free(line);</highlight></codeline>
<codeline lineno="262"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="263"><highlight class="normal">};</highlight></codeline>
<codeline lineno="264"><highlight class="normal"></highlight></codeline>
<codeline lineno="272"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="273"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_vwriteline(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/>va_list<sp/>ap)<sp/>{</highlight></codeline>
<codeline lineno="274"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>vfprintf(t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>.<ref refid="structasciiFile__t_1a799e768ea6b00c3cdf49303950b015b6" kindref="member">fd</ref>,<sp/>t.<ref refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" kindref="member">format_str</ref>,<sp/>ap);</highlight></codeline>
<codeline lineno="275"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="276"><highlight class="normal">};</highlight></codeline>
<codeline lineno="277"><highlight class="normal"></highlight></codeline>
<codeline lineno="285"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="286"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_readline(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/>...)<sp/>{</highlight></codeline>
<codeline lineno="287"><highlight class="normal"><sp/><sp/>va_list<sp/>ap;</highlight></codeline>
<codeline lineno="288"><highlight class="normal"><sp/><sp/>va_start(ap,<sp/>t);<sp/></highlight><highlight class="comment">//<sp/>might<sp/>need<sp/>to<sp/>use<sp/>last<sp/>element<sp/>in<sp/>structure</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="289"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>at_vreadline(t,<sp/>ap);</highlight></codeline>
<codeline lineno="290"><highlight class="normal"><sp/><sp/>va_end(ap);</highlight></codeline>
<codeline lineno="291"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="292"><highlight class="normal">};</highlight></codeline>
<codeline lineno="293"><highlight class="normal"></highlight></codeline>
<codeline lineno="301"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="302"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_writeline(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/>...)<sp/>{</highlight></codeline>
<codeline lineno="303"><highlight class="normal"><sp/><sp/>va_list<sp/>ap;</highlight></codeline>
<codeline lineno="304"><highlight class="normal"><sp/><sp/>va_start(ap,<sp/>t);</highlight></codeline>
<codeline lineno="305"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>at_vwriteline(t,<sp/>ap);</highlight></codeline>
<codeline lineno="306"><highlight class="normal"><sp/><sp/>va_end(ap);</highlight></codeline>
<codeline lineno="307"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="308"><highlight class="normal">};</highlight></codeline>
<codeline lineno="309"><highlight class="normal"></highlight></codeline>
<codeline lineno="315"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="316"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_writeformat(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t)<sp/>{</highlight></codeline>
<codeline lineno="317"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="318"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(af_is_open(t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>)<sp/>==<sp/>1)<sp/>{</highlight></codeline>
<codeline lineno="319"><highlight class="normal"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>(int)fwrite(t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>.<ref refid="structasciiFile__t_1aa6b01ebf820bd2c7bc7003e7b0669092" kindref="member">comment</ref>,<sp/>1,<sp/>strlen(t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>.<ref refid="structasciiFile__t_1aa6b01ebf820bd2c7bc7003e7b0669092" kindref="member">comment</ref>),<sp/>t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>.<ref refid="structasciiFile__t_1a799e768ea6b00c3cdf49303950b015b6" kindref="member">fd</ref>);</highlight></codeline>
<codeline lineno="320"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>&lt;<sp/>0)</highlight></codeline>
<codeline lineno="321"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="322"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="323"><highlight class="normal"><sp/><sp/>ret<sp/>=<sp/>af_writeline_full(t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>,<sp/>t.<ref refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" kindref="member">format_str</ref>);</highlight></codeline>
<codeline lineno="324"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="325"><highlight class="normal">};</highlight></codeline>
<codeline lineno="326"><highlight class="normal"></highlight></codeline>
<codeline lineno="333"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="334"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_discover_format_str(<ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>*t)<sp/>{</highlight></codeline>
<codeline lineno="335"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>at_open(t);</highlight></codeline>
<codeline lineno="336"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>&lt;<sp/>0)</highlight></codeline>
<codeline lineno="337"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="338"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>nread<sp/>=<sp/>LINE_SIZE_MAX;</highlight></codeline>
<codeline lineno="339"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*line<sp/>=<sp/>(</highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*)malloc(nread);</highlight></codeline>
<codeline lineno="340"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(line<sp/>==<sp/>NULL)<sp/>{</highlight></codeline>
<codeline lineno="341"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_discover_format_str:<sp/>Failed<sp/>to<sp/>malloc<sp/>line.&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="342"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="343"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="344"><highlight class="normal"><sp/><sp/>ret<sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="345"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>(getline(&amp;line,<sp/>&amp;nread,<sp/>(*t).f.fd)<sp/>&gt;=<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="346"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(af_is_comment((*t).f,<sp/>line)<sp/>==<sp/>1)<sp/>{</highlight></codeline>
<codeline lineno="347"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(count_formats(line)<sp/>&gt;<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="348"><highlight class="normal"><sp/><sp/><sp/><sp/>strcpy((*t).format_str,<sp/>line<sp/>+<sp/>strlen((*t).f.comment));</highlight></codeline>
<codeline lineno="349"><highlight class="normal"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="350"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">break</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="351"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="352"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="353"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="354"><highlight class="normal"><sp/><sp/>at_close(t);</highlight></codeline>
<codeline lineno="355"><highlight class="normal"><sp/><sp/>free(line);</highlight></codeline>
<codeline lineno="356"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="357"><highlight class="normal">};</highlight></codeline>
<codeline lineno="358"><highlight class="normal"></highlight></codeline>
<codeline lineno="364"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="365"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_set_ncols(<ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>*t)<sp/>{</highlight></codeline>
<codeline lineno="366"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Assumes<sp/>that<sp/>format_str<sp/>already<sp/>done</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="367"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>count;</highlight></codeline>
<codeline lineno="368"><highlight class="normal"><sp/><sp/>count<sp/>=<sp/>count_formats((*t).format_str);</highlight></codeline>
<codeline lineno="369"><highlight class="normal"><sp/><sp/>(*t).ncols<sp/>=<sp/>count;</highlight></codeline>
<codeline lineno="370"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>count;</highlight></codeline>
<codeline lineno="371"><highlight class="normal">};</highlight></codeline>
<codeline lineno="372"><highlight class="normal"></highlight></codeline>
<codeline lineno="373"><highlight class="normal"></highlight></codeline>
<codeline lineno="379"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="380"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_set_format_siz(<ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>*t)<sp/>{</highlight></codeline>
<codeline lineno="381"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>(*t).format_siz<sp/>=<sp/>(int*)malloc((*t).ncols*sizeof(int));<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="382"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>i,<sp/>typ,<sp/>siz;</highlight></codeline>
<codeline lineno="383"><highlight class="normal"><sp/><sp/>(*t).row_siz<sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="384"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">for</highlight><highlight class="normal"><sp/>(i<sp/>=<sp/>0;<sp/>i<sp/>&lt;<sp/>(*t).ncols;<sp/>i++)<sp/>{</highlight></codeline>
<codeline lineno="385"><highlight class="normal"><sp/><sp/><sp/><sp/>typ<sp/>=<sp/>(*t).format_typ[i];</highlight></codeline>
<codeline lineno="386"><highlight class="normal"><sp/><sp/><sp/><sp/>siz<sp/>=<sp/>(*t).format_siz[i];</highlight></codeline>
<codeline lineno="387"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_STRING)<sp/>siz<sp/>=<sp/>(*t).format_siz[i];<sp/></highlight><highlight class="comment">//<sp/>TODO</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="388"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_FLOAT)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(float);</highlight></codeline>
<codeline lineno="389"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_DOUBLE)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(double);</highlight></codeline>
<codeline lineno="390"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_COMPLEX)<sp/>siz<sp/>=<sp/>2*</highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(double);</highlight></codeline>
<codeline lineno="391"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_SHORTSHORT)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(char);</highlight></codeline>
<codeline lineno="392"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_SHORT)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(short);</highlight></codeline>
<codeline lineno="393"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_LONGLONG)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keywordtype">long</highlight><highlight class="normal"><sp/>long);</highlight></codeline>
<codeline lineno="394"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_LONG)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(long);</highlight></codeline>
<codeline lineno="395"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_INT)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(int);</highlight></codeline>
<codeline lineno="396"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_USHORTSHORT)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keywordtype">unsigned</highlight><highlight class="normal"><sp/>char);</highlight></codeline>
<codeline lineno="397"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_USHORT)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keywordtype">unsigned</highlight><highlight class="normal"><sp/>short);</highlight></codeline>
<codeline lineno="398"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_ULONGLONG)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keywordtype">unsigned</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">long</highlight><highlight class="normal"><sp/>long);</highlight></codeline>
<codeline lineno="399"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_ULONG)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keywordtype">unsigned</highlight><highlight class="normal"><sp/>long);</highlight></codeline>
<codeline lineno="400"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(typ<sp/>==<sp/>AT_UINT)<sp/>siz<sp/>=<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keywordtype">unsigned</highlight><highlight class="normal"><sp/>int);</highlight></codeline>
<codeline lineno="401"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>siz<sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="402"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(siz<sp/>&lt;<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="403"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_set_format_siz:<sp/>Could<sp/>not<sp/>set<sp/>size<sp/>for<sp/>column<sp/>%d<sp/>with<sp/>type<sp/>%d&quot;</highlight><highlight class="normal">,<sp/>i,<sp/>typ);</highlight></codeline>
<codeline lineno="404"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="405"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="406"><highlight class="normal"><sp/><sp/><sp/><sp/>(*t).format_siz[i]<sp/>=<sp/>siz;</highlight></codeline>
<codeline lineno="407"><highlight class="normal"><sp/><sp/><sp/><sp/>(*t).row_siz<sp/>+=<sp/>siz;</highlight></codeline>
<codeline lineno="408"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//<sp/>printf(&quot;format_str<sp/>=<sp/>%s\n&quot;,<sp/>t-&gt;format_str);</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="409"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//<sp/>printf(&quot;col<sp/>%d/%d<sp/>siz<sp/>=<sp/>%d\n&quot;,<sp/>i,<sp/>(*t).ncols,<sp/>siz);</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="410"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="411"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>0;</highlight></codeline>
<codeline lineno="412"><highlight class="normal">}</highlight></codeline>
<codeline lineno="413"><highlight class="normal"></highlight></codeline>
<codeline lineno="420"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="421"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_set_format_typ(<ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>*t)<sp/>{</highlight></codeline>
<codeline lineno="422"><highlight class="normal"><sp/><sp/>(*t).format_typ<sp/>=<sp/>(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">*)malloc((*t).ncols*</highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">));</highlight></codeline>
<codeline lineno="423"><highlight class="normal"><sp/><sp/>(*t).format_siz<sp/>=<sp/>(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">*)malloc((*t).ncols*</highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">));</highlight></codeline>
<codeline lineno="424"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(((*t).format_typ<sp/>==<sp/>NULL)<sp/>||<sp/>((*t).format_siz<sp/>==<sp/>NULL))<sp/>{</highlight></codeline>
<codeline lineno="425"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_set_format_typ:<sp/>Failed<sp/>to<sp/>alloc<sp/>format_typ/format_siz&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="426"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="427"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="428"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>beg<sp/>=<sp/>0,<sp/>end;</highlight></codeline>
<codeline lineno="429"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>icol<sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="430"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>ifmt[FMT_LEN];</highlight></codeline>
<codeline lineno="431"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Initialize</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="432"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">for</highlight><highlight class="normal"><sp/>(icol<sp/>=<sp/>0;<sp/>icol<sp/>&lt;<sp/>(*t).ncols;<sp/>icol++)<sp/>{</highlight></codeline>
<codeline lineno="433"><highlight class="normal"><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="434"><highlight class="normal"><sp/><sp/><sp/><sp/>(*t).format_siz[icol]<sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="435"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="436"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Loop<sp/>over<sp/>string</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="437"><highlight class="normal"><sp/><sp/>icol<sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="438"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>mres;</highlight></codeline>
<codeline lineno="439"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>sind,<sp/>eind;</highlight></codeline>
<codeline lineno="440"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>re_fmt[FMT_LEN];</highlight></codeline>
<codeline lineno="441"><highlight class="normal"><sp/><sp/>sprintf(re_fmt,<sp/></highlight><highlight class="stringliteral">&quot;%%[^%s%s]+[%s%s]&quot;</highlight><highlight class="normal">,</highlight></codeline>
<codeline lineno="442"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).column,<sp/>(*t).f.newline,<sp/>(*t).column,<sp/>(*t).f.newline);</highlight></codeline>
<codeline lineno="443"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>(beg<sp/>&lt;<sp/>strlen((*t).format_str))<sp/>{</highlight></codeline>
<codeline lineno="444"><highlight class="normal"><sp/><sp/><sp/><sp/>mres<sp/>=<sp/>find_match(re_fmt,<sp/>(*t).format_str<sp/>+<sp/>beg,<sp/>&amp;sind,<sp/>&amp;eind);</highlight></codeline>
<codeline lineno="445"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(mres<sp/>&lt;<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="446"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_set_format_typ:<sp/>find_match<sp/>returned<sp/>%d&quot;</highlight><highlight class="normal">,<sp/>mres);</highlight></codeline>
<codeline lineno="447"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="448"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(mres<sp/>==<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="449"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>beg++;</highlight></codeline>
<codeline lineno="450"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">continue</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="451"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="452"><highlight class="normal"><sp/><sp/><sp/><sp/>beg<sp/>+=<sp/>sind;</highlight></codeline>
<codeline lineno="453"><highlight class="normal"><sp/><sp/><sp/><sp/>end<sp/>=<sp/>beg<sp/>+<sp/>(eind<sp/>-<sp/>sind);</highlight></codeline>
<codeline lineno="454"><highlight class="normal"><sp/><sp/><sp/><sp/>strncpy(ifmt,<sp/>&amp;((*t).format_str)[beg],<sp/>end-beg);</highlight></codeline>
<codeline lineno="455"><highlight class="normal"><sp/><sp/><sp/><sp/>ifmt[end-beg]<sp/>=<sp/></highlight><highlight class="charliteral">&apos;\0&apos;</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="456"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*s&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="457"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_STRING;</highlight></codeline>
<codeline lineno="458"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>mres<sp/>=<sp/>regex_replace_sub(ifmt,<sp/>FMT_LEN,</highlight></codeline>
<codeline lineno="459"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="stringliteral">&quot;%(\\.)?([[:digit:]]*)s(.*)&quot;</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">&quot;$2&quot;</highlight><highlight class="normal">,<sp/>0);</highlight></codeline>
<codeline lineno="460"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_siz[icol]<sp/>=<sp/>atoi(ifmt);</highlight></codeline>
<codeline lineno="461"><highlight class="normal"></highlight><highlight class="preprocessor">#ifdef<sp/>_WIN32</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="462"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;(%.*[fFeEgG]){2}j&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="463"><highlight class="normal"></highlight><highlight class="preprocessor">#else</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="464"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;(\%.*[fFeEgG]){2}j&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="465"><highlight class="normal"></highlight><highlight class="preprocessor">#endif</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="466"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_COMPLEX;<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="467"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_DOUBLE;</highlight></codeline>
<codeline lineno="468"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>icol++;</highlight></codeline>
<codeline lineno="469"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_DOUBLE;</highlight></codeline>
<codeline lineno="470"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*[fFeEgG]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="471"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_DOUBLE;</highlight></codeline>
<codeline lineno="472"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>}<sp/>else<sp/>if<sp/>(find_match(&quot;%.*l[fFeEgG]&quot;,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="473"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_DOUBLE;<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="474"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>}<sp/>else<sp/>if<sp/>(find_match(&quot;%.*[fFeEgG]&quot;,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="475"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_FLOAT;<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="476"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*hh[id]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="477"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_SHORTSHORT;</highlight></codeline>
<codeline lineno="478"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*h[id]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="479"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_SHORT;</highlight></codeline>
<codeline lineno="480"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*ll[id]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="481"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_LONGLONG;</highlight></codeline>
<codeline lineno="482"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*l64[id]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="483"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_LONGLONG;</highlight></codeline>
<codeline lineno="484"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*l[id]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="485"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_LONG;</highlight></codeline>
<codeline lineno="486"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*[id]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="487"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_INT;</highlight></codeline>
<codeline lineno="488"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*hh[uoxX]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="489"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_USHORTSHORT;</highlight></codeline>
<codeline lineno="490"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*h[uoxX]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="491"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_USHORT;</highlight></codeline>
<codeline lineno="492"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*ll[uoxX]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="493"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_ULONGLONG;</highlight></codeline>
<codeline lineno="494"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*l64[uoxX]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="495"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_ULONGLONG;</highlight></codeline>
<codeline lineno="496"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*l[uoxX]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="497"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_ULONG;</highlight></codeline>
<codeline lineno="498"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(find_match(</highlight><highlight class="stringliteral">&quot;%.*[uoxX]&quot;</highlight><highlight class="normal">,<sp/>ifmt,<sp/>&amp;sind,<sp/>&amp;eind))<sp/>{</highlight></codeline>
<codeline lineno="499"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>(*t).format_typ[icol]<sp/>=<sp/>AT_UINT;</highlight></codeline>
<codeline lineno="500"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="501"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_set_format_typ:<sp/>Could<sp/>not<sp/>parse<sp/>format<sp/>string:<sp/>%s&quot;</highlight><highlight class="normal">,<sp/>ifmt);</highlight></codeline>
<codeline lineno="502"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="503"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="504"><highlight class="normal"><sp/><sp/><sp/><sp/>beg<sp/>=<sp/>end;</highlight></codeline>
<codeline lineno="505"><highlight class="normal"><sp/><sp/><sp/><sp/>icol++;</highlight></codeline>
<codeline lineno="506"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="507"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>at_set_format_siz(t);</highlight></codeline>
<codeline lineno="508"><highlight class="normal">};</highlight></codeline>
<codeline lineno="509"><highlight class="normal"></highlight></codeline>
<codeline lineno="520"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="521"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_vbytes_to_array(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*data,</highlight></codeline>
<codeline lineno="522"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>data_siz,<sp/>va_list<sp/>ap)<sp/>{</highlight></codeline>
<codeline lineno="523"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>check<sp/>size<sp/>of<sp/>array</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="524"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>size_t<sp/>data_siz<sp/>=<sp/>strlen(data);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="525"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>((data_siz<sp/>%<sp/>t.<ref refid="structasciiTable__t_1aaa2f0c09c59e6b4cdad4e3845552da35" kindref="member">row_siz</ref>)<sp/>!=<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="526"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_vbytes_to_array:<sp/>Data:<sp/>%s&quot;</highlight><highlight class="normal">,<sp/>data);</highlight></codeline>
<codeline lineno="527"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_vbytes_to_array:<sp/>Data<sp/>size<sp/>(%d)<sp/>not<sp/>an<sp/>even<sp/>number<sp/>of<sp/>rows<sp/>(row<sp/>size<sp/>is<sp/>%d)&quot;</highlight><highlight class="normal">,</highlight></codeline>
<codeline lineno="528"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">)data_siz,<sp/>t.<ref refid="structasciiTable__t_1aaa2f0c09c59e6b4cdad4e3845552da35" kindref="member">row_siz</ref>);</highlight></codeline>
<codeline lineno="529"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="530"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="531"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Loop<sp/>through</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="532"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>nrows<sp/>=<sp/>(int)data_siz<sp/>/<sp/>t.<ref refid="structasciiTable__t_1aaa2f0c09c59e6b4cdad4e3845552da35" kindref="member">row_siz</ref>;</highlight></codeline>
<codeline lineno="533"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>cur_pos<sp/>=<sp/>0,<sp/>col_siz;</highlight></codeline>
<codeline lineno="534"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>i;</highlight></codeline>
<codeline lineno="535"><highlight class="normal"><sp/><sp/>for<sp/>(i<sp/>=<sp/>0;<sp/>i<sp/>&lt;<sp/>t.<ref refid="structasciiTable__t_1a837095bd2a245987e98f2bdd1fccaa94" kindref="member">ncols</ref>;<sp/>i++)<sp/>{</highlight></codeline>
<codeline lineno="536"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>**temp;</highlight></codeline>
<codeline lineno="537"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*t2;</highlight></codeline>
<codeline lineno="538"><highlight class="normal"><sp/><sp/><sp/><sp/>temp<sp/>=<sp/>va_arg(ap,<sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">**);</highlight></codeline>
<codeline lineno="539"><highlight class="normal"><sp/><sp/><sp/><sp/>col_siz<sp/>=<sp/>nrows*t.<ref refid="structasciiTable__t_1a807c3654eee6e0cedc1d8ce1d3e73b17" kindref="member">format_siz</ref>[i];</highlight></codeline>
<codeline lineno="540"><highlight class="normal"><sp/><sp/><sp/><sp/>t2<sp/>=<sp/>(</highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*)realloc(*temp,<sp/>col_siz);</highlight></codeline>
<codeline lineno="541"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(t2<sp/>==<sp/>NULL)<sp/>{</highlight></codeline>
<codeline lineno="542"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>cislog_error(</highlight><highlight class="stringliteral">&quot;at_vbytes_to_array:<sp/>Failed<sp/>to<sp/>realloc<sp/>temp<sp/>var.&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="543"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>free(*temp);</highlight></codeline>
<codeline lineno="544"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="545"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="546"><highlight class="normal"><sp/><sp/><sp/><sp/>*temp<sp/>=<sp/>t2;</highlight></codeline>
<codeline lineno="547"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//<sp/>C<sp/>order<sp/>memory</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="548"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>for<sp/>(int<sp/>j<sp/>=<sp/>0;<sp/>j<sp/>&lt;<sp/>nrows;<sp/>j++)<sp/>{<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="549"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/><sp/><sp/>memcpy(*temp<sp/>+<sp/>j*t.format_siz[i],<sp/>data<sp/>+<sp/>j*t.row_siz<sp/>+<sp/>cur_pos,<sp/>t.format_siz[i]);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="550"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>}<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="551"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>cur_pos<sp/>+=<sp/>t.format_siz[i];<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="552"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//<sp/>F<sp/>order<sp/>memory</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="553"><highlight class="normal"><sp/><sp/><sp/><sp/>memcpy(*temp,<sp/>data+cur_pos,<sp/>col_siz);</highlight></codeline>
<codeline lineno="554"><highlight class="normal"><sp/><sp/><sp/><sp/>cur_pos<sp/>+=<sp/>col_siz;</highlight></codeline>
<codeline lineno="555"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>printf(&quot;col<sp/>%d:<sp/>cur_pos<sp/>=<sp/>%d,<sp/>col_siz<sp/>=<sp/>%d,<sp/>data<sp/>=<sp/>%s,<sp/>raw_data<sp/>=<sp/>&quot;,<sp/>i,<sp/>cur_pos,<sp/>col_siz,<sp/>*temp);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="556"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>fwrite(*temp,<sp/>col_siz,<sp/>1,<sp/>stdout);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="557"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>printf(&quot;\n&quot;);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="558"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="559"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>nrows;</highlight></codeline>
<codeline lineno="560"><highlight class="normal">};</highlight></codeline>
<codeline lineno="561"><highlight class="normal"></highlight></codeline>
<codeline lineno="573"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="574"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_varray_to_bytes(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*data,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>data_siz,<sp/>va_list<sp/>ap)<sp/>{</highlight></codeline>
<codeline lineno="575"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>nrows<sp/>=<sp/>va_arg(ap,<sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="576"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>msg_siz<sp/>=<sp/>nrows*t.<ref refid="structasciiTable__t_1aaa2f0c09c59e6b4cdad4e3845552da35" kindref="member">row_siz</ref>;</highlight></codeline>
<codeline lineno="577"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(msg_siz<sp/>&gt;<sp/>(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">)data_siz)<sp/>{</highlight></codeline>
<codeline lineno="578"><highlight class="normal"><sp/><sp/><sp/><sp/>cislog_debug(</highlight><highlight class="stringliteral">&quot;at_varray_to_bytes:<sp/>Message<sp/>size<sp/>(%d<sp/>bytes)<sp/>will<sp/>exceed<sp/>allocated<sp/>buffer<sp/>(%d<sp/>bytes).&quot;</highlight><highlight class="normal">,</highlight></codeline>
<codeline lineno="579"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>msg_siz,<sp/>(</highlight><highlight class="keywordtype">int</highlight><highlight class="normal">)data_siz);</highlight></codeline>
<codeline lineno="580"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>msg_siz;</highlight></codeline>
<codeline lineno="581"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="582"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Loop<sp/>through</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="583"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>cur_pos<sp/>=<sp/>0,<sp/>col_siz;</highlight></codeline>
<codeline lineno="584"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*temp;</highlight></codeline>
<codeline lineno="585"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>i;</highlight></codeline>
<codeline lineno="586"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">for</highlight><highlight class="normal"><sp/>(i<sp/>=<sp/>0;<sp/>i<sp/>&lt;<sp/>t.<ref refid="structasciiTable__t_1a837095bd2a245987e98f2bdd1fccaa94" kindref="member">ncols</ref>;<sp/>i++)<sp/>{</highlight></codeline>
<codeline lineno="587"><highlight class="normal"><sp/><sp/><sp/><sp/>col_siz<sp/>=<sp/>nrows*t.<ref refid="structasciiTable__t_1a807c3654eee6e0cedc1d8ce1d3e73b17" kindref="member">format_siz</ref>[i];</highlight></codeline>
<codeline lineno="588"><highlight class="normal"><sp/><sp/><sp/><sp/>temp<sp/>=<sp/>va_arg(ap,<sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*);</highlight></codeline>
<codeline lineno="589"><highlight class="normal"><sp/><sp/><sp/><sp/>memcpy(data+cur_pos,<sp/>temp,<sp/>col_siz);</highlight></codeline>
<codeline lineno="590"><highlight class="normal"><sp/><sp/><sp/><sp/>cur_pos<sp/>+=<sp/>col_siz;</highlight></codeline>
<codeline lineno="591"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="592"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>cur_pos;</highlight></codeline>
<codeline lineno="593"><highlight class="normal">};</highlight></codeline>
<codeline lineno="594"><highlight class="normal"></highlight></codeline>
<codeline lineno="605"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="606"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_bytes_to_array(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*data,<sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>data_siz,<sp/>...)<sp/>{</highlight></codeline>
<codeline lineno="607"><highlight class="normal"><sp/><sp/>va_list<sp/>ap;</highlight></codeline>
<codeline lineno="608"><highlight class="normal"><sp/><sp/>va_start(ap,<sp/>data_siz);</highlight></codeline>
<codeline lineno="609"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>at_vbytes_to_array(t,<sp/>data,<sp/>data_siz,<sp/>ap);</highlight></codeline>
<codeline lineno="610"><highlight class="normal"><sp/><sp/>va_end(ap);</highlight></codeline>
<codeline lineno="611"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="612"><highlight class="normal">};</highlight></codeline>
<codeline lineno="613"><highlight class="normal"></highlight></codeline>
<codeline lineno="625"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="626"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_array_to_bytes(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t,<sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*data,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>data_siz,<sp/>...)<sp/>{</highlight></codeline>
<codeline lineno="627"><highlight class="normal"><sp/><sp/>va_list<sp/>ap;</highlight></codeline>
<codeline lineno="628"><highlight class="normal"><sp/><sp/>va_start(ap,<sp/>data_siz);</highlight></codeline>
<codeline lineno="629"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/>at_varray_to_bytes(t,<sp/>data,<sp/>data_siz,<sp/>ap);</highlight></codeline>
<codeline lineno="630"><highlight class="normal"><sp/><sp/>va_end(ap);</highlight></codeline>
<codeline lineno="631"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>ret;</highlight></codeline>
<codeline lineno="632"><highlight class="normal">};</highlight></codeline>
<codeline lineno="633"><highlight class="normal"></highlight></codeline>
<codeline lineno="638"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="639"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>at_cleanup(<ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>*t)<sp/>{</highlight></codeline>
<codeline lineno="640"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>((*t).format_typ)</highlight></codeline>
<codeline lineno="641"><highlight class="normal"><sp/><sp/><sp/><sp/>free((*t).format_typ);</highlight></codeline>
<codeline lineno="642"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>((*t).format_siz)</highlight></codeline>
<codeline lineno="643"><highlight class="normal"><sp/><sp/><sp/><sp/>free((*t).format_siz);</highlight></codeline>
<codeline lineno="644"><highlight class="normal"><sp/><sp/>(*t).format_typ<sp/>=<sp/>NULL;</highlight></codeline>
<codeline lineno="645"><highlight class="normal"><sp/><sp/>(*t).format_siz<sp/>=<sp/>NULL;</highlight></codeline>
<codeline lineno="646"><highlight class="normal">};</highlight></codeline>
<codeline lineno="647"><highlight class="normal"></highlight></codeline>
<codeline lineno="656"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="657"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>at_update(<ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>*t,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*filepath,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*io_mode)<sp/>{</highlight></codeline>
<codeline lineno="658"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>flag<sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="659"><highlight class="normal"><sp/><sp/>flag<sp/>=<sp/>af_update(&amp;(t-&gt;<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref>),<sp/>filepath,<sp/>io_mode);</highlight></codeline>
<codeline lineno="660"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(flag<sp/>==<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="661"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>((strlen(t-&gt;<ref refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" kindref="member">format_str</ref>)<sp/>==<sp/>0)<sp/>&amp;&amp;<sp/>(strcmp(io_mode,<sp/></highlight><highlight class="stringliteral">&quot;r&quot;</highlight><highlight class="normal">)<sp/>==<sp/>0))<sp/>{</highlight></codeline>
<codeline lineno="662"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>flag<sp/>=<sp/>at_discover_format_str(t);</highlight></codeline>
<codeline lineno="663"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(flag<sp/>&gt;=<sp/>0)</highlight></codeline>
<codeline lineno="664"><highlight class="normal"><sp/><sp/><sp/><sp/>flag<sp/>=<sp/>at_set_ncols(t);</highlight></codeline>
<codeline lineno="665"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(flag<sp/>&gt;=<sp/>0)</highlight></codeline>
<codeline lineno="666"><highlight class="normal"><sp/><sp/><sp/><sp/>flag<sp/>=<sp/>at_set_format_typ(t);</highlight></codeline>
<codeline lineno="667"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="668"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="669"><highlight class="normal"><sp/><sp/>t-&gt;<ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref><sp/>=<sp/>flag;</highlight></codeline>
<codeline lineno="670"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>flag;</highlight></codeline>
<codeline lineno="671"><highlight class="normal">};</highlight></codeline>
<codeline lineno="672"><highlight class="normal"></highlight></codeline>
<codeline lineno="689"><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">inline</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="690"><highlight class="normal"><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>asciiTable(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*filepath,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*io_mode,</highlight></codeline>
<codeline lineno="691"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*format_str,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*comment,</highlight></codeline>
<codeline lineno="692"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*column,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*newline)<sp/>{</highlight></codeline>
<codeline lineno="693"><highlight class="normal"><sp/><sp/><ref refid="structasciiTable__t" kindref="compound">asciiTable_t</ref><sp/>t;</highlight></codeline>
<codeline lineno="694"><highlight class="normal"><sp/><sp/>strcpy(t.<ref refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" kindref="member">format_str</ref>,<sp/></highlight><highlight class="stringliteral">&quot;\0&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="695"><highlight class="normal"><sp/><sp/>t.<ref refid="structasciiTable__t_1a837095bd2a245987e98f2bdd1fccaa94" kindref="member">ncols</ref><sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="696"><highlight class="normal"><sp/><sp/>t.<ref refid="structasciiTable__t_1aaa59065a52a15e3dd33c6e043941ed8b" kindref="member">format_typ</ref><sp/>=<sp/>NULL;</highlight></codeline>
<codeline lineno="697"><highlight class="normal"><sp/><sp/>t.<ref refid="structasciiTable__t_1a807c3654eee6e0cedc1d8ce1d3e73b17" kindref="member">format_siz</ref><sp/>=<sp/>NULL;</highlight></codeline>
<codeline lineno="698"><highlight class="normal"><sp/><sp/>t.<ref refid="structasciiTable__t_1aaa2f0c09c59e6b4cdad4e3845552da35" kindref="member">row_siz</ref><sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="699"><highlight class="normal"><sp/><sp/>t.<ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref><sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="700"><highlight class="normal"><sp/><sp/>t.<ref refid="structasciiTable__t_1a1e211c26164429dca7a616e6a8af64a6" kindref="member">f</ref><sp/>=<sp/>asciiFile(filepath,<sp/>io_mode,<sp/>comment,<sp/>newline);</highlight></codeline>
<codeline lineno="701"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Set<sp/>defaults<sp/>for<sp/>optional<sp/>parameters</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="702"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(column<sp/>==<sp/>NULL)</highlight></codeline>
<codeline lineno="703"><highlight class="normal"><sp/><sp/><sp/><sp/>strcpy(t.<ref refid="structasciiTable__t_1a4c09956acb7a76e0431d9deb6f27be7e" kindref="member">column</ref>,<sp/></highlight><highlight class="stringliteral">&quot;\t&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="704"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="705"><highlight class="normal"><sp/><sp/><sp/><sp/>strcpy(t.<ref refid="structasciiTable__t_1a4c09956acb7a76e0431d9deb6f27be7e" kindref="member">column</ref>,<sp/>column);</highlight></codeline>
<codeline lineno="706"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Guess<sp/>format<sp/>string<sp/>from<sp/>file</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="707"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(format_str<sp/>==<sp/>NULL)<sp/>{</highlight></codeline>
<codeline lineno="708"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(strcmp(io_mode,<sp/></highlight><highlight class="stringliteral">&quot;r&quot;</highlight><highlight class="normal">)<sp/>==<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="709"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>t.<ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref><sp/>=<sp/>at_discover_format_str(&amp;t);</highlight></codeline>
<codeline lineno="710"><highlight class="normal"><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="711"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>t.<ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref><sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="712"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="713"><highlight class="normal"><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="714"><highlight class="normal"><sp/><sp/><sp/><sp/>strcpy(t.<ref refid="structasciiTable__t_1a030a09e49d0cb900ae0e3f6103229d14" kindref="member">format_str</ref>,<sp/>format_str);</highlight></codeline>
<codeline lineno="715"><highlight class="normal"><sp/><sp/>}</highlight></codeline>
<codeline lineno="716"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>Get<sp/>number<sp/>of<sp/>columns<sp/>&amp;<sp/>types</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="717"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(t.<ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref><sp/>&gt;=<sp/>0)</highlight></codeline>
<codeline lineno="718"><highlight class="normal"><sp/><sp/><sp/><sp/>t.<ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref><sp/>=<sp/>at_set_ncols(&amp;t);</highlight></codeline>
<codeline lineno="719"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(t.<ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref><sp/>&gt;=<sp/>0)</highlight></codeline>
<codeline lineno="720"><highlight class="normal"><sp/><sp/><sp/><sp/>t.<ref refid="structasciiTable__t_1a3a1b4f901f6cad135a0600a22942c43b" kindref="member">status</ref><sp/>=<sp/>at_set_format_typ(&amp;t);</highlight></codeline>
<codeline lineno="721"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>printf(&quot;status<sp/>=<sp/>%d\n&quot;,<sp/>t.status);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="722"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>printf(&quot;format_str<sp/>=<sp/>%s\n&quot;,<sp/>t.format_str);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="723"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>printf(&quot;ncols<sp/>=<sp/>%d,<sp/>row_siz<sp/>=<sp/>%d\n&quot;,<sp/>t.ncols,<sp/>t.row_siz);<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="724"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>t;</highlight></codeline>
<codeline lineno="725"><highlight class="normal">};</highlight></codeline>
<codeline lineno="726"><highlight class="normal"></highlight></codeline>
<codeline lineno="727"><highlight class="normal"></highlight><highlight class="preprocessor">#ifdef<sp/>__cplusplus<sp/></highlight><highlight class="comment">/*<sp/>If<sp/>this<sp/>is<sp/>a<sp/>C++<sp/>compiler,<sp/>end<sp/>C<sp/>linkage<sp/>*/</highlight><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="728"><highlight class="normal">}</highlight></codeline>
<codeline lineno="729"><highlight class="normal"></highlight><highlight class="preprocessor">#endif</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="730"><highlight class="normal"></highlight></codeline>
<codeline lineno="731"><highlight class="normal"></highlight><highlight class="preprocessor">#endif<sp/></highlight><highlight class="comment">/*ASCIITABLE_H_*/</highlight><highlight class="preprocessor"></highlight></codeline>
    </programlisting>
    <location file="/root/cis_interface/cis_interface/cis_interface/dataio/AsciiTable.h"/>
  </compounddef>
</doxygen>
