169 lines
21 KiB
HTML
169 lines
21 KiB
HTML
<!-- HTML header for doxygen 1.8.8-->
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
<!-- For Mobile Devices -->
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta name="generator" content="Doxygen 1.8.12"/>
|
|
<script type="text/javascript" src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
|
|
<title>zeus: Zeus ewol micro-service interface: framework/atria-soft/zeus/zeus/File.hpp Source File</title>
|
|
<!--<link href="tabs.css" rel="stylesheet" type="text/css"/>-->
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
<link href="customdoxygen.css" rel="stylesheet" type="text/css"/>
|
|
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css">
|
|
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/js/bootstrap.min.js"></script>
|
|
<script type="text/javascript" src="doxy-boot.js"></script>
|
|
</head>
|
|
<body>
|
|
<nav class="navbar navbar-default navbar-fixed-top" role="navigation">
|
|
<div class="container">
|
|
<div class="navbar-header">
|
|
<a class="navbar-brand">zeus: Zeus ewol micro-service interface 0.4.0</a>
|
|
</div>
|
|
<div id="navbar" class="navbar-collapse collapse">
|
|
<ul class="nav navbar-nav">
|
|
<li><a href="index.html">Main Page</a></li>
|
|
<li><a href="pages.html">Related Pages</a></li>
|
|
<li><a href="namespaces.html">Namespaces</a></li>
|
|
<li><a href="annotated.html">Classes</a></li>
|
|
<li><a href="files.html">Files</a></li>
|
|
</ul>
|
|
<ul class="nav navbar-nav navbar-right">
|
|
<li class="dropdown">
|
|
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
|
|
Link-libs<span class="caret"></span>
|
|
</a>
|
|
<ul class="dropdown-menu">
|
|
<li><a href="http://HeeroYui.github.io/lutin">lutin</a></li>
|
|
<li><a href="http://atria-soft.github.io/ewol">ewol</a></li>
|
|
<li><a href="http://atria-soft.github.io/echrono">echrono</a></li>
|
|
<li><a href="http://atria-soft.github.io/etk">etk</a></li>
|
|
<li><a href="http://atria-soft.github.io/ejson">ejson</a></li>
|
|
<li><a href="http://atria-soft.github.io/exml">exml</a></li>
|
|
<li><a href="http://atria-soft.github.io/esvg">esvg</a></li>
|
|
<li><a href="http://atria-soft.github.io/egami">egami</a></li>
|
|
<li><a href="http://atria-soft.github.io/gale">gale</a></li>
|
|
<li><a href="http://atria-soft.github.io/ege">ege</a></li>
|
|
<li><a href="http://atria-soft.github.io/elog">elog</a></li>
|
|
<li><a href="http://atria-soft.github.io/ememory">ememory</a></li>
|
|
<li><a href="http://atria-soft.github.io/enet">enet</a></li>
|
|
<li><a href="http://atria-soft.github.io/eproperty">eproperty</a></li>
|
|
<li><a href="http://atria-soft.github.io/esignal">esignal</a></li>
|
|
<li><a href="http://atria-soft.github.io/etranslate">etranslate</a></li>
|
|
<li><a href="http://atria-soft.github.io/zeus">zeus</a></li>
|
|
<li><a href="http://musicdsp.github.io/audio-ess">audio-ess</a></li>
|
|
<li><a href="http://musicdsp.github.io/audio">audio</a></li>
|
|
<li><a href="http://musicdsp.github.io/audio-drain">audio-drain</a></li>
|
|
<li><a href="http://musicdsp.github.io/audio-orchestra">audio-orchestra</a></li>
|
|
<li><a href="http://musicdsp.github.io/audio-river">audio-river</a></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<div id="search-box" class="input-group">
|
|
<div class="input-group-btn">
|
|
<button aria-expanded="false" type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
|
|
<span class="glyphicon glyphicon-search"></span>
|
|
<span class="caret"></span>
|
|
</button>
|
|
<ul class="dropdown-menu">
|
|
<li><a href="#">All</a></li>
|
|
<li><a href="#">Classes</a></li>
|
|
<li><a href="#">Namespaces</a></li>
|
|
<li><a href="#">Files</a></li>
|
|
<li><a href="#">Functions</a></li>
|
|
<li><a href="#">Variables</a></li>
|
|
<li><a href="#">Typedefs</a></li>
|
|
<li><a href="#">Enumerations</a></li>
|
|
<li><a href="#">Enumerator</a></li>
|
|
<li><a href="#">Friends</a></li>
|
|
<li><a href="#">Macros</a></li>
|
|
<li><a href="#">Pages</a></li>
|
|
</ul>
|
|
</div>
|
|
<button id="search-close" type="button" class="close" aria-label="Close">
|
|
<span aria-hidden="true"></span>
|
|
</button>
|
|
<input id="search-field" class="form-control" accesskey="S" onkeydown="searchBox.OnSearchFieldChange(event);" placeholder="Search ..." type="text">
|
|
</div>
|
|
</div><!--/.nav-collapse -->
|
|
</div>
|
|
</nav>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div class="content" id="content">
|
|
<div class="container">
|
|
<div class="row">
|
|
<div class="col-sm-12 panel panel-default" style="padding-bottom: 15px;">
|
|
<div style="margin-bottom: 15px;margin-top: 60px;">
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.12 -->
|
|
<script type="text/javascript">
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
</script>
|
|
<script type="text/javascript" src="menudata.js"></script>
|
|
<script type="text/javascript" src="menu.js"></script>
|
|
<script type="text/javascript">
|
|
$(function() {
|
|
initMenu('',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
</script>
|
|
<div id="main-nav"></div>
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
<div id="nav-path" class="navpath">
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="dir_644e041c3a6521da7b27eba0e4eb2b95.html">framework</a></li><li class="navelem"><a class="el" href="dir_a094892b17be858f66bf3446bbb755c7.html">atria-soft</a></li><li class="navelem"><a class="el" href="dir_96d802beaf7bb3afdcf2656a2c8ec44e.html">zeus</a></li><li class="navelem"><a class="el" href="dir_645a2e7aebb6c78a7ec97ee8c38ef7e7.html">zeus</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="headertitle">
|
|
<div class="title">File.hpp</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<a href="_file_8hpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> </div><div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="preprocessor">#pragma once</span></div><div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="preprocessor">#include <<a class="codeRef" doxygen="/home/heero/dev/perso/out/doc/release/etk.tag:http://atria-soft.github.io/etk/" href="http://atria-soft.github.io/etk/types__8hpp.html">etk/types.hpp</a>></span></div><div class="line"><a name="l00008"></a><span class="lineno"> 8</span> </div><div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="keyword">namespace </span><a class="code" href="namespacezeus.html">zeus</a> {</div><div class="line"><a name="l00013"></a><span class="lineno"><a class="line" href="classzeus_1_1_file.html"> 13</a></span>  <span class="keyword">class </span><a class="code" href="classzeus_1_1_file.html">File</a> {</div><div class="line"><a name="l00014"></a><span class="lineno"> 14</span>  <span class="keyword">private</span>:</div><div class="line"><a name="l00015"></a><span class="lineno"> 15</span>  std::string m_mineType;</div><div class="line"><a name="l00016"></a><span class="lineno"> 16</span>  int32_t m_fileSize;</div><div class="line"><a name="l00017"></a><span class="lineno"> 17</span>  std::vector<uint8_t> m_data;</div><div class="line"><a name="l00018"></a><span class="lineno"> 18</span>  <span class="keyword">public</span>:</div><div class="line"><a name="l00022"></a><span class="lineno"> 22</span>  <a class="code" href="classzeus_1_1_file.html#a347f4ee8c48496ad6ccf4905098cc1a3">File</a>();</div><div class="line"><a name="l00027"></a><span class="lineno"> 27</span>  <a class="code" href="classzeus_1_1_file.html#a347f4ee8c48496ad6ccf4905098cc1a3">File</a>(<span class="keyword">const</span> std::string& _filename);</div><div class="line"><a name="l00034"></a><span class="lineno"> 34</span>  <a class="code" href="classzeus_1_1_file.html#a347f4ee8c48496ad6ccf4905098cc1a3">File</a>(<span class="keyword">const</span> std::string& _mineType, std::vector<uint8_t> _data, int32_t _fileSize = -1);</div><div class="line"><a name="l00040"></a><span class="lineno"> 40</span>  <a class="code" href="classzeus_1_1_file.html#a347f4ee8c48496ad6ccf4905098cc1a3">File</a>(<span class="keyword">const</span> std::string& _mineType, int32_t _size);</div><div class="line"><a name="l00045"></a><span class="lineno"><a class="line" href="classzeus_1_1_file.html#ab84dccb7817bb4c1024f6855f6c3299e"> 45</a></span>  int32_t <a class="code" href="classzeus_1_1_file.html#ab84dccb7817bb4c1024f6855f6c3299e">getTheoricFileSize</a>()<span class="keyword"> const </span>{</div><div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  <span class="keywordflow">return</span> m_fileSize;</div><div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  }</div><div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  <span class="keywordtype">void</span> <a class="code" href="classzeus_1_1_file.html#a8f033107c62f94e85c5bc41565a09557">storeIn</a>(<span class="keyword">const</span> std::string& _filename) <span class="keyword">const</span>;</div><div class="line"><a name="l00057"></a><span class="lineno"><a class="line" href="classzeus_1_1_file.html#a15f115334e4b61f115bad019b2d96f73"> 57</a></span>  <span class="keyword">const</span> std::string& <a class="code" href="classzeus_1_1_file.html#a15f115334e4b61f115bad019b2d96f73">getMineType</a>()<span class="keyword"> const </span>{</div><div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  <span class="keywordflow">return</span> m_mineType;</div><div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  }</div><div class="line"><a name="l00064"></a><span class="lineno"><a class="line" href="classzeus_1_1_file.html#a46b613bce19240b648d71258551cd4f9"> 64</a></span>  <span class="keywordtype">void</span> <a class="code" href="classzeus_1_1_file.html#a46b613bce19240b648d71258551cd4f9">setMineType</a>(<span class="keyword">const</span> std::string& _type) {</div><div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  m_mineType = _type;</div><div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  }</div><div class="line"><a name="l00071"></a><span class="lineno"><a class="line" href="classzeus_1_1_file.html#a6962ed7df661f54967d1a5261766c92a"> 71</a></span>  <span class="keywordtype">void</span> <a class="code" href="classzeus_1_1_file.html#a6962ed7df661f54967d1a5261766c92a">preSetDataSize</a>(uint64_t _size) {</div><div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  m_data.resize(_size, 0);</div><div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  }</div><div class="line"><a name="l00078"></a><span class="lineno"><a class="line" href="classzeus_1_1_file.html#a4d483918b8752d2b2b7cc63959fae575"> 78</a></span>  <span class="keyword">const</span> std::vector<uint8_t>& <a class="code" href="classzeus_1_1_file.html#a4d483918b8752d2b2b7cc63959fae575">getData</a>()<span class="keyword"> const </span>{</div><div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  <span class="keywordflow">return</span> m_data;</div><div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  }</div><div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  <span class="keywordtype">void</span> <a class="code" href="classzeus_1_1_file.html#afd274fe57fdd61d0573aa1433c1d5e58">setData</a>(uint64_t _offset, <span class="keyword">const</span> std::vector<uint8_t>& _data);</div><div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  <span class="keywordtype">void</span> <a class="code" href="classzeus_1_1_file.html#afd274fe57fdd61d0573aa1433c1d5e58">setData</a>(uint64_t _offset, <span class="keyword">const</span> uint8_t* _data, uint32_t _size);</div><div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  };</div><div class="line"><a name="l00099"></a><span class="lineno"><a class="line" href="classzeus_1_1_file_server.html"> 99</a></span>  <span class="keyword">class </span><a class="code" href="classzeus_1_1_file_server.html">FileServer</a> {</div><div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  <span class="keyword">private</span>:</div><div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  std::string m_name;</div><div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  <span class="keyword">public</span>:</div><div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  <a class="code" href="classzeus_1_1_file_server.html">FileServer</a>();</div><div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  <a class="code" href="classzeus_1_1_file_server.html">FileServer</a>(<span class="keyword">const</span> std::string& _filename);</div><div class="line"><a name="l00116"></a><span class="lineno"><a class="line" href="classzeus_1_1_file_server.html#a1f58455c19ade011e4c492906466d2a0"> 116</a></span>  <span class="keyword">const</span> std::string& <a class="code" href="classzeus_1_1_file_server.html#a1f58455c19ade011e4c492906466d2a0">getFileName</a>()<span class="keyword"> const </span>{</div><div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  <span class="keywordflow">return</span> m_name;</div><div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  }</div><div class="line"><a name="l00119"></a><span class="lineno"> 119</span>  };</div><div class="line"><a name="l00120"></a><span class="lineno"> 120</span> }</div><div class="line"><a name="l00121"></a><span class="lineno"> 121</span> </div><div class="ttc" id="classzeus_1_1_file_html_a15f115334e4b61f115bad019b2d96f73"><div class="ttname"><a href="classzeus_1_1_file.html#a15f115334e4b61f115bad019b2d96f73">zeus::File::getMineType</a></div><div class="ttdeci">const std::string & getMineType() const</div><div class="ttdoc">Get the mine type of the file. </div><div class="ttdef"><b>Definition:</b> File.hpp:57</div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_html_a4d483918b8752d2b2b7cc63959fae575"><div class="ttname"><a href="classzeus_1_1_file.html#a4d483918b8752d2b2b7cc63959fae575">zeus::File::getData</a></div><div class="ttdeci">const std::vector< uint8_t > & getData() const</div><div class="ttdoc">get a rérérence of the data </div><div class="ttdef"><b>Definition:</b> File.hpp:78</div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_server_html"><div class="ttname"><a href="classzeus_1_1_file_server.html">zeus::FileServer</a></div><div class="ttdoc">File server interface. </div><div class="ttdef"><b>Definition:</b> File.hpp:99</div></div>
|
|
<div class="ttc" id="types__8hpp_html"><div class="ttname"><a href="http://atria-soft.github.io/etk/types__8hpp.html">types.hpp</a></div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_html_ab84dccb7817bb4c1024f6855f6c3299e"><div class="ttname"><a href="classzeus_1_1_file.html#ab84dccb7817bb4c1024f6855f6c3299e">zeus::File::getTheoricFileSize</a></div><div class="ttdeci">int32_t getTheoricFileSize() const</div><div class="ttdoc">get the théoric file size </div><div class="ttdef"><b>Definition:</b> File.hpp:45</div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_html"><div class="ttname"><a href="classzeus_1_1_file.html">zeus::File</a></div><div class="ttdoc">File inetrface. </div><div class="ttdef"><b>Definition:</b> File.hpp:13</div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_html_a6962ed7df661f54967d1a5261766c92a"><div class="ttname"><a href="classzeus_1_1_file.html#a6962ed7df661f54967d1a5261766c92a">zeus::File::preSetDataSize</a></div><div class="ttdeci">void preSetDataSize(uint64_t _size)</div><div class="ttdoc">préallocate the data </div><div class="ttdef"><b>Definition:</b> File.hpp:71</div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_html_a347f4ee8c48496ad6ccf4905098cc1a3"><div class="ttname"><a href="classzeus_1_1_file.html#a347f4ee8c48496ad6ccf4905098cc1a3">zeus::File::File</a></div><div class="ttdeci">File()</div><div class="ttdoc">Contructor of an empty file. </div></div>
|
|
<div class="ttc" id="namespacezeus_html"><div class="ttname"><a href="namespacezeus.html">zeus</a></div><div class="ttdoc">Main zeus library namespace. </div><div class="ttdef"><b>Definition:</b> AbstractFunction.hpp:15</div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_server_html_a1f58455c19ade011e4c492906466d2a0"><div class="ttname"><a href="classzeus_1_1_file_server.html#a1f58455c19ade011e4c492906466d2a0">zeus::FileServer::getFileName</a></div><div class="ttdeci">const std::string & getFileName() const</div><div class="ttdoc">Get the filename registered. </div><div class="ttdef"><b>Definition:</b> File.hpp:116</div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_html_a46b613bce19240b648d71258551cd4f9"><div class="ttname"><a href="classzeus_1_1_file.html#a46b613bce19240b648d71258551cd4f9">zeus::File::setMineType</a></div><div class="ttdeci">void setMineType(const std::string &_type)</div><div class="ttdoc">Set the mine type of the file. </div><div class="ttdef"><b>Definition:</b> File.hpp:64</div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_html_a8f033107c62f94e85c5bc41565a09557"><div class="ttname"><a href="classzeus_1_1_file.html#a8f033107c62f94e85c5bc41565a09557">zeus::File::storeIn</a></div><div class="ttdeci">void storeIn(const std::string &_filename) const</div><div class="ttdoc">Store data in the specify file. </div></div>
|
|
<div class="ttc" id="classzeus_1_1_file_html_afd274fe57fdd61d0573aa1433c1d5e58"><div class="ttname"><a href="classzeus_1_1_file.html#afd274fe57fdd61d0573aa1433c1d5e58">zeus::File::setData</a></div><div class="ttdeci">void setData(uint64_t _offset, const std::vector< uint8_t > &_data)</div><div class="ttdoc">Set data on the buffer. </div></div>
|
|
</div><!-- fragment --></div><!-- contents -->
|
|
<!-- HTML footer for doxygen 1.8.8-->
|
|
<!-- start footer part -->
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated on Mon Oct 24 2016 15:35:54 for zeus: Zeus ewol micro-service interface by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.12
|
|
</small></address>
|
|
</body>
|
|
</html>
|