<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">

	<title>SIKIServiceEvents Protocol Reference</title>

	<link rel="stylesheet" href="../css/style.css">
	<meta name="viewport" content="initial-scale=1, maximum-scale=1.4">
	<meta name="generator" content="appledoc 2.2.1 (build 1333)">
</head>
<body class="appledoc">
	<header>
		<div class="container" class="hide-in-xcode">
			
			<h1 id="library-title">
				<a href="../index.html">Connect </a>
			</h1>

			<p id="developer-home">
				<a href="../index.html">Siminov Software Solution LLP</a>
			</p>
			
		</div>
	</header>

	<aside>
		<div class="container">
			<nav>
				<ul id="header-buttons" role="toolbar">
					<li><a href="../index.html">Index</a></li>
<li><a href="../hierarchy.html">Hierarchy</a></li>

					<li id="on-this-page" role="navigation">
						<label>
							On This Page

							<div class="chevron">
								<div class="chevy chevron-left"></div>
								<div class="chevy chevron-right"></div>
							</div>

							<select id="jump-to">
	<option value="top">Jump To&#133;</option>
	
	<option value="overview">Overview</option>
	

	
	
	<option value="tasks">Tasks</option>
	
	

	
	

	

	
	<optgroup label="Instance Methods">
		
		<option value="//api/name/onFinish">- onFinish</option>
		
		<option value="//api/name/onPause">- onPause</option>
		
		<option value="//api/name/onQueue">- onQueue</option>
		
		<option value="//api/name/onRequestFinish:">- onRequestFinish:</option>
		
		<option value="//api/name/onRequestInvoke:">- onRequestInvoke:</option>
		
		<option value="//api/name/onResume">- onResume</option>
		
		<option value="//api/name/onStart">- onStart</option>
		
		<option value="//api/name/onTerminate:">- onTerminate:</option>
		
	</optgroup>
	
	
</select>
						</label>
					</li>
				</ul>
			</nav>
		</div>
	</aside>

	<article>
		<div id="overview_contents" class="container">
			<div id="content">
				<main role="main">
					<h1 class="title">SIKIServiceEvents Protocol Reference</h1>

					
					<div class="section section-specification"><table cellspacing="0"><tbody>
						<tr>
	<th>Conforms to</th>
	<td>NSObject</td>
</tr><tr>
	<th>Declared in</th>
	<td>SIKIServiceEvents.h</td>
</tr>
						</tbody></table></div>
					

                    
					
					<div class="section section-overview">
						<a title="Overview" name="overview"></a>
						<h2 class="subtitle subtitle-overview">Overview</h2>
						<p>It exposes APIs to handle service events</p>
					</div>
					
					

					
					
					<div class="section section-tasks">
						<a title="Tasks" name="tasks"></a>
						

						
						

						<div class="task-list">
							<div class="section-method">
	<a name="//api/name/onStart" title="onStart"></a>
	<h3 class="method-title"><code><a href="#//api/name/onStart">&ndash;&nbsp;onStart</a></code>
<span class="task-item-suffix">required method</span></h3>

	<div class="method-info">
		<div class="pointy-thing"></div>

		<div class="method-info-container">
			
			
			<div class="method-subsection brief-description">
				<p>This is the first method to be called when a service is created.</p>
			</div>
			
		    

			<div class="method-subsection method-declaration"><code>- (void)onStart</code></div>

		    
			

			

			

			
			<div class="method-subsection discussion-section">
				<h4 class="method-subtitle">Discussion</h4>
				<p>This is the first method to be called when a service is created.</p>

<p><p>
OnStart is always overridden to perform any startup initializations that may be required by a Service such as:</p>

<p><p>
<ui>
<li> Initializing variables
<li> Binding static data to service
<li> Binding related screen to service
</ui>
<p>
Once OnStart has finished, Connect will call OnServiceQueue if Service is in ASYNC mode else OnServiceApiInvoke.
*</p>
			</div>
			

			

			

			
			<div class="method-subsection declared-in-section">
				<h4 class="method-subtitle">Declared In</h4>
				<p><code class="declared-in-ref">SIKIServiceEvents.h</code></p>
			</div>
			
			
		</div>
	</div>
</div><div class="section-method">
	<a name="//api/name/onQueue" title="onQueue"></a>
	<h3 class="method-title"><code><a href="#//api/name/onQueue">&ndash;&nbsp;onQueue</a></code>
<span class="task-item-suffix">required method</span></h3>

	<div class="method-info">
		<div class="pointy-thing"></div>

		<div class="method-info-container">
			
			
			<div class="method-subsection brief-description">
				<p>This method is called when the service is put in the queue for the execution.</p>
			</div>
			
		    

			<div class="method-subsection method-declaration"><code>- (void)onQueue</code></div>

		    
			

			

			

			
			<div class="method-subsection discussion-section">
				<h4 class="method-subtitle">Discussion</h4>
				<p>This method is called when the service is put in the queue for the execution.</p>
			</div>
			

			

			

			
			<div class="method-subsection declared-in-section">
				<h4 class="method-subtitle">Declared In</h4>
				<p><code class="declared-in-ref">SIKIServiceEvents.h</code></p>
			</div>
			
			
		</div>
	</div>
</div><div class="section-method">
	<a name="//api/name/onPause" title="onPause"></a>
	<h3 class="method-title"><code><a href="#//api/name/onPause">&ndash;&nbsp;onPause</a></code>
<span class="task-item-suffix">required method</span></h3>

	<div class="method-info">
		<div class="pointy-thing"></div>

		<div class="method-info-container">
			
			
			<div class="method-subsection brief-description">
				<p>This method is called when there is no network. Services should override this method if they need to:</p>
			</div>
			
		    

			<div class="method-subsection method-declaration"><code>- (void)onPause</code></div>

		    
			

			

			

			
			<div class="method-subsection discussion-section">
				<h4 class="method-subtitle">Discussion</h4>
				<p>This method is called when there is no network. Services should override this method if they need to:</p>

<p><p>
<ui>
<li> Commit unsaved changes to persistent data
<li> Destroy or clean up other objects consuming resources
<li> Display any relevant alerts or dialogs
</ui>
*</p>
			</div>
			

			

			

			
			<div class="method-subsection declared-in-section">
				<h4 class="method-subtitle">Declared In</h4>
				<p><code class="declared-in-ref">SIKIServiceEvents.h</code></p>
			</div>
			
			
		</div>
	</div>
</div><div class="section-method">
	<a name="//api/name/onResume" title="onResume"></a>
	<h3 class="method-title"><code><a href="#//api/name/onResume">&ndash;&nbsp;onResume</a></code>
<span class="task-item-suffix">required method</span></h3>

	<div class="method-info">
		<div class="pointy-thing"></div>

		<div class="method-info-container">
			
			
			<div class="method-subsection brief-description">
				<p>The Connect calls this method when the Service is ready to start executing.</p>

<p><p>
Services should override this method to perform tasks such as:</p>
			</div>
			
		    

			<div class="method-subsection method-declaration"><code>- (void)onResume</code></div>

		    
			

			

			

			
			<div class="method-subsection discussion-section">
				<h4 class="method-subtitle">Discussion</h4>
				<p>The Connect calls this method when the Service is ready to start executing.</p>

<p><p>
Services should override this method to perform tasks such as:</p>

<p><p>
<ui>
<li> Display any relevant alerts or dialogs
<li> Wire up external event handlers
<li> Listening for GPS updates
<ui>
*</p>
			</div>
			

			

			

			
			<div class="method-subsection declared-in-section">
				<h4 class="method-subtitle">Declared In</h4>
				<p><code class="declared-in-ref">SIKIServiceEvents.h</code></p>
			</div>
			
			
		</div>
	</div>
</div><div class="section-method">
	<a name="//api/name/onFinish" title="onFinish"></a>
	<h3 class="method-title"><code><a href="#//api/name/onFinish">&ndash;&nbsp;onFinish</a></code>
<span class="task-item-suffix">required method</span></h3>

	<div class="method-info">
		<div class="pointy-thing"></div>

		<div class="method-info-container">
			
			
			<div class="method-subsection brief-description">
				<ul>
<li>This is the final method that is called on a Service instance before it�s destroyed and completely removed from memory.</li>
</ul>


<p><p>
There will be no lifecycle methods called after the Activity has been destroyed.</p>
			</div>
			
		    

			<div class="method-subsection method-declaration"><code>- (void)onFinish</code></div>

		    
			

			

			

			
			<div class="method-subsection discussion-section">
				<h4 class="method-subtitle">Discussion</h4>
				<ul>
<li>This is the final method that is called on a Service instance before it�s destroyed and completely removed from memory.</li>
</ul>


<p><p>
There will be no lifecycle methods called after the Activity has been destroyed.</p>
			</div>
			

			

			

			
			<div class="method-subsection declared-in-section">
				<h4 class="method-subtitle">Declared In</h4>
				<p><code class="declared-in-ref">SIKIServiceEvents.h</code></p>
			</div>
			
			
		</div>
	</div>
</div><div class="section-method">
	<a name="//api/name/onRequestInvoke:" title="onRequestInvoke:"></a>
	<h3 class="method-title"><code><a href="#//api/name/onRequestInvoke:">&ndash;&nbsp;onRequestInvoke:</a></code>
<span class="task-item-suffix">required method</span></h3>

	<div class="method-info">
		<div class="pointy-thing"></div>

		<div class="method-info-container">
			
			
			<div class="method-subsection brief-description">
				<p>This method is called before Service calls Web Service Request.</p>
			</div>
			
		    

			<div class="method-subsection method-declaration"><code>- (void)onRequestInvoke:(id&lt;SIKIConnectionRequest&gt;)<em>connectionRequest</em></code></div>

		    
			
			<div class="method-subsection arguments-section parameters">
				<h4 class="method-subtitle parameter-title">Parameters</h4>
				<table class="argument-def parameter-def">
				
					<tr>
						<th scope="row" class="argument-name"><code>connectionRequest</code></th>
						<td><p>IConnectionRequest instance</p></td>
					</tr>
				
				</table>
			</div>
			

			

			

			
			<div class="method-subsection discussion-section">
				<h4 class="method-subtitle">Discussion</h4>
				<p>This method is called before Service calls Web Service Request.</p>
			</div>
			

			

			

			
			<div class="method-subsection declared-in-section">
				<h4 class="method-subtitle">Declared In</h4>
				<p><code class="declared-in-ref">SIKIServiceEvents.h</code></p>
			</div>
			
			
		</div>
	</div>
</div><div class="section-method">
	<a name="//api/name/onRequestFinish:" title="onRequestFinish:"></a>
	<h3 class="method-title"><code><a href="#//api/name/onRequestFinish:">&ndash;&nbsp;onRequestFinish:</a></code>
<span class="task-item-suffix">required method</span></h3>

	<div class="method-info">
		<div class="pointy-thing"></div>

		<div class="method-info-container">
			
			
			<div class="method-subsection brief-description">
				<p>This method is called after Web Service Request is executed.</p>
			</div>
			
		    

			<div class="method-subsection method-declaration"><code>- (void)onRequestFinish:(id&lt;SIKIConnectionResponse&gt;)<em>connectionResponse</em></code></div>

		    
			
			<div class="method-subsection arguments-section parameters">
				<h4 class="method-subtitle parameter-title">Parameters</h4>
				<table class="argument-def parameter-def">
				
					<tr>
						<th scope="row" class="argument-name"><code>connectionResponse</code></th>
						<td><p>IConnectionResponse instance</p></td>
					</tr>
				
				</table>
			</div>
			

			

			

			
			<div class="method-subsection discussion-section">
				<h4 class="method-subtitle">Discussion</h4>
				<p>This method is called after Web Service Request is executed.</p>
			</div>
			

			

			

			
			<div class="method-subsection declared-in-section">
				<h4 class="method-subtitle">Declared In</h4>
				<p><code class="declared-in-ref">SIKIServiceEvents.h</code></p>
			</div>
			
			
		</div>
	</div>
</div><div class="section-method">
	<a name="//api/name/onTerminate:" title="onTerminate:"></a>
	<h3 class="method-title"><code><a href="#//api/name/onTerminate:">&ndash;&nbsp;onTerminate:</a></code>
<span class="task-item-suffix">required method</span></h3>

	<div class="method-info">
		<div class="pointy-thing"></div>

		<div class="method-info-container">
			
			
			<div class="method-subsection brief-description">
				<ul>
<li>This method is called when there is any exception while executing the service.</li>
</ul>


<p><p>
Once this is called the service will be terminated and release from the memory.
* @param serviceException</p>
			</div>
			
		    

			<div class="method-subsection method-declaration"><code>- (void)onTerminate:(SIKServiceException *)<em>serviceException</em></code></div>

		    
			

			

			

			
			<div class="method-subsection discussion-section">
				<h4 class="method-subtitle">Discussion</h4>
				<ul>
<li>This method is called when there is any exception while executing the service.</li>
</ul>


<p><p>
Once this is called the service will be terminated and release from the memory.
* @param serviceException</p>
			</div>
			

			

			

			
			<div class="method-subsection declared-in-section">
				<h4 class="method-subtitle">Declared In</h4>
				<p><code class="declared-in-ref">SIKIServiceEvents.h</code></p>
			</div>
			
			
		</div>
	</div>
</div>
						</div>
						
					</div>
					
					

                    
                    
          
				</main>

				<footer>
					<div class="footer-copyright">
						
						<p class="copyright">Copyright &copy; 2016 Siminov Software Solution LLP. All rights reserved. Updated: 2016-01-04</p>
						
						
						<p class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.2.1 (build 1333)</a>.</p>
						
					</div>
				</footer>
			</div>
		</div>
	</article>

	<script src="../js/script.js"></script>
</body>
</html>