<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Dreams of Upul</title>
	<atom:link href="http://www.iroshan.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.iroshan.net</link>
	<description>All About Me &#124; සියල්ල මම ගැනමයි..</description>
	<lastBuildDate>Wed, 21 Apr 2010 17:37:20 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>පාවෙලා යන්න.. &#8211; Kasun Kalhara</title>
		<link>http://www.iroshan.net/lyrics/paa_wela_yanna/</link>
		<comments>http://www.iroshan.net/lyrics/paa_wela_yanna/#comments</comments>
		<pubDate>Wed, 21 Apr 2010 17:37:20 +0000</pubDate>
		<dc:creator>Iroshan</dc:creator>
				<category><![CDATA[Lyrics]]></category>
		<category><![CDATA[Kasun Kalhara]]></category>
		<category><![CDATA[Sinhala]]></category>
		<category><![CDATA[Sinhala Lyrics]]></category>

		<guid isPermaLink="false">http://www.iroshan.net/?p=57</guid>
		<description><![CDATA[පාවෙලා යන්න&#8230; මට ඉඩක් දෙන්න&#8230;. හීනයක් වෙන්න&#8230; මොහොතක් තනිව ඉන්න&#8230; ජීවිතේ පුරා පැතූ සිහින බොඳ වෙන්න&#8230; පෙර ඔබ එන්න&#8230; ආදරේ ගලා හැලෙනා&#8230; දිය වැල්ල ඔබ වෙන්න&#8230; මා දවා ඒ ආදරේ උණුහුම සොයා යන්න මතකය පමණි ඉතිරි වී ඇත්තේ]]></description>
			<content:encoded><![CDATA[<div><img class="size-full wp-image-59 aligncenter" title="Love" src="http://www.iroshan.net/wp-content/uploads/2010/04/fmphung1.jpg" alt="" width="413" height="391" /></div>
<div>පාවෙලා යන්න&#8230; මට ඉඩක් දෙන්න&#8230;.<br />
හීනයක් වෙන්න&#8230; මොහොතක් තනිව ඉන්න&#8230;<br />
ජීවිතේ පුරා පැතූ සිහින බොඳ වෙන්න&#8230; පෙර ඔබ එන්න&#8230;</div>
<div>
<p>ආදරේ ගලා හැලෙනා&#8230; දිය වැල්ල ඔබ වෙන්න&#8230;<br />
මා දවා ඒ ආදරේ උණුහුම සොයා යන්න<br />
මතකය පමණි ඉතිරි වී ඇත්තේ</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.iroshan.net/lyrics/paa_wela_yanna/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>සිංහලෙන් යතුරු ලියනය කරන්න.</title>
		<link>http://www.iroshan.net/sinhala/%e0%b7%83%e0%b7%92%e0%b6%82%e0%b7%84%e0%b6%bd%e0%b7%99%e0%b6%b1%e0%b7%8a-%e0%b6%ba%e0%b6%ad%e0%b7%94%e0%b6%bb%e0%b7%94-%e0%b6%bd%e0%b7%92%e0%b6%ba%e0%b6%b1%e0%b6%ba-%e0%b6%9a%e0%b6%bb%e0%b6%b1/</link>
		<comments>http://www.iroshan.net/sinhala/%e0%b7%83%e0%b7%92%e0%b6%82%e0%b7%84%e0%b6%bd%e0%b7%99%e0%b6%b1%e0%b7%8a-%e0%b6%ba%e0%b6%ad%e0%b7%94%e0%b6%bb%e0%b7%94-%e0%b6%bd%e0%b7%92%e0%b6%ba%e0%b6%b1%e0%b6%ba-%e0%b6%9a%e0%b6%bb%e0%b6%b1/#comments</comments>
		<pubDate>Mon, 12 Apr 2010 07:17:12 +0000</pubDate>
		<dc:creator>Iroshan</dc:creator>
				<category><![CDATA[Sinhala]]></category>
		<category><![CDATA[Typing]]></category>
		<category><![CDATA[Google transliteration]]></category>
		<category><![CDATA[Type in Sinhalese]]></category>
		<category><![CDATA[UCSC Font Conversion]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Google transliteration යනු Google විසින් අප වෙත ලබා දෙන නවතම මෘදුකාංගයකි. ඉන් ඔබට ඉංග්‍රීසි බෂාවෙන් ලියන අකුරු ඔබගේ භාෂාවට පරිවර්තනය කර ගැනීමේ හැකියාවක් පවතී. දැනට එය බොහොමයක් භාෂාවන් සඳහා උදව් කරන අතර අපගේ සිංහල භාෂාවද එඅ අතර වෙයි. මෙම ලිපිය සකස් කලේද Google transliteration වලින් වන අතර එය AJAX තාක්ෂනය ඔස්සේ පරිවර්තනය සිදු කරයි. මේ [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.iroshan.net/wp-content/uploads/2010/04/041210_0017_11.png" alt="" />Google transliteration යනු Google විසින් අප වෙත ලබා දෙන නවතම මෘදුකාංගයකි. ඉන් ඔබට ඉංග්‍රීසි බෂාවෙන් ලියන අකුරු ඔබගේ භාෂාවට පරිවර්තනය කර ගැනීමේ හැකියාවක් පවතී. දැනට එය බොහොමයක් භාෂාවන් සඳහා උදව් කරන අතර අපගේ සිංහල භාෂාවද එඅ අතර වෙයි. මෙම ලිපිය සකස් කලේද Google transliteration වලින් වන අතර එය AJAX තාක්ෂනය ඔස්සේ පරිවර්තනය සිදු කරයි. මේ අතර UCSC විසින් මෙයට පෙර මීට වඩා සාර්ථක නිපැයුමක් කරන ලදී. එය JavaScript පමණක් පාවිච්චි කරන අතර ඒ සඳහා අන්තර්ජාලයේ පාවිච්චිය අවම වෙයි. කෙසේ නමුත් Google විසින් සිංහල භාෂාව වෙනුවෙන් කරන ලද මෙම සේවය අප සැවොම විසින් අගය කල යුතු වෙමු. පහත වෙබ් ලිපින ඔස්සේ ඔබට Google Transliteration මෙන්ම UCSC Font Conversion Utility අත්හදා බැලිය හැක.<br />
[1] <a href="http://www.google.com/transliterate/sinhalese">http://www.google.com/transliterate/sinhalese</a></p>
<p>[2] <a href="http://ucsc.cmb.ac.lk/ltrl/services/feconverter/">http://ucsc.cmb.ac.lk/ltrl/services/feconverter/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.iroshan.net/sinhala/%e0%b7%83%e0%b7%92%e0%b6%82%e0%b7%84%e0%b6%bd%e0%b7%99%e0%b6%b1%e0%b7%8a-%e0%b6%ba%e0%b6%ad%e0%b7%94%e0%b6%bb%e0%b7%94-%e0%b6%bd%e0%b7%92%e0%b6%ba%e0%b6%b1%e0%b6%ba-%e0%b6%9a%e0%b6%bb%e0%b6%b1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Summer of Code Idea for Eclipse (2010)</title>
		<link>http://www.iroshan.net/google-data-protocol-provider/summer-of-code-idea-2010/</link>
		<comments>http://www.iroshan.net/google-data-protocol-provider/summer-of-code-idea-2010/#comments</comments>
		<pubDate>Sat, 10 Apr 2010 06:51:45 +0000</pubDate>
		<dc:creator>Iroshan</dc:creator>
				<category><![CDATA[Google Data Protocol Provider]]></category>
		<category><![CDATA[Eclipse Communication Framework]]></category>
		<category><![CDATA[Google Data Protocol]]></category>

		<guid isPermaLink="false">http://www.iroshan.net/?p=28</guid>
		<description><![CDATA[The Google Data Protocol let end users access and updates the data stored by many Google products. A number of Google products, such as Calendar, Blogger and Spreadsheets, provide APIs that are based on the Google Data Protocol. The developers can use these APIs to give end users new ways to access and manipulate the [...]]]></description>
			<content:encoded><![CDATA[<p>The Google Data Protocol let end users access and updates the data stored by many Google products. A number of Google products, such as Calendar, Blogger and Spreadsheets, provide APIs that are based on the Google Data Protocol. The developers can use these APIs to give end users new ways to access and manipulate the data they store in those Google products. The goal of this project is to develop a ECF provider for Google data protocol and create a new adapter for Google calendar API.</p>
<p style="text-align: justify;"><span style="color: #4f81bd;"><strong>Google Data Protocol<br />
</strong></span></p>
<p style="text-align: justify;">Google Data protocol is a REST inspired technology for reading, writing information on the web. It&#8217;s based on the Atom 1.0, RSS 2.0 syndication formats and Atom Publishing Protocol. Google Data Protocol extends Atom publishing protocol for processing queries, authentication, and batch requests.</p>
<p style="text-align: justify;">Google Data protocol provide external access for data and functionalities of many Google products .It enables access to data stored in Google servers through contexts other than web browsers. So Developers can write applications to access or update data stored in many Google products. Many services at Google provide external access to data and functionality through APIs that utilize the Google Data Protocol. Google Data API is based on Google data protocol.</p>
<p style="text-align: justify;"><span style="color: #4f81bd;"><strong>Eclipse Communication Framework<br />
</strong></span></p>
<p style="text-align: justify;"><span style="color: black;">Eclipse communication framework supporting communication based applications in eclipse platform. Currently there are several components to access different protocols and services.<br />
</span></p>
<p style="text-align: justify;">
<p style="text-align: justify;"><span style="color: black;">This project is based on creating a protocol provider for Google data. It&#8217;ll enable access to different Google services through eclipse platform. Developers can write applications to access and use functionalities of different google services like calendar API, blogger API, spreadsheet API&#8230;etc using this protocol provider.<br />
</span></p>
<p style="text-align: justify;">
<p style="text-align: justify;"><span id="more-28"></span></p>
<p style="text-align: justify;"><span style="color: black;">This project mainly has 3 components.<br />
</span></p>
<ol>
<li>
<div style="text-align: justify;"><span style="color: black;">Google Data Protocol Provider for ECF<br />
</span></div>
</li>
<li>
<div style="text-align: justify;"><span style="color: black;">Google Calendar Adapter and Google Calendar UI Plug-in<br />
</span></div>
</li>
<li>
<div style="text-align: justify;"><span style="color: black;">Google Data Project generation tool for Eclipse Platform<br />
</span></div>
</li>
</ol>
<p style="text-align: justify;">
<p style="text-align: justify;"><span style="color: #4f81bd; font-family: Cambria;"><strong>Google data protocol provider for ECF<br />
</strong></span></p>
<p style="text-align: justify;">There are number of Google service APIs available, developed on top of Google data protocol. When developing those as ECF adapters this will be the base provider for all of them. This will handle all the base services of Google Data protocol (like authentication) and provide base classes for all other Google service APIs.</p>
<p style="text-align: justify;"><span style="color: #4f81bd; font-family: Cambria;"><strong>Google Calendar Adapter and Google Calendar UI Plug-in<br />
</strong></span></p>
<p style="text-align: justify;">Google calendar is very useful service provided by Google. It&#8217;ll enable us to organize their events online and provide access from anywhere in the world. Google calendar adapter will bring advantages and functionalities of Google calendar service in to eclipse platform by using ECF architecture. UI plug-in will use Google calendar adapter and provide an interface to organize events through IDE or from RCP application.</p>
<p style="text-align: justify;">Following services will be provided through this Adapter and UI plug-in</p>
<ul>
<li>
<div style="text-align: justify;">Retrieving calendar lists</div>
</li>
<li>
<div style="text-align: justify;">Managing calendars (Create / Update / Delete calendars)</div>
</li>
<li>
<div style="text-align: justify;">Retrieving events</div>
</li>
<li>
<div style="text-align: justify;">Managing events (Create / Update / Delete events)</div>
</li>
<li>
<div style="text-align: justify;">Reminders and Notifications ( Users can set up notifications via SMS, Email or IDE popup notification*)</div>
</li>
<li>
<div style="text-align: justify;">Sharing calendars (Retrieve access control list / Adding user to ACL / Update user role / remove user from ACL)</div>
</li>
<li>
<div style="text-align: justify;">Managing subscriptions to calendars (Add / Edit / Delete subscriptions)</div>
</li>
<li>
<div style="text-align: justify;">Synchronization with online service either pre-defined time or after forced by user.</div>
</li>
</ul>
<p style="text-align: justify;">
<p style="text-align: justify;"><span style="color: #4f81bd; font-family: Cambria;"><strong>Google Data Project generation tool for Eclipse Platform<br />
</strong></span></p>
<p style="text-align: justify;"><span style="color: black; font-family: Verdana; font-size: 10pt;">This tool will generate projects based on Google data APIs. Developers will be able to create Google data API projects based on a pre-defined template without writing code from the scratch. New Project creation wizard will provide choices to the developer to select which service to use and what are the operations needed to implement.<br />
</span></p>
<p style="text-align: justify;"><span style="font-size: 10pt;">Note: With this project I&#8217;m going to develop only Google calendar adapter/ plug-in only. So there will be option only for creating projects using Google calendar provider API.<br />
</span></p>
<p><span style="color: #4f81bd; font-family: Cambria;"><strong>Resources going to use in the project<br />
</strong></span></p>
<ul>
<li>Google Data Java client library &#8211; The GData Java Client Library provides a library and source code that makes it easy to access data through Google Data APIs. This library provides access to set of Google service APIs. It&#8217;s distributed under Apache 2.0 license.<br />
<a href="http://code.google.com/p/gdata-java-client/"><span style="color: blue; text-decoration: underline;">http://code.google.com/p/gdata-java-client/</span></a></li>
<li>Eclipse Communications Framework – Latest release of the ECF ( version 3.2)<br />
<a href="http://www.eclipse.org/ecf/"><span style="color: blue; text-decoration: underline;">http://www.eclipse.org/ecf/</span></a></li>
<li>Eclipse Plug-in Development Environment (PDE) – Plug-in development environment and PDE UI tools<br />
<a href="http://www.eclipse.org/pde/"><span style="color: blue; text-decoration: underline;">http://www.eclipse.org/pde/</span></a></li>
</ul>
<p><span style="color: #4f81bd; font-family: Cambria;"><strong>Benefits to Eclipse Community<br />
</strong></span></p>
<ul>
<li>Develop applications that use Google data protocol.</li>
<li>Develop adapters for Google data APIs (e.g.  Google calendar API).</li>
<li>Accesses to Google services and read / modify data stored in Google servers.</li>
<li>Use Google calendar&#8217;s data and functionalities in eclipse plug-ins or Eclipse RCP applications.</li>
<li>Eclipse UI plug-in to use Google calendar functionalities from the IDE. Manage events from Eclipse IDE.</li>
<li>Get notifications about the events from the Eclipse IDE.</li>
</ul>
<p><span style="color: #4f81bd; font-family: Cambria;"><strong>Information Gathering for the Project<br />
</strong></span></p>
<ul>
<li>Referring to online media of Google Data Protocol. (Developer Guide, Protocol Reference, Java API documentation and other articles, blogs</li>
<li>Read online articles, blogs available for ECF.</li>
<li>Getting help from dev-mailing lists and mentor.</li>
<li>Looking into Code base of ECF as well as GData java client source.</li>
</ul>
<p><span style="color: #4f81bd; font-family: Cambria;"><strong>Deliverables<br />
</strong></span></p>
<ol style="margin-left: 37pt;">
<li>Google Data Protocol Provider for ECF</li>
<li> ECF Container Adapter for Google Calendar</li>
<li> Google Calendar UI plug-in based on above adapter</li>
<li> Project / Code Generation plug-in for Google Data API</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.iroshan.net/google-data-protocol-provider/summer-of-code-idea-2010/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SWT Browser Widget with Mozilla (SWT.MOZILLA)</title>
		<link>http://www.iroshan.net/uncategorized/swt-browser-widget-with-mozilla-swt-mozilla/</link>
		<comments>http://www.iroshan.net/uncategorized/swt-browser-widget-with-mozilla-swt-mozilla/#comments</comments>
		<pubDate>Sat, 06 Mar 2010 16:39:01 +0000</pubDate>
		<dc:creator>Iroshan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.iroshan.net/?p=18</guid>
		<description><![CDATA[We can use browser inside our java application with SWT browser widget. We can load external HTML pages or websites into our applications using it. Normal way to initialize browser widget in your application is following. Browser browser = new Browser(shell, SWT.NONE); This will create a widget with OS specific browser instance. If you are [...]]]></description>
			<content:encoded><![CDATA[<p>We can use browser inside our java application with SWT browser widget. We can load external HTML pages or websites into our applications using it.</p>
<p>Normal way to initialize browser widget in your application is following.</p>
<p><span style="font-family:Courier New; font-size:10pt"><span style="color:black">Browser browser = </span><span style="color:#7f0055"><strong>new</strong></span><span style="color:black"> Browser(shell, SWT.</span><span style="color:#0000c0"><em>NONE</em></span><span style="color:black">); </span></span></p>
<p><span style="color:black">This will create a widget with OS specific browser instance. If you are in windows, Internet Explorer will be your browser host. For Linux default is Mozilla. Personally I don&#8217;t like IE much. And there&#8217;s a way to load Mozilla to SWT browser widget. Other than that there&#8217;s another advantage with using Mozilla, By using Mozilla if you right click nothing will happen inside the application. With IE, users can detect we are using HTML page inside the application. That&#8217;s by right click will show the browser specific context menu. Other than that using Mozilla we can get powerful features from Mozilla and XUL runner runtime. Powerful feature with browser widget is we can call JavaScript functions from Java as well as java functions from JavaScript. </span></p>
<p><span style="color:black">There are few steps you have to achieve this goal. </span></p>
<ul>
<li>
<div><span style="color:black">Download and install XUL runner. </span></div>
<ul>
<li><span style="color:black">I&#8217;ve downloaded the SDK version. This includes runtime version and additional files needed for development purposes.<br />
</span><a href="http://releases.mozilla.org/pub/mozilla.org/xulrunner/releases/1.9.2/sdk/" target="_blank">http://releases.mozilla.org/pub/mozilla.org/xulrunner/releases/1.9.2/sdk/</a><span style="color:black"><br />
</span></li>
<li><span style="color:black">Installation instructions can be found at following<br />
</span><a href="https://developer.mozilla.org/en/XULRunner_1.9.1_Release_Notes" target="_blank">https://developer.mozilla.org/en/XULRunner_1.9.1_Release_Notes</a><span style="color:black"><br />
</span></li>
<li><span style="color:black">It mentioned to run following command in order to install XUL Runner.<br />
<span style="font-family:Courier New; font-size:10pt">xulrunner.exe &#8211;register-global</span><br />
</span></li>
<li><span style="color:black">But we can&#8217;t see anything happening. Actually it&#8217;s registering some variables in windows registry. Run <span style="font-family:Courier New; font-size:10pt">regedit</span> and see whether following variables are set in your registry.<br />
</span></li>
<li><span style="color:black">HKEY_LOCAL_MACHINE/Software/mozilla.org/GRE (for register global)<br />
</span></li>
<li><span style="color:black">HKEY_CURRENT_USER/Software/mozilla.org/GRE (for register user)<br />
</span></li>
<li><a href="https://developer.mozilla.org/en/GRE_Registration" target="_blank">https://developer.mozilla.org/en/GRE_Registration</a><span style="color:black"><br />
</span></li>
</ul>
</li>
<li><span style="color:black">Now you can start with Development of SWT Browser application.<br />
Just change <span style="font-family:Courier New; font-size:10pt">SWT.</span></span><span style="color:#0000c0; font-family:Courier New; font-size:10pt"><em>NONE</em></span><span style="color:black"> to <span style="font-family:Courier New; font-size:10pt">SWT.</span></span><span style="color:#0000c0; font-family:Courier New; font-size:10pt"><em>MOZILLA </em></span>to load Mozilla into the widget.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.iroshan.net/uncategorized/swt-browser-widget-with-mozilla-swt-mozilla/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Introduction to Aspects</title>
		<link>http://www.iroshan.net/uncategorized/introduction-to-aspects/</link>
		<comments>http://www.iroshan.net/uncategorized/introduction-to-aspects/#comments</comments>
		<pubDate>Wed, 21 Oct 2009 18:36:11 +0000</pubDate>
		<dc:creator>Iroshan</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.iroshan.net/?p=3</guid>
		<description><![CDATA[Application-context.xml &#60;?xml version="1.0" encoding="UTF-8"?&#62; &#60;beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsd"&#62; &#60;aop:aspectj-autoproxy /&#62; &#60;bean name="firstAspect"/&#62; &#60;bean name="helloWorld"/&#62; &#60;/beans&#62; FirstAspect.java package com.iroshan.aop.aspects; import org.aspectj.lang.ProceedingJoinPoint; import org.aspectj.lang.annotation.Around; import org.aspectj.lang.annotation.Aspect; import org.aspectj.lang.annotation.Before; import org.aspectj.lang.annotation.Pointcut; @Aspect public class FirstAspect { @Pointcut("execution(* sayHello(..))") public void helloPointCut(){ } @Before("helloPointCut()") public void helloAdvice(){ System.out.println("Hello There!!!"); } @Around("helloPointCut()") public Object helloAroundAdvice(ProceedingJoinPoint pjp) [...]]]></description>
			<content:encoded><![CDATA[<h4><span style="text-decoration: underline;">Application-context.xml</span></h4>
<pre class="xml">&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;beans
 xmlns="http://www.springframework.org/schema/beans"
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 xmlns:aop="http://www.springframework.org/schema/aop"
 xsi:schemaLocation="http://www.springframework.org/schema/beans

http://www.springframework.org/schema/beans/spring-beans-2.5.xsd

http://www.springframework.org/schema/aop

 http://www.springframework.org/schema/aop/spring-aop-2.5.xsd"&gt;

 &lt;aop:aspectj-autoproxy /&gt;

 &lt;bean name="firstAspect"/&gt;

 &lt;bean name="helloWorld"/&gt;

&lt;/beans&gt;</pre>
<p><span id="more-3"></span></p>
<h4>FirstAspect.java</h4>
<pre class="java">package com.iroshan.aop.aspects;

import org.aspectj.lang.ProceedingJoinPoint;
import org.aspectj.lang.annotation.Around;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;

@Aspect
public class FirstAspect {

 @Pointcut("execution(* sayHello(..))")
 public void helloPointCut(){

 }

 @Before("helloPointCut()")
 public void helloAdvice(){
 System.out.println("Hello There!!!");
 }

 @Around("helloPointCut()")
 public Object helloAroundAdvice(ProceedingJoinPoint pjp) throws Throwable{
 Object retVal = pjp.proceed();
 System.out.println(retVal);
 return 2;
 }

}</pre>
<h4>HelloWorld.java</h4>
<pre class="java">package com.iroshan.aop;

public class HelloWorld {

public int sayHello() {
    System.out.println("Hello World");
    return 1;
}

}</pre>
<h4>Main.java</h4>
<pre class="java">package com.iroshan.aop;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Main {

public static void main(String[] args) {
   ApplicationContext factory = new ClassPathXmlApplicationContext("Application-context.xml");
   HelloWorld helloWorld = (HelloWorld) factory.getBean("helloWorld");
   System.out.println(helloWorld.sayHello());
}

}</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.iroshan.net/uncategorized/introduction-to-aspects/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
