📄 httpsvc_8h-source.html
字号:
00231 <span class="comment">// then the following are used to build one</span><a name="l00232"></a><a class="code" href="structPHTTPServiceProcess_1_1Info.html#m15">00232</a> <span class="keyword">const</span> <span class="keywordtype">char</span> * <a class="code" href="structPHTTPServiceProcess_1_1Info.html#m15">gifFilename</a>; <span class="comment">// File name for the products GIF file</span><a name="l00233"></a><a class="code" href="structPHTTPServiceProcess_1_1Info.html#m16">00233</a> <span class="keywordtype">int</span> <a class="code" href="structPHTTPServiceProcess_1_1Info.html#m16">gifWidth</a>; <span class="comment">// Size of GIF image, if zero then none is used</span><a name="l00234"></a><a class="code" href="structPHTTPServiceProcess_1_1Info.html#m17">00234</a> <span class="keywordtype">int</span> <a class="code" href="structPHTTPServiceProcess_1_1Info.html#m17">gifHeight</a>; <span class="comment">// in the generated HTML.</span>00235 <a name="l00236"></a><a class="code" href="structPHTTPServiceProcess_1_1Info.html#m18">00236</a> <span class="keyword">const</span> <span class="keywordtype">char</span> * <a class="code" href="structPHTTPServiceProcess_1_1Info.html#m18">copyrightHolder</a>; <span class="comment">// Name of copyright holder</span><a name="l00237"></a><a class="code" href="structPHTTPServiceProcess_1_1Info.html#m19">00237</a> <span class="keyword">const</span> <span class="keywordtype">char</span> * <a class="code" href="structPHTTPServiceProcess_1_1Info.html#m19">copyrightHomePage</a>; <span class="comment">// Home page for copyright holder</span><a name="l00238"></a><a class="code" href="structPHTTPServiceProcess_1_1Info.html#m20">00238</a> <span class="keyword">const</span> <span class="keywordtype">char</span> * <a class="code" href="structPHTTPServiceProcess_1_1Info.html#m20">copyrightEmail</a>; <span class="comment">// E-Mail address for copyright holder</span>00239 };00240 00241 <a class="code" href="classPHTTPServiceProcess.html#a0">PHTTPServiceProcess</a>(<span class="keyword">const</span> Info & inf);00242 <a class="code" href="classPHTTPServiceProcess.html#a1">~PHTTPServiceProcess</a>();00243 00244 BOOL <a class="code" href="classPHTTPServiceProcess.html#a2">OnStart</a>();00245 <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#a3">OnStop</a>();00246 BOOL <a class="code" href="classPHTTPServiceProcess.html#a4">OnPause</a>();00247 <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#a5">OnContinue</a>();00248 <span class="keyword">const</span> <span class="keywordtype">char</span> * <a class="code" href="classPHTTPServiceProcess.html#a6">GetServiceDependencies</a>() <span class="keyword">const</span>;00249 00250 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#a7">OnConfigChanged</a>() = 0;00251 <span class="keyword">virtual</span> BOOL <a class="code" href="classPHTTPServiceProcess.html#a8">Initialise</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> * initMsg) = 0;00252 00253 BOOL <a class="code" href="classPHTTPServiceProcess.html#a9">ListenForHTTP</a>(00254 WORD port,00255 <a class="code" href="classPSocket.html#z369_0">PSocket::Reusability</a> reuse = <a class="code" href="classPSocket.html#z369_0s0">PSocket::CanReuseAddress</a>,00256 PINDEX stackSize = 0x400000257 );00258 BOOL <a class="code" href="classPHTTPServiceProcess.html#a9">ListenForHTTP</a>(00259 <a class="code" href="classPSocket.html">PSocket</a> * listener,00260 <a class="code" href="classPSocket.html#z369_0">PSocket::Reusability</a> reuse = <a class="code" href="classPSocket.html#z369_0s0">PSocket::CanReuseAddress</a>,00261 PINDEX stackSize = 0x400000262 );00263 00264 <span class="keyword">virtual</span> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#a11">GetPageGraphic</a>();00265 <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#a12">GetPageHeader</a>(<a class="code" href="classPHTML.html">PHTML</a> &);00266 <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#a12">GetPageHeader</a>(<a class="code" href="classPHTML.html">PHTML</a> &, <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> & title);00267 00268 <span class="keyword">virtual</span> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#a14">GetCopyrightText</a>();00269 <a name="l00270"></a><a class="code" href="classPHTTPServiceProcess.html#a15">00270</a> <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> & <a class="code" href="classPHTTPServiceProcess.html#a15">GetMacroKeyword</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n2">macroKeyword</a>; }<a name="l00271"></a><a class="code" href="classPHTTPServiceProcess.html#a16">00271</a> <span class="keyword">const</span> <a class="code" href="classPTime.html">PTime</a> & <a class="code" href="classPHTTPServiceProcess.html#a16">GetCompilationDate</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n7">compilationDate</a>; }<a name="l00272"></a><a class="code" href="classPHTTPServiceProcess.html#a17">00272</a> <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> & <a class="code" href="classPHTTPServiceProcess.html#a17">GetHomePage</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n8">manufacturersHomePage</a>; }<a name="l00273"></a><a class="code" href="classPHTTPServiceProcess.html#a18">00273</a> <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> & <a class="code" href="classPHTTPServiceProcess.html#a18">GetEMailAddress</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n9">manufacturersEmail</a>; }<a name="l00274"></a><a class="code" href="classPHTTPServiceProcess.html#a19">00274</a> <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> & <a class="code" href="classPHTTPServiceProcess.html#a19">GetProductName</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n10">productNameHTML</a>; }<a name="l00275"></a><a class="code" href="classPHTTPServiceProcess.html#a20">00275</a> <span class="keyword">const</span> <a class="code" href="structPTEACypher_1_1Key.html">PTEACypher::Key</a> & <a class="code" href="classPHTTPServiceProcess.html#a20">GetProductKey</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n3">productKey</a>; }<a name="l00276"></a><a class="code" href="classPHTTPServiceProcess.html#a21">00276</a> <span class="keyword">const</span> <a class="code" href="classPStringArray.html">PStringArray</a> & <a class="code" href="classPHTTPServiceProcess.html#a21">GetSecuredKeys</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n4">securedKeys</a>; }<a name="l00277"></a><a class="code" href="classPHTTPServiceProcess.html#a22">00277</a> <span class="keyword">const</span> <a class="code" href="structPTEACypher_1_1Key.html">PTEACypher::Key</a> & <a class="code" href="classPHTTPServiceProcess.html#a22">GetSignatureKey</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n5">signatureKey</a>; }<a name="l00278"></a><a class="code" href="classPHTTPServiceProcess.html#a23">00278</a> BOOL <a class="code" href="classPHTTPServiceProcess.html#a23">ShouldIgnoreSignatures</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classPHTTPServiceProcess.html#n6">ignoreSignatures</a>; }<a name="l00279"></a><a class="code" href="classPHTTPServiceProcess.html#a24">00279</a> <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#a24">SetIgnoreSignatures</a>(BOOL ig) { <a class="code" href="classPHTTPServiceProcess.html#n6">ignoreSignatures</a> = ig; }00280 00281 <span class="keyword">static</span> <a class="code" href="classPHTTPServiceProcess.html">PHTTPServiceProcess</a> & <a class="code" href="classPHTTPServiceProcess.html#d0">Current</a>();00282 00283 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#a25">AddRegisteredText</a>(<a class="code" href="classPHTML.html">PHTML</a> & html);00284 <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#a26">AddUnregisteredText</a>(<a class="code" href="classPHTML.html">PHTML</a> & html);00285 <span class="keyword">virtual</span> BOOL <a class="code" href="classPHTTPServiceProcess.html#a27">SubstituteEquivalSequence</a>(<a class="code" href="classPHTTPRequest.html">PHTTPRequest</a> & request, <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> &, <a class="code" href="classPString.html">PString</a> &);00286 <span class="keyword">virtual</span> <a class="code" href="classPHTTPServer.html">PHTTPServer</a> * <a class="code" href="classPHTTPServiceProcess.html#a28">CreateHTTPServer</a>(<a class="code" href="classPTCPSocket.html">PTCPSocket</a> & socket);00287 <span class="keyword">virtual</span> <a class="code" href="classPHTTPServer.html">PHTTPServer</a> * <a class="code" href="classPHTTPServiceProcess.html#a29">OnCreateHTTPServer</a>(<span class="keyword">const</span> <a class="code" href="classPHTTPSpace.html">PHTTPSpace</a> & urlSpace);00288 <a class="code" href="classPTCPSocket.html">PTCPSocket</a> * <a class="code" href="classPHTTPServiceProcess.html#a30">AcceptHTTP</a>();00289 BOOL <a class="code" href="classPHTTPServiceProcess.html#a31">ProcessHTTP</a>(<a class="code" href="classPTCPSocket.html">PTCPSocket</a> & socket);00290 00291 <span class="keyword">protected</span>:<a name="l00292"></a><a class="code" href="classPHTTPServiceProcess.html#n0">00292</a> <a class="code" href="classPSocket.html">PSocket</a> * <a class="code" href="classPHTTPServiceProcess.html#n0">httpListeningSocket</a>;<a name="l00293"></a><a class="code" href="classPHTTPServiceProcess.html#n1">00293</a> <a class="code" href="classPHTTPSpace.html">PHTTPSpace</a> <a class="code" href="classPHTTPServiceProcess.html#n1">httpNameSpace</a>;<a name="l00294"></a><a class="code" href="classPHTTPServiceProcess.html#n2">00294</a> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#n2">macroKeyword</a>;00295 <a name="l00296"></a><a class="code" href="classPHTTPServiceProcess.html#n3">00296</a> <a class="code" href="structPTEACypher_1_1Key.html">PTEACypher::Key</a> <a class="code" href="classPHTTPServiceProcess.html#n3">productKey</a>;<a name="l00297"></a><a class="code" href="classPHTTPServiceProcess.html#n4">00297</a> <a class="code" href="classPStringArray.html">PStringArray</a> <a class="code" href="classPHTTPServiceProcess.html#n4">securedKeys</a>;<a name="l00298"></a><a class="code" href="classPHTTPServiceProcess.html#n5">00298</a> <a class="code" href="structPTEACypher_1_1Key.html">PTEACypher::Key</a> <a class="code" href="classPHTTPServiceProcess.html#n5">signatureKey</a>;<a name="l00299"></a><a class="code" href="classPHTTPServiceProcess.html#n6">00299</a> BOOL <a class="code" href="classPHTTPServiceProcess.html#n6">ignoreSignatures</a>;00300 <a name="l00301"></a><a class="code" href="classPHTTPServiceProcess.html#n7">00301</a> <a class="code" href="classPTime.html">PTime</a> <a class="code" href="classPHTTPServiceProcess.html#n7">compilationDate</a>;<a name="l00302"></a><a class="code" href="classPHTTPServiceProcess.html#n8">00302</a> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#n8">manufacturersHomePage</a>;<a name="l00303"></a><a class="code" href="classPHTTPServiceProcess.html#n9">00303</a> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#n9">manufacturersEmail</a>;<a name="l00304"></a><a class="code" href="classPHTTPServiceProcess.html#n10">00304</a> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#n10">productNameHTML</a>;<a name="l00305"></a><a class="code" href="classPHTTPServiceProcess.html#n11">00305</a> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#n11">gifHTML</a>;<a name="l00306"></a><a class="code" href="classPHTTPServiceProcess.html#n12">00306</a> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#n12">copyrightHolder</a>;<a name="l00307"></a><a class="code" href="classPHTTPServiceProcess.html#n13">00307</a> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#n13">copyrightHomePage</a>;<a name="l00308"></a><a class="code" href="classPHTTPServiceProcess.html#n14">00308</a> <a class="code" href="classPString.html">PString</a> <a class="code" href="classPHTTPServiceProcess.html#n14">copyrightEmail</a>;00309 00310 <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#b0">ShutdownListener</a>();00311 <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#b1">BeginRestartSystem</a>();00312 <span class="keywordtype">void</span> <a class="code" href="classPHTTPServiceProcess.html#b2">CompleteRestartSystem</a>();00313 <a name="l00314"></a><a class="code" href="classPHTTPServiceProcess.html#n15">00314</a> <a class="code" href="classPThread.html">PThread</a> * <a class="code" href="classPHTTPServiceProcess.html#n15">restartThread</a>;00315 00316 <a class="code" href="classPHTTPServiceProcess.html#b3">PLIST</a>(ThreadList, <a class="code" href="classPHTTPServiceThread.html">PHTTPServiceThread</a>);<a name="l00317"></a><a class="code" href="classPHTTPServiceProcess.html#n16">00317</a> ThreadList <a class="code" href="classPHTTPServiceProcess.html#n16">httpThreads</a>;<a name="l00318"></a><a class="code" href="classPHTTPServiceProcess.html#n17">00318</a> <a class="code" href="classPMutex.html">PMutex</a> <a class="code" href="classPHTTPServiceProcess.html#n17">httpThreadsMutex</a>;00319 <a name="l00320"></a><a class="code" href="classPHTTPServiceProcess.html#l0">00320</a> <span class="keyword">friend</span> <span class="keyword">class </span><a class="code" href="classPConfigPage.html">PConfigPage</a>;<a name="l00321"></a><a class="code" href="classPHTTPServiceProcess.html#l1">00321</a> <span class="keyword">friend</span> <span class="keyword">class </span><a class="code" href="classPConfigSectionsPage.html">PConfigSectionsPage</a>;<a name="l00322"></a><a class="code" href="classPHTTPServiceProcess.html#l2">00322</a> <span class="keyword">friend</span> <span class="keyword">class </span><a class="code" href="classPHTTPServiceThread.html">PHTTPServiceThread</a>;00323 };00324 00325 00327 <a name="l00328"></a><a class="code" href="classPConfigPage.html">00328</a> <span class="keyword">class </span><a class="code" href="classPConfigPage.html">PConfigPage</a> : <span class="keyword">public</span> <a class="code" href="classPHTTPConfig.html">PHTTPConfig</a>00329 {00330 <a class="code" href="object_8h.html#a27">PCLASSINFO</a>(<a class="code" href="classPConfigPage.html">PConfigPage</a>, <a class="code" href="classPHTTPConfig.html">PHTTPConfig</a>)00331 <span class="keyword">public</span>:00332 <a class="code" href="classPConfigPage.html#a0">PConfigPage</a>(00333 <a class="code" href="classPHTTPServiceProcess.html">PHTTPServiceProcess</a> & app,00334 <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> & <a class="code" href="classPHTTPConfig.html#n0">section</a>,00335 <span class="keyword">const</span> <a class="code" href="classPHTTPAuthority.html">PHTTPAuthority</a> & auth00336 );00337 <a class="code" href="classPConfigPage.html#a0">PConfigPage</a>(00338 <a class="code" href="classPHTTPServiceProcess.html">PHTTPServiceProcess</a> & app,00339 <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> & title,00340 <span class="keyword">const</span> <a class="code" href="classPString.html">PString</a> & section,00341 <span class="keyword">const</span> <a class="code" href="classPHTTPAuthority.html">PHTTPAuthority</a> & auth00342 );00343 00344 <span class="keywordtype">void</span> <a class="code" href="classPConfigPage.html#a2">OnLoadedText</a>(<a class="code" href="classPHTTPRequest.html">PHTTPRequest</a> &, <a class="code" href="classPString.html">PString</a> & text);00345 00346 BOOL <a class="code" href="classPConfigPage.html#a3">OnPOST</a>(00347 <a class="code" href="classPHTTPServer.html">PHTTPServer</a> & server,00348 <span class="keyword">const</span> <a class="code" href="classPURL.html">PURL</a> & url,00349 <span class="keyword">const</span> <a class="code" href="classPMIMEInfo.html">PMIMEInfo</a> & info,
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -