Location: PHPKode > projects > DIY Blog > diy-blog/lib/diy-framework/docs/diy-framework/controller/Controller.html
<?xml version="1.0" encoding="iso-8859-1"?>
<!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>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class Controller</title>
			<link rel="stylesheet" href="../../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			

<h2 class="class-name">Class Controller</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
													<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
						|											<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
                <p class="implements">
            Implements interfaces:
            <ul>
                <li><a href="../../diy-framework/controller/Singleton.html">Singleton</a></li>            </ul>
        </p>
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Controller handles HTTP requests, selects and executes appropriate resource. Afterwards sends out output generated by the View to the browser, and the execution halts: application waits for another request.</p>
<p class="description"><p>Implemented as a frontal controller: it is the only point of entry to the application.  It is an abstract class for sub-classing. An application Controller should extend the framework Controller and call the parent::process() to handle requests.</p></p>
	<ul class="tags">
				<li><span class="field">author:</span> Martynas Jusevicius &lt;<a href="mailto:hide@address.com">hide@address.com</a>&gt;</li>
				<li><span class="field">link:</span> <a href="http://www.xml.lt">http://www.xml.lt</a></li>
				<li><span class="field">abstract:</span> </li>
			</ul>
		<p class="notes">
			Located in <a class="field" href="_diy-framework---controller---Controller.class.php.html">/diy-framework/controller/Controller.class.php</a> (line <span class="field">13</span>)
		</p>
		
				
		<pre></pre>
	
			</div>
</div>



	<a name="sec-var-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Variable Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
						<span class="disabled">Vars</span> (<a href="#sec-vars">details</a>)
							| 
									<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
								</div>
		<div class="info-box-body">
			<div class="var-summary">
																																<div class="var-title">
					<span class="var-type">mixed</span>
					<a href="#$resource" title="details" class="var-name">$resource</a>
				</div>
																<div class="var-title">
					<span class="var-type">mixed</span>
					<a href="#$view" title="details" class="var-name">$view</a>
				</div>
											</div>
		</div>
	</div>

	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
																		<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
				 
				|
						<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
												<div class="method-definition">
					static 						<span class="method-result">void</span>
										<a href="#output" title="details" class="method-name">output</a>
											(<span class="var-type"><a href="../../diy-framework/controller/Response.html">Response</a></span>&nbsp;<span class="var-name">$response</span>)
									</div>
																
																				<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#process" title="details" class="method-name">process</a>
											(<span class="var-type"><a href="../../diy-framework/controller/Request.html">Request</a></span>&nbsp;<span class="var-name">$request</span>, <span class="var-type"><a href="../../diy-framework/controller/Response.html">Response</a></span>&nbsp;<span class="var-name">$response</span>, <span class="var-type"><a href="../../diy-framework/controller/ResourceMapping.html">ResourceMapping</a></span>&nbsp;<span class="var-name">$mapping</span>)
									</div>
								</div>
		</div>
	</div>		

	<a name="sec-vars"></a>
	<div class="info-box">
		<div class="info-box-title">Variables</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
										<a href="#sec-var-summary">Vars</a> (<span class="disabled">details</span>)
						
			
										| 
									<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
					</div>
		<div class="info-box-body">
			<a name="var$resource" id="$resource"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">mixed</span>
			<span class="var-name">$resource</span>
			 = <span class="var-default"> null</span>			(line <span class="line-number">15</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">access:</span> protected</li>
			</ul>
	
	
		
		

</div>
<a name="var$view" id="$view"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">mixed</span>
			<span class="var-name">$view</span>
			 = <span class="var-default"> null</span>			(line <span class="line-number">16</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
	<ul class="tags">
				<li><span class="field">access:</span> protected</li>
			</ul>
	
	
		
		

</div>

						
		</div>
	</div>
	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
															<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
																	<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>
<a name="methodoutput" id="output"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">static method output</span> (line <span class="line-number">60</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Sets HTTP response headers and writes out the buffer.</p>
	<ul class="tags">
				<li><span class="field">access:</span> protected</li>
			</ul>
	
	<div class="method-signature">
	    static
		<span class="method-result">void</span>
		<span class="method-name">
			output
		</span>
					(<span class="var-type"><a href="../../diy-framework/controller/Response.html">Response</a></span>&nbsp;<span class="var-name">$response</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"><a href="../../diy-framework/controller/Response.html">Response</a></span>
				<span class="var-name">$response</span><span class="var-description">: Response to write out and to send to the client</span>			</li>
				</ul>
		
			
	</div>

<a name="methodprocess" id="process"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">process</span> (line <span class="line-number">75</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Processes the HTTP Request. Finds an appropriate Resource, passes the control to it, and displays the resulting View.</p>
	<ul class="tags">
				<li><span class="field">access:</span> protected</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			process
		</span>
					(<span class="var-type"><a href="../../diy-framework/controller/Request.html">Request</a></span>&nbsp;<span class="var-name">$request</span>, <span class="var-type"><a href="../../diy-framework/controller/Response.html">Response</a></span>&nbsp;<span class="var-name">$response</span>, <span class="var-type"><a href="../../diy-framework/controller/ResourceMapping.html">ResourceMapping</a></span>&nbsp;<span class="var-name">$mapping</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"><a href="../../diy-framework/controller/Request.html">Request</a></span>
				<span class="var-name">$request</span><span class="var-description">: Request to process</span>			</li>
					<li>
				<span class="var-type"><a href="../../diy-framework/controller/Response.html">Response</a></span>
				<span class="var-name">$response</span><span class="var-description">: Response to process</span>			</li>
					<li>
				<span class="var-type"><a href="../../diy-framework/controller/ResourceMapping.html">ResourceMapping</a></span>
				<span class="var-name">$mapping</span>			</li>
				</ul>
		
			
	</div>
						
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Tue, 25 Sep 2007 11:17:19 +0200 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.3.2</a>
	</p>
	</div></body>
</html>
Return current item: DIY Blog