You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
114 lines
11 KiB
114 lines
11 KiB
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
|
<meta name="generator" content="Doxygen 1.9.7"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>Webserv: includes/Server.hpp Source File</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<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" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr id="projectrow">
|
|
<td id="projectalign">
|
|
<div id="projectname">Webserv
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.9.7 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="menudata.js"></script>
|
|
<script type="text/javascript" src="menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
$(function() {
|
|
initMenu('',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
/* @license-end */
|
|
</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">
|
|
<div id="MSearchResults">
|
|
<div class="SRPage">
|
|
<div id="SRIndex">
|
|
<div id="SRResults"></div>
|
|
<div class="SRStatus" id="Loading">Loading...</div>
|
|
<div class="SRStatus" id="Searching">Searching...</div>
|
|
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="nav-path" class="navpath">
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="dir_09e761304027c904456130627fd4dcf5.html">includes</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="headertitle"><div class="title">Server.hpp</div></div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<a href="Server_8hpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="preprocessor">#pragma once</span></div>
|
|
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="preprocessor">#include "<a class="code" href="webserv_8hpp.html">webserv.hpp</a>"</span></div>
|
|
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span> </div>
|
|
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"><a class="line" href="classServer.html"> 4</a></span><span class="keyword">class </span><a class="code hl_class" href="classServer.html">Server</a> : <span class="keyword">public</span> <a class="code hl_class" href="classRoute.html">Route</a> {</div>
|
|
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"><a class="line" href="classServer.html#a95c77245a1a0a9fd09926fc8e9661ebe"> 5</a></span> <span class="keywordtype">string</span> <a class="code hl_variable" href="classServer.html#a95c77245a1a0a9fd09926fc8e9661ebe">_name</a>; </div>
|
|
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"><a class="line" href="classServer.html#aebc8d22ef79e648de88441c37fb1db46"> 6</a></span> std::map<string, Route *> <a class="code hl_variable" href="classServer.html#aebc8d22ef79e648de88441c37fb1db46">_routes</a>; </div>
|
|
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span> </div>
|
|
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span><span class="keyword">public</span>:</div>
|
|
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"><a class="line" href="classServer.html#a6fecdbd597c344d2ae004ff72fdbef74"> 9</a></span> std::vector<ip_port_t> <a class="code hl_variable" href="classServer.html#a6fecdbd597c344d2ae004ff72fdbef74">_listens</a>; </div>
|
|
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span> <a class="code hl_class" href="classServer.html">Server</a>(<a class="code hl_class" href="classJSONNode.html">JSONNode</a> *server);</div>
|
|
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span> <a class="code hl_function" href="classServer.html#a803b89b673283131d2ae765c82923f8d">~Server</a>(<span class="keywordtype">void</span>);</div>
|
|
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> <a class="code hl_class" href="classMaster.html">Master</a> *<a class="code hl_function" href="classServer.html#a6c46d7b86956f508b1c0bfe125b03993">create_master</a>(<span class="keywordtype">string</span> str);</div>
|
|
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> std::vector<Master *> <a class="code hl_function" href="classServer.html#a5738134631f6bab9a26ca0687d86f21f">get_sockets</a>(<a class="code hl_class" href="classJSONNode.html">JSONNode</a> *server);</div>
|
|
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> <a class="code hl_class" href="classRoute.html">Route</a> *<a class="code hl_function" href="classServer.html#a0664c62a66a7e3e41d48c286c55a90a9">choose_route</a>(<span class="keywordtype">string</span> uri);</div>
|
|
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> <span class="keywordtype">string</span> <a class="code hl_function" href="classServer.html#ab957b5aafbabdc8f108cf68bfb5968c9">getName</a>(<span class="keywordtype">void</span>);</div>
|
|
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span>};</div>
|
|
<div class="ttc" id="aclassJSONNode_html"><div class="ttname"><a href="classJSONNode.html">JSONNode</a></div><div class="ttdef"><b>Definition:</b> <a href="Nodes_8hpp_source.html#l00004">Nodes.hpp:4</a></div></div>
|
|
<div class="ttc" id="aclassMaster_html"><div class="ttname"><a href="classMaster.html">Master</a></div><div class="ttdef"><b>Definition:</b> <a href="Master_8hpp_source.html#l00004">Master.hpp:4</a></div></div>
|
|
<div class="ttc" id="aclassRoute_html"><div class="ttname"><a href="classRoute.html">Route</a></div><div class="ttdef"><b>Definition:</b> <a href="Route_8hpp_source.html#l00004">Route.hpp:4</a></div></div>
|
|
<div class="ttc" id="aclassServer_html"><div class="ttname"><a href="classServer.html">Server</a></div><div class="ttdef"><b>Definition:</b> <a href="Server_8hpp_source.html#l00004">Server.hpp:4</a></div></div>
|
|
<div class="ttc" id="aclassServer_html_a0664c62a66a7e3e41d48c286c55a90a9"><div class="ttname"><a href="classServer.html#a0664c62a66a7e3e41d48c286c55a90a9">Server::choose_route</a></div><div class="ttdeci">Route * choose_route(string uri)</div><div class="ttdoc">Choose the route an uri asked to the server.</div><div class="ttdef"><b>Definition:</b> <a href="Server_8cpp_source.html#l00102">Server.cpp:102</a></div></div>
|
|
<div class="ttc" id="aclassServer_html_a5738134631f6bab9a26ca0687d86f21f"><div class="ttname"><a href="classServer.html#a5738134631f6bab9a26ca0687d86f21f">Server::get_sockets</a></div><div class="ttdeci">std::vector< Master * > get_sockets(JSONNode *server)</div><div class="ttdoc">Create server's defined sockets:</div><div class="ttdef"><b>Definition:</b> <a href="Server_8cpp_source.html#l00079">Server.cpp:79</a></div></div>
|
|
<div class="ttc" id="aclassServer_html_a6c46d7b86956f508b1c0bfe125b03993"><div class="ttname"><a href="classServer.html#a6c46d7b86956f508b1c0bfe125b03993">Server::create_master</a></div><div class="ttdeci">Master * create_master(string str)</div><div class="ttdoc">Master socket safe creation.</div><div class="ttdef"><b>Definition:</b> <a href="Server_8cpp_source.html#l00056">Server.cpp:56</a></div></div>
|
|
<div class="ttc" id="aclassServer_html_a6fecdbd597c344d2ae004ff72fdbef74"><div class="ttname"><a href="classServer.html#a6fecdbd597c344d2ae004ff72fdbef74">Server::_listens</a></div><div class="ttdeci">std::vector< ip_port_t > _listens</div><div class="ttdoc">The list of listens the server which are linked to the server.</div><div class="ttdef"><b>Definition:</b> <a href="Server_8hpp_source.html#l00009">Server.hpp:9</a></div></div>
|
|
<div class="ttc" id="aclassServer_html_a803b89b673283131d2ae765c82923f8d"><div class="ttname"><a href="classServer.html#a803b89b673283131d2ae765c82923f8d">Server::~Server</a></div><div class="ttdeci">~Server(void)</div><div class="ttdoc">Destructor.</div><div class="ttdef"><b>Definition:</b> <a href="Server_8cpp_source.html#l00038">Server.cpp:38</a></div></div>
|
|
<div class="ttc" id="aclassServer_html_a95c77245a1a0a9fd09926fc8e9661ebe"><div class="ttname"><a href="classServer.html#a95c77245a1a0a9fd09926fc8e9661ebe">Server::_name</a></div><div class="ttdeci">string _name</div><div class="ttdoc">The server name.</div><div class="ttdef"><b>Definition:</b> <a href="Server_8hpp_source.html#l00005">Server.hpp:5</a></div></div>
|
|
<div class="ttc" id="aclassServer_html_ab957b5aafbabdc8f108cf68bfb5968c9"><div class="ttname"><a href="classServer.html#ab957b5aafbabdc8f108cf68bfb5968c9">Server::getName</a></div><div class="ttdeci">string getName(void)</div><div class="ttdef"><b>Definition:</b> <a href="Server_8cpp_source.html#l00047">Server.cpp:47</a></div></div>
|
|
<div class="ttc" id="aclassServer_html_aebc8d22ef79e648de88441c37fb1db46"><div class="ttname"><a href="classServer.html#aebc8d22ef79e648de88441c37fb1db46">Server::_routes</a></div><div class="ttdeci">std::map< string, Route * > _routes</div><div class="ttdoc">The server's routings with a route object as object and his location as key.</div><div class="ttdef"><b>Definition:</b> <a href="Server_8hpp_source.html#l00006">Server.hpp:6</a></div></div>
|
|
<div class="ttc" id="awebserv_8hpp_html"><div class="ttname"><a href="webserv_8hpp.html">webserv.hpp</a></div></div>
|
|
</div><!-- fragment --></div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.7
|
|
</small></address>
|
|
</body>
|
|
</html>
|
|
|