tag:blogger.com,1999:blog-26241885544387593362024-03-14T08:59:58.876+05:30Programming WorldJava training, Android Developement, Web developement,Android IDE, java developement, PHP, C, CPP, Java tutorials, Android examples, Application developement, mobile application, Android applications,android mobile applicationAnonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.comBlogger22125tag:blogger.com,1999:blog-2624188554438759336.post-86552518173272430542013-06-19T12:39:00.000+05:302013-06-19T12:39:57.603+05:30Setup Java Environment Variable<div dir="ltr" style="text-align: left;" trbidi="on">
<h3 style="text-align: left;">
<b>What is Environment Variable???</b></h3>
<div>
Environment variables are the variables which decides the functionality of Command Prompt.</div>
<div>
e.g. </div>
<div>
If we talk about <a href="http://programmingworld4u.blogspot.in/2012/07/java-j2se-intro.html" target="_blank">java</a>, then if we don't setup the environment variable,then we have to run program by going in the bin directory which contains the java.exe and javac.exe file which are used for program compilation and running the program.</div>
<div>
And moreover we have to paste the source code file in bin directory which creates our work more difficult. </div>
<div>
<br /></div>
<div>
But if we setup the environment variable, then we can run our source code from any directory.</div>
<div>
<br /></div>
<div>
Here is the demo for HOW TO SETUP ENVIRONMENT VARIABLE FOR JAVA.........</div>
<div>
<br />
<iframe allowfullscreen="" frameborder="0" height="315" src="http://www.youtube.com/embed/aq_dDdc0vHs" width="420"></iframe><br /><br />
If you have any query regarding this or anything else related to programming then feel free to contact us either by leaving comment here or just mail us at surinderrajpal[at]india.com<br />
<br /></div>
<div>
<br /></div>
</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-62349298613794045092013-06-10T19:00:00.000+05:302013-06-10T19:01:47.234+05:30Ruby Programming Demo<a href="http://programmingworld4u.blogspot.in/2013/06/ruby-introduction.html" target="_blank">Ruby</a> , as described before this post, is most powerfull interpreted language.<br />
Syntax used in Ruby is just like Perl, Lisp and SmallTalk which doesn't means that you have to learn these languages first. But you can start learning ruby if and only if you have some basic programming knowledge like control statements(e.g. looping), conditional statements(e.g. if else).<br />
Now as you know what ruby language is and where it is used?<br />
So we start our practice by implementing our first program i.e. Printing "Hello World"<br />
<br />
I have made a video for this Program tutorials.<br />
Program is given below:-<br />
<br />
"<br />
puts "Hello World!!!"<br />
<br />
"<br />
<br />
Above program results in Printing Hello World!!! on the screen.<br />
The tutorial is shown below so have a look over it...<br />
<br />
<br />
<iframe allowfullscreen="" frameborder="0" height="315" src="http://www.youtube.com/embed/3-elOoi6FAI" width="560"></iframe><br />
<br />
<br />
For any query feel free to contact us by leaving your valuable comment on the post or on the video.....Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-30104940586578615242013-06-08T02:07:00.000+05:302013-06-08T02:07:11.270+05:30RUBY Introduction<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<div>
<b><u>RUBY- AN INTERPRETED PROGRAMMING LANGUAGE<div class="separator" style="clear: both; text-align: center;">
<a href="http://4.bp.blogspot.com/-YB6E3Y6E8a0/UbJDdCWLleI/AAAAAAAAASk/8YTjzlloM2Q/s1600/ruby.png" imageanchor="1" style="clear: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img alt="RUBY Programming language" border="0" height="200" src="http://4.bp.blogspot.com/-YB6E3Y6E8a0/UbJDdCWLleI/AAAAAAAAASk/8YTjzlloM2Q/s200/ruby.png" title="RUBY Programming language" width="199" /></a></div>
</u></b></div>
<ul style="text-align: left;">
<li>Ruby is one of the most powerful programming language.</li>
<li>It is object-oriented programming langauge.</li>
<li>It is an interpreted language i.e. A little bit code conventions are there.</li>
<li>Its the simplest one of all Object-Oriented languages.</li>
<li>The code saved in file with the extension either .rb or .rbw</li>
<li>All the facilty is provided in this like Window Programming, Console Programming.</li>
<li>This is used on web also in combination with rails.</li>
<li>RUBY ON RAILS which is one of the most powerful scripting language.</li>
<li>Scripting languages are the languages which run directly i.e. no need to convert them first into machine-dependent code.So it is the fastest language.</li>
<li>The code convention are similar to PERL, SMALL-TALK, LISP, ADA, EIFFEL.</li>
<li>It is the language which is similar to HUMAN BODY i.e <b>Simpler from outside Complex from inside.</b></li>
<li>This is the language with balanced functional programming with impretive programming.</li>
<li>Yukihiro “Matz” Matsumoto, Creator Of Ruby, often said that "he is trying to make Ruby Natural, but not simple.</li>
<li>After its public release in 1995, It has drawn devoted coders world-wide.</li>
<li>One more thing about ruby is its free of cost. That means anyone can be expert in this without paying anything.</li>
<li>It also provide the facility of calculator i.e. We can any computation directly without writing any code.</li>
</ul>
<br />
<br /></div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-13051004370506879842013-02-25T14:02:00.002+05:302013-02-25T14:02:42.188+05:30Android Setup (Configuration )<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
<a href="http://2.bp.blogspot.com/-y5zNzRKSf3I/USsgtn9CYSI/AAAAAAAAAOo/ABbIOHWS5uQ/s1600/android-apps.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="Android apps" border="0" height="150" src="http://2.bp.blogspot.com/-y5zNzRKSf3I/USsgtn9CYSI/AAAAAAAAAOo/ABbIOHWS5uQ/s200/android-apps.jpg" title="Android apps" width="200" /></a>Now we learned much that we can start doing practical, so now the problem is how to setup or configure Android on your PC.<br />
<br />
Now the requirements are:-<br />
<br />
<br />
<ol style="text-align: left;">
<li>Android SDK(Software Development Kit)</li>
<li>JDK (Java Development Kit )</li>
<li>Eclipse with ADT (Android Developer Tool) plug-in</li>
</ol>
<div>
After installing these three components you need to configure Android SDK Path for Eclipse.</div>
<div>
To do so follow the steps explained in the document attached below. To view the document, <a href="https://docs.google.com/document/d/1TnANEx-qilBqaess8vcTTVE-ZBdfd8cpACWx-64U9Qc/edit?usp=sharing" target="_blank">click here</a></div>
<div>
<br /></div>
<div>
In this document, you will find following things:-</div>
<div>
<a href="http://3.bp.blogspot.com/-qhS_WpJu408/USsgufAeTWI/AAAAAAAAAOw/rDo5VKJozbU/s1600/avd_first_prg.jpg" imageanchor="1" style="clear: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img alt="Android First app" border="0" height="166" src="http://3.bp.blogspot.com/-qhS_WpJu408/USsgufAeTWI/AAAAAAAAAOw/rDo5VKJozbU/s200/avd_first_prg.jpg" title="Android First app" width="200" /></a><ul style="text-align: left;">
<li>Requirements</li>
<li>Configuration Guide</li>
<li>+ Your First App Guide (App to print hello on screen )</li>
</ul>
<div>
Here you are going to place your first feet in Android Development, so wish you best of luck......</div>
</div>
<div>
Keep enjoying.........</div>
</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com1tag:blogger.com,1999:blog-2624188554438759336.post-2850108581041101942013-02-19T18:48:00.000+05:302013-02-19T18:50:14.146+05:30Activity In Android<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-PoLG2Cm67yU/USN6wLljTaI/AAAAAAAAANY/zgS8ow1RrIY/s1600/Android-activity-Life-cycle.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img alt="Android Activity LifeCycle" border="0" height="246" src="http://3.bp.blogspot.com/-PoLG2Cm67yU/USN6wLljTaI/AAAAAAAAANY/zgS8ow1RrIY/s320/Android-activity-Life-cycle.png" title="Android Activity LifeCycle" width="320" /></a></div>
As we provided the just intro about the main components of <a href="http://programmingworld4u.blogspot.in/2012/10/android-introduction.html" target="_blank">android</a>, now we'll discuss these components in details. First component we discuss is <b>ACTIVITY.</b><br />
<b><br /></b>
As we all know that activity is used to display the user interface just like in AWT or SWING in<a href="http://programmingworld4u.blogspot.in/2012/07/java-j2se-intro.html" target="_blank"> java</a>. Interface is made in XML(eXtensible Markup Language).<br />
Activity is an class provided by the android framework . which provide the facility to display the layout to the user. This class provide some callback methods to represent the different change of state of an activity.<br />
To define an activity, we have to create a subclass of Activity Class and need to override its methods.<br />
Different change of state of an activity are as follows:-<br />
<br />
<ol style="text-align: left;">
<li>Active State</li>
<li>Visible State</li>
<li>Inactive / Invisible State</li>
</ol>
<div>
<span style="font-weight: bold;"> 1</span><span style="font-weight: bold;">. </span><u style="font-weight: bold;">Active State</u><b>:-</b> An activity is in active state only when it has user focus and it is visible to user to handle the life-cycle of the activity. </div>
<div>
Life-cycle of an active activity can be managed by onPause() and onResume() callback methods.</div>
<div>
<br /></div>
<div>
<span style="font-weight: bold;"> </span><b>2. <u>Visible State</u>:- </b>An activity is in visible state when it appears to the user but doesn't have user focus.</div>
<div>
Life-cycle of an visible activity can be manged by onStart() and onStop() callback methods.</div>
<div>
<br /></div>
<div>
<span style="font-weight: bold;"> </span><b>3. <u>Inactive/Invisible State</u>:- </b>An activity is in Inactive/Invisible state when it doesn't have user focus and also doesn't appear to the user.</div>
<div>
Life-cycle of an inactive state can be managed by onCreate() and onDistroy() callback methods.</div>
</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-16910893631540771512013-01-31T12:48:00.000+05:302013-01-31T12:48:00.095+05:30Components of Android<div dir="ltr" style="text-align: left;" trbidi="on">
<a href="http://programmingworld4u.blogspot.in/2012/10/android-introduction.html" target="_blank">Android</a> has basically four components which it uses to manage all the applications.<br />
These are as follows:-<br />
<br />
<ol style="text-align: left;"><a href="http://3.bp.blogspot.com/-2Mvbc7TWebE/UQoaBT7yZaI/AAAAAAAAAM4/0uBU7Ub76VQ/s1600/untitled.bmp" imageanchor="1" style="clear: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img alt="Components of Android" border="0" height="190" src="http://3.bp.blogspot.com/-2Mvbc7TWebE/UQoaBT7yZaI/AAAAAAAAAM4/0uBU7Ub76VQ/s400/untitled.bmp" title="Components of Android" width="400" /></a>
<li>Activity</li>
<li>Content Provider</li>
<li>Broadcast Reciever</li>
<li>Service<br /></li>
</ol>
<div>
Here is just the overview of the components of Android.These components of android will be discussed in later posts.</div>
<h4 style="text-align: left;">
<span style="font-weight: bold;">1.</span><span style="font-weight: bold;"> </span><u style="font-weight: bold;">Activity</u><span style="font-weight: bold;">:</span><span style="font-weight: bold;">-</span><span style="font-weight: normal;"> Activity is an visible component of android which is used to display the user interface to the user just like a frame in awt or swing.Interface is made using Xtensible Markup Language(XML).To use this, Activity class is provided by the android.Activity is full java based class.</span></h4>
<div style="text-align: left;">
<b>2. </b><u style="font-weight: bold;">Content Provider</u><b>:- </b>This component provides the facility to share database between different applications.</div>
<div>
e.g. As the contact detail is saved in contact application but we can use that information in other applications like Phone Dialer, Messaging, call, etc.</div>
<div>
This facility is provided by Content Provider.</div>
<div>
<br /></div>
<div>
<b>3. </b><u style="font-weight: bold;">Broadcast Reciever</u><b>:-</b> This android component provides the facility to communicate between two or more applications. It is used by the application to broadcast its change of state to other applications.</div>
<div>
e.g. Whenever we are listening music and a call is received at the same time, then in this situation music player is paused automatically and when the call is ended, Music player is resumed automatically.</div>
<div>
This is done with the help of Broadcast Reciever.</div>
<div>
<br /></div>
<div>
<b>4. <u>Service</u>:- </b>Services are used to provide the facility for starting long running tasks which perform some operation in background and doesn't require much user interaction.</div>
<div>
e.g. Downloading a file from network, playing some music in background,etc.</div>
<div>
These tasks never interrupt in other applications.</div>
<div>
<br /></div>
<div>
<br /></div>
<div>
These four components are the basic components which will discussed briefly in later posts with examples.</div>
</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-2863654711828230092012-12-13T18:43:00.000+05:302013-02-19T18:51:10.532+05:30Android LifeCycle<div dir="ltr" style="text-align: left;" trbidi="on">
<br />
In <a href="http://www.programmingworld4u.blogspot.in/2012/10/android-introduction.html" target="_blank">android</a>, an application doesn't have any control over its lifecycle.<br />
<br />
Life Cycle of an Android Application could be managed by <b>Android Run-time</b> <b>Environment </b>which provide some callback methods to notify the different change of state of an application.<br />
<br />
As an application developer, our responsibility would be just to override these callback methods to handle the change of state of an application. <br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://4.bp.blogspot.com/-iAh-GvmfHU0/UMnUEcPv2cI/AAAAAAAAALk/cZlh4kMEzNo/s1600/activity_lifecycle.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="Activity LifeCycle" border="0" height="320" src="http://4.bp.blogspot.com/-iAh-GvmfHU0/UMnUEcPv2cI/AAAAAAAAALk/cZlh4kMEzNo/s1600/activity_lifecycle.png" title="Activity LifeCycle" width="271" /></a></div>
Different<a href="http://programmingworld4u.blogspot.in/2013/02/activity-in-android.html" target="_blank"> states</a> are:-<br />
<ul>
<li>Active State</li>
<li>Visible State</li>
<li>Inactive/Invisible State</li>
</ul>
These states can be managed using following methods:-<br />
<ul>
<li>onCreate()</li>
<li>onDestroy()</li>
<li>onStart()</li>
<li>onStop()</li>
<li>onPause()</li>
<li>onResume()</li>
</ul>
To be continued........ </div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-32813097909457680972012-12-13T13:53:00.003+05:302012-12-13T13:53:43.092+05:30PHP Introduction<a href="http://4.bp.blogspot.com/-ayJvD2UP9tE/UMmPfdeq02I/AAAAAAAAALU/GT9mWJ9pmEs/s1600/php.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="PHP ( Hypertext Preprocessor)" border="0" src="http://4.bp.blogspot.com/-ayJvD2UP9tE/UMmPfdeq02I/AAAAAAAAALU/GT9mWJ9pmEs/s1600/php.png" height="168" title="PHP ( Hypertext Preprocessor)" width="320" /></a><b>PHP</b> is a language that has been growned so fastly. It was originally conceived as a set or <b>collection of macros </b>to provide help to the coders to maintain their personal home pages, and its name given from this purpose i.e. <b>Personal(P) Home(H) Page(P)</b>. Since then, The capabilities of PHP have been extended, taking it beyond a set of utilities to a full-featured programming language, capable of managing huge database-driven online environments or say complete WEBSITE can be managed using PHP. As PHP's capabilities have grown, so its popularity is also increased. PHP was running on around <b>1 million hosts in Nov. 1999. </b>And <b>in Feb. 2000,</b> that figure had already risen to<b> 1.4 million hosts.</b> According to E-Soft, PHP is the only module which is most popular on Apache, beating even ModPerl. <br />Now, PHP is officially known as PHP - <b>"HyperText Preprocessor"</b>. It is an server-side scripting language basically written in an HTML context or HTML tag. Unlike an ordinary HTML page, a PHP script is not sent directly to a client by the server. Instead, it is parsed by the PHP binary or module or PHP interpreter. HTML elements in the script are left alone, but PHP code is interpreted and executed. PHP code in a script can be used to query databases, create images, read and write files, talk to remote servers. The possibilities in PHP are endless.<br />PHP is one of the easiest Web Development Language in which a complete full functioning website can be Developed in a day or two days.<br />As it provides the simplest Keywords to manage database, to get User Input or to respond user back.<br />
<br />
Now-a-days this is most required language in the web development market.<br />Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-6658279054331514972012-12-09T21:28:00.000+05:302012-12-14T14:08:26.289+05:30DVM(Dalvik Virtual Machine)As we are familiar with the two major problems in mobiles,given as:-<br />
i) Less Memory<br />
i) Limited Battery Backup<br />
<br />
Keeping these tow limitations in mind, we use Register Based <a href="http://www.programmingworld4u.blogspot.in/2012/12/process-virtual-machine.html" target="_blank">Process Virtual Machine</a> in Mobiles.<br />
DVM is also an Register Based Process Virtual Machine whereas JVM is an Stack Based Process Virtual Machine.<br />
<br />
As in JVM, after compilation it gives BYTE Code which is platform-independant Intermidiate Code.<br />
<br />
<div style="text-align: center;">
<b><span style="background-color: white;"> Java File</span></b></div>
<div style="text-align: center;">
<b><span style="background-color: white;"><span style="background-color: white;">(Compiled by java Compiler</span>)</span></b></div>
<div style="text-align: center;">
<b><span style="background-color: white;">↓ </span></b></div>
<div style="text-align: center;">
<b><span style="background-color: white;">Byte Code</span></b></div>
<div style="text-align: center;">
<b><span style="background-color: white;">(.class File)</span><br /><span style="background-color: white;">↓ </span></b></div>
<div style="text-align: center;">
<b><span style="background-color: white;">Dalvik Executable Code</span></b></div>
<div style="text-align: center;">
<b><span style="background-color: white;">(.dex File)</span></b></div>
<div style="text-align: center;">
</div>
<span style="background-color: #999999;"><span style="background-color: white;"></span></span><br />
Just Like JVM, after compilation it generates DEX code i.e. Dalvik Executable Code which is also an platform independant Intermediate Code.<br />
<br />
DVM Uses less memory for the execution of an instruction so that it is efficient in case of less memory as in mobiles.Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-30142595002664788392012-12-09T16:15:00.004+05:302012-12-14T14:10:21.613+05:30Process Virtual Machine<h4>
<b>Process Virtual Machine Continued.....</b> </h4>
As you know, Process Virtual Machines are used to support an O.S. in the execution of an application.<br />
e.g.<br />
JVM(Java Virtual Machine), CLR, DVM(Dalvik Virtual Machine), etc.<br />
On the basis of its architecture, we have two types of Process Virtual Machine:-<br />
<ol>
<li> Stack Based Process Virtual Machine</li>
<li>Register Based Process Virtual Machine </li>
</ol>
1)<u><b> Stack Based VM</b></u> <b>:-</b> Stack based Process Virtual machines are faster and use Reduced Instruction Set (RISC Architecture).<br />
e.g.<br />
JVM (Java Virtual Machine)<br />
Main disvantage of this type of machines is that they require more memory.<br />
<br />
2) <u><b>Register Based VM</b></u> <b>:-</b> Register based process virtual machines are little bit slower than Stack Based Virtual Machine but take less memory to execute instruction.in comparison to Stack Based Virtual Machine.<br />
e.g.<br />
DVM(<a href="http://www.programmingworld4u.blogspot.in/2012/12/dalvik-virtual-machine.html" target="_blank"> Dalvik Virtual Machine</a>)<br />
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-48804453631730155852012-11-14T20:01:00.000+05:302012-12-14T14:11:17.167+05:30Virtual Machine<h2>
VM ( Virtual Machine)</h2>
<h4>
<a href="http://4.bp.blogspot.com/-z9UXJ_OW5Cg/UKOqcU_7prI/AAAAAAAAAKI/dVtsp01lKYA/s1600/Virtual+Machine.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="Dalvik Virtual Machine(DVM)" border="0" src="http://4.bp.blogspot.com/-z9UXJ_OW5Cg/UKOqcU_7prI/AAAAAAAAAKI/dVtsp01lKYA/s1600/Virtual+Machine.jpg" height="197" title="Dalvik Virtual Machine(DVM)" width="320" /></a><u>Virtual Machine(VM):-</u> </h4>
<h4>
<span style="font-weight: normal;">VM is an software implementation of a machine or computer which is used to execute our program like on a physical machine. VM is a set of instructions which will be followed to execute our program. On the basis of use, we have two types of Virtual Machine:-</span></h4>
<br />
<ol>
<li>System Virtual Machine</li>
<li><a href="http://www.programmingworld4u.blogspot.in/2012/12/process-virtual-machine.html" target="_blank">Process Virtual Machine</a></li>
</ol>
<u><b>System VM</b></u> are used to simulate complete working of an operating system or hardware.<br />
e.g.<br />
Virtual PC, VMWare, etc.<br />
<br />
<br />
<u><b>Process VM</b></u> are used to support an operating system in the execution of an application.<br />
<br />
e.g.<br />
JVM, CLR(Common Language Runtime used in Dot Net), DVM, etc.<br />
<br />
Process VM To Be Continued.........<br />
<br />Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-40502608998080156582012-11-12T14:44:00.000+05:302012-12-14T14:12:01.742+05:30Android Vs. J2ME<h2>
Android Vs. J2ME(Java 2 Micro Edition) </h2>
<h2>
</h2>
In Conventional model of mobile application or say J2ME, we have two major problems:-<br />
<br />
<ol>
<li>Third Party Apps were treated as second class citizen i.e. all the system resources were not available to them and in case of processor/memory request, they were killed first.</li>
<li>To develop an app in a native technology native API's and hardware specification must be learned by the developer which were all available to them at large. To develop an application which has complete access to resources, the application development require native libraries which are propriated.</li>
</ol>
<h3>
<a href="http://www.programmingworld4u.blogspot.in/2012/10/android-introduction.html" target="_blank">Android</a> vs. J2ME using FLOW Diagram </h3>
<div class="separator" style="clear: both; text-align: center;">
</div>
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-_1AuNNFEPlE/UKC8ycpyIYI/AAAAAAAAAJ4/eaOMGSDqJ0o/s1600/android_vs._j2me.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img alt="Android vs. J2ME" border="0" src="http://2.bp.blogspot.com/-_1AuNNFEPlE/UKC8ycpyIYI/AAAAAAAAAJ4/eaOMGSDqJ0o/s1600/android_vs._j2me.png" height="456" title="Android vs. J2ME" width="640" /></a></div>
<div style="text-align: center;">
Click on the pic to view the complete diagram</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-77867489180113919542012-11-01T23:53:00.000+05:302012-12-14T14:12:29.745+05:30Android Architecture<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-bVPOdjE27Ss/UJK-kh0HslI/AAAAAAAAAJg/EuLpEiq0Z14/s1600/Android+Architecture.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" src="http://2.bp.blogspot.com/-bVPOdjE27Ss/UJK-kh0HslI/AAAAAAAAAJg/EuLpEiq0Z14/s1600/Android+Architecture.jpg" height="150" width="200" /></a></div>
<h3 style="text-align: center;">
<b>Architecture of <a href="http://www.programmingworld4u.blogspot.in/2012/10/android-introduction.html" target="_blank">Android</a></b></h3>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
Application</div>
<div style="text-align: center;">
Native App 3rd Party App Developer App </div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
↕</div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
Application Framework</div>
<div style="text-align: center;">
(Set of API's written in java to provide productive app developement)</div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
↕ ↕</div>
<div style="text-align: left;">
<br /></div>
<div style="text-align: left;">
Native Library Dalvik Virtual Machine </div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
↕ ↕</div>
<div style="text-align: center;">
<br /></div>
<div style="text-align: center;">
Linux Kernel</div>
<div style="text-align: center;">
Device Drivers Power Mgt. Memory Mgt. Process Mgt. </div>
<div style="text-align: center;">
<br /></div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-17702100010198875532012-10-10T21:35:00.000+05:302012-10-10T21:35:20.428+05:30Android Introduction<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-zbIVjFAZ7L0/UHWZug4-T7I/AAAAAAAAAG0/fNw2mHCE-q0/s1600/android.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" height="284" src="http://1.bp.blogspot.com/-zbIVjFAZ7L0/UHWZug4-T7I/AAAAAAAAAG0/fNw2mHCE-q0/s320/android.jpg" width="320" /></a></div>
<b>Android</b> is an <b>open source</b> mobile platform provided by Google which comprises of mobile operating system, Application development framework, Run-time environment and some applications developed in Android.<br />
<br />
Android is like an <b>Software Stack </b>which provides the facility to develope, to deploy and to execute an application. Software Stack means more than one software includess.<br />
<br />
In short, Android is Linux based open source mobile application development platform or say mobile based operating system.<br />
<br />
There are two types of mobile operating system:-<br />
<ol style="text-align: left;">
<li>Propritate OS</li>
<li>Open Source</li>
</ol>
Propritate OS means you can't change the Operating system files and we have to take license for developing applications in that OS i.e. we have to pay money for developing applications in propritate OS.<br />
e.g.<br />
I O.S. and Blackberry<br />
<br />
Open Source OS means you can change the operating files and we don't have to take license for developing application in that OS.<br />
e.g.<br />
Android <br />
<br />
One of the best thing in android is that it is open source so that we don't have to pay to create application in this or to use its API's.<br />
<br />
<br />
To be Continued...........</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-20314057099955925592012-09-29T16:45:00.002+05:302012-09-29T16:50:34.517+05:30C Introduction<div dir="ltr" style="text-align: left;" trbidi="on">
<h3 style="text-align: left;">
<b>Introduction TO C language: </b> </h3>
<div style="text-align: left;">
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-yKO39kEWSuI/UGbWzV2NbGI/AAAAAAAAAEk/m2dqRUYaR3Y/s1600/c_programming_language.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="C Introduction" border="0" height="195" src="http://3.bp.blogspot.com/-yKO39kEWSuI/UGbWzV2NbGI/AAAAAAAAAEk/m2dqRUYaR3Y/s200/c_programming_language.jpg" title="C Introduction" width="200" /></a></div>
C an programming language which is the base language of all the languages like c++, Java, PERL, Limbo, etc.</div>
<div style="text-align: left;">
<br />
<div style="text-align: right;">
</div>
<table cellpadding="0" cellspacing="0" class="tr-caption-container" style="float: right; margin-left: 1em; text-align: right;"><tbody>
<tr><td style="text-align: center;"><a href="http://4.bp.blogspot.com/-7NS6rzOQYsM/UGbZSTbrTGI/AAAAAAAAAE0/mykiEotJbLU/s1600/Dennis+Ritchie+Founder+of+C.jpg" imageanchor="1" style="clear: right; margin-bottom: 1em; margin-left: auto; margin-right: auto;"><img alt="Dennis Ritchie Founder of C" border="0" height="137" src="http://4.bp.blogspot.com/-7NS6rzOQYsM/UGbZSTbrTGI/AAAAAAAAAE0/mykiEotJbLU/s200/Dennis+Ritchie+Founder+of+C.jpg" title="Dennis Ritchie Founder of C" width="200" /></a></td></tr>
<tr><td class="tr-caption" style="text-align: center;">C Introduction</td><td class="tr-caption" style="text-align: center;"><br /></td></tr>
</tbody></table>
C was firstly introduced and developed by <b>Dennis Ritchie</b> in <b>1969</b> at <b>AT & T Bell Laboratory</b>.</div>
<div style="text-align: left;">
<br />
<br />
After the C Introduction , the first Operating System is made using C language and known as UNIX.<br />
<br />
<b>UNIX</b> is fully developed in C and known as the most secure Operating System. <br />
<br />
After <b>UNIX</b> then <b>Linux and Windows</b> are developed using one and only <b>C language.</b><br />
<br />
All<b> </b>other languages uses the syntax and structure of C.<br />
<br />
In short, C is the backbone of all other languages.</div>
</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-56030432967683934722012-09-12T23:46:00.006+05:302013-05-01T16:55:39.683+05:30Java Tutorial Asignment<div dir="ltr" style="text-align: left;" trbidi="on">
<a href="http://3.bp.blogspot.com/-j9mgHLK2Uf0/UFWT2vlez7I/AAAAAAAAAEU/FfT0hBIpiF8/s1600/thumbtack_note_assignment.png" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="Java Tutorial Asignment" border="0" src="http://3.bp.blogspot.com/-j9mgHLK2Uf0/UFWT2vlez7I/AAAAAAAAAEU/FfT0hBIpiF8/s1600/thumbtack_note_assignment.png" title="Java Tutorial Asignment" /></a><b>Asignment for java tutorial :- </b><br />
<br />
Here am going to tell you about some java tutorial which you use most of the time.<br />
<br />
You can take this as your asignment for java tutorial and which one writes the best, I'll publish that java tutorial on my blog.So just write the best java tutorial on the following topics:-<br />
<br />
<u><br /></u>
<u><br /></u>
<u><br /></u>
<u><br /></u>
<u>1.</u> <b>Write the java examples for printing output like this:-</b><br />
<br />
*<br />
* *<br />
* * *<br />
* * * *<br />
<u>2.</u><b> Write the java examples for swaping two numbers without using a third variable</b>.<br />
<br />
<u>3.</u> <b>Write the java examples for printing output like this:-</b><br />
<br />
1<br />
1 2 1<br />
1 2 2 1<br />
1 2 3 2 1<br />
<br /></div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-4437381478695580742012-09-10T21:23:00.000+05:302013-01-31T13:00:22.907+05:30Adding two numbers using IInd Method(J2SE)<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="separator" style="clear: both; text-align: center;">
</div>
<div style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;">
<div class="separator" style="clear: both; text-align: center;">
<a href="http://3.bp.blogspot.com/-LZcuqwwW2no/UE4MEahiJqI/AAAAAAAAAEE/4WqWP9PoE8A/s1600/addition.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="Adding two numbers" border="0" height="200" src="http://3.bp.blogspot.com/-LZcuqwwW2no/UE4MEahiJqI/AAAAAAAAAEE/4WqWP9PoE8A/s200/addition.jpg" title="Adding two numbers" width="200" /></a></div>
J2SE Programming<br />
<br />
Now m going to write the program for adding two numbers using values via command line arguments.<br />
Command-Line arguments are the arguments which are passed just before run time i.e. after compilation.<br />
Now the problem is how to get the arguments via command line.<br />
Command Line arguments are passed in the String array used in main function as an argument.<br />
Now the numbers are passed as string and we want int then what to do for this.<br />
We have a static method in Integer class i.e. parseInt(String) which takes an argument of type string an returns int and there is a condition that the string passed in this should have a valid int value otherwise there is an run time exception i.e. NumberFormatException.<br />
<br /></div>
<div>
<br /></div>
<div>
Here is the program for this:-</div>
<div>
<br /></div>
<div>
<br /></div>
<table border="1">
<tbody>
<tr>
<td> class abc <br />
{<br />
int a,b,sum;<br />
<br />
public static void main(String[] args)<br />
{<br />
<br />
a=Integer.parseInt(args[0]); //Getting int from string array at position 0<br />
<br />
b=Integer.parseInt(args[1]); //Getting int from string array at position 1<br />
<br />
sum=a+b; //Adding numbers<br />
<br />
System.out.println("Sum = "+sum); // Printing sum<br />
<br />
}<br />
}</td></tr>
</tbody></table>
<br />
<div>
Now how to pass value in that string array.</div>
<div>
Here is the solution:-</div>
<div>
<br /></div>
<div>
Firstly compile it as usual using <b>Javac program.java</b></div>
<div>
Now Run using <b>java program arg1 arg2</b></div>
<div>
<b>arg1 arg2 are the arguments which are the a and b.</b></div>
<div>
<b><br /></b></div>
<div>
<b><br /></b></div>
<div>
<b>For further queries, feel free to contact us any time using our contact us form.</b></div>
<div>
<b>Thank You.</b></div>
<div>
<br /></div>
</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-33285670685074860252012-07-29T14:49:00.000+05:302013-01-31T13:00:49.803+05:30WAP to add two numbers by just assigning values(J2SE).<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="separator" style="clear: both; text-align: center;">
<a href="http://4.bp.blogspot.com/-vaEbQWBUmoQ/UBT7TCjevGI/AAAAAAAAADU/PKiOap1PkEA/s1600/Add.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="Adding two numbers" border="0" height="145" src="http://4.bp.blogspot.com/-vaEbQWBUmoQ/UBT7TCjevGI/AAAAAAAAADU/PKiOap1PkEA/s200/Add.jpg" title="Adding two numbers" width="200" /></a></div>
J2SE Programming<br />
<br />
Now I am going to write a program which adds two numbers.<br />
For this i just want to know about addition operator and two inputs.<br />
As we know, there is one operator known as plus(+) operator can be used to add two inputs.<br />
Now the problem is how to get input for adding numbers.<br />
<br />
There are three ways to get input as follows:-<br />
<ol style="text-align: left;">
<li>One way is just by assigning values.</li>
<li>Second way is by User input during Run-time. </li>
<li>Third way is using Command-Line arguments.</li>
</ol>
Here we are using First way i.e. by Assigning values.<br />
Other ways will be discussed Later.<br />
<br />
<table border="1" style="width: 500px;">
<tbody>
<tr>
<td> class Addition<br />
{<br />
//Main Function<br />
public static void main(String[] args)<br />
{<br />
Addition a1=new Addition();<br />
int a=a1.add(10,20);<br />
System.out.println(Sum is : +a);<br />
}<br />
<br />
//Function to add two numbers<br />
<br />
public int add(int a,int b)<br />
{<br />
<br />
int c=0;<br />
c=a+b;<br />
return c;<br />
<br />
} <br />
}
</td>
</tr>
</tbody></table>
<br />
<br />
Now save it as Addition.java<br />
Compile it using "javac Addition.java" Command in CMD<br />
After compilation Run it using command "java Addition" in CMD<br />
<br /></div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-83861443868986033382012-07-28T00:24:00.001+05:302013-01-31T13:01:08.054+05:30Printing Hello World In Java(J2SE)<div dir="ltr" style="text-align: left;" trbidi="on">
J2SE Programming<br />
<br />
Here now we go for our first program i.e. printing hello world in java.<br />
<br />
class HelloWorld<br />
{<br />
public static void main(String[] args)<br />
{<br />
System.out.println("Hello World");<br />
}<br />
}<br />
<br />
Now compile it as show in fig.<br />
Firstly you have to move into the directory where the file is saved(use cd to move between Directories )<br />
<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://4.bp.blogspot.com/-5cSlzwLHGoE/UBEtuc_G_eI/AAAAAAAAAC4/reQMepk14Uo/s1600/Compile.bmp" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img alt="Print hello world in java" border="0" height="363" src="http://4.bp.blogspot.com/-5cSlzwLHGoE/UBEtuc_G_eI/AAAAAAAAAC4/reQMepk14Uo/s640/Compile.bmp" title="Print hello world in java" width="640" /></a></div>
<br />
Once you have compiled it then Run it as Shown in fig below<br />
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-XlLEnjx39LA/UBLjl8_VxuI/AAAAAAAAADE/qWri7IRncFM/s1600/Run.bmp" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img alt="Print hello world in java" border="0" height="364" src="http://1.bp.blogspot.com/-XlLEnjx39LA/UBLjl8_VxuI/AAAAAAAAADE/qWri7IRncFM/s640/Run.bmp" title="Print hello world in java" width="640" /></a></div>
<br />
<br /></div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com1tag:blogger.com,1999:blog-2624188554438759336.post-199985945486248272012-07-25T22:16:00.000+05:302013-01-31T13:00:01.188+05:30Starting Java(J2SE) Programming<div dir="ltr" style="text-align: left;" trbidi="on">
<div class="separator" style="clear: both; text-align: center;">
<a href="http://2.bp.blogspot.com/-HfRdnjoejLM/UBAhtWyMSwI/AAAAAAAAACo/kdgFbMZSTVE/s1600/startProgramming.jpg" imageanchor="1" style="clear: right; float: right; margin-bottom: 1em; margin-left: 1em;"><img alt="Start Java Programming" border="0" height="320" src="http://2.bp.blogspot.com/-HfRdnjoejLM/UBAhtWyMSwI/AAAAAAAAACo/kdgFbMZSTVE/s320/startProgramming.jpg" title="Start Java Programming" width="259" /></a></div>
J2SE Programming<br />
<br />
As we know there are three types of programming we can do in Java. One is Console Based, second is Window Based and third one is Web-Based.<br />
We start firstly with Console based.<br />
<br />
Before Actual working, I tell some syntax used in java<br />
<b>Class syntax :</b> class <class_name><br />
{<br />
//code to do<br />
}<br />
e.g.<br />
class abc<br />
{<br />
//code<br />
}<br />
<br />
<b>Method Declaration :</b> access_specifier return_type <function_name>(Argument List)<br />
{<br />
//Code to do<br />
}<br />
e.g.<br />
public void doStuff()<br />
{<br />
System.out.println("DoStuff");<br />
}<br />
<br />
<b>Variable Declaration : </b>type <variable_name>;<br />
<br />
e.g. int a;<br />
<br />
<b>Variable Intialization : </b>name=<variable_value>;<br />
<br />
e.g. a=10;<br />
<br />
<b>Object Creation : </b>type <reference_name>=new type(Arg List);<br />
<br />
abc a1=new abc();<br />
<br /></div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-90383320795927567252012-07-25T00:42:00.000+05:302013-05-01T16:56:02.443+05:30How java(J2SE) compiler works?<div dir="ltr" style="text-align: left;" trbidi="on">
J2SE Programming<br />
<br />
Here am going to tell you how java compiler works i.e. what is the actual working of java compiler.<br />
<br />
If you write a program in java then it is both compiled and interpreted. The aim of the both compilation and interpretion is just to make program made by you more secure and making it portable i.e. platform independent.<br />
<div>
<br />
<div class="separator" style="clear: both; text-align: center;">
<a href="http://1.bp.blogspot.com/-2gz8Ms3Mxa4/UA7xyF7LGDI/AAAAAAAAACc/gmoT3VjqfbE/s1600/java-compiler.gif" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img alt="Java Compiler Working" border="0" height="168" src="http://1.bp.blogspot.com/-2gz8Ms3Mxa4/UA7xyF7LGDI/AAAAAAAAACc/gmoT3VjqfbE/s320/java-compiler.gif" title="Java Compiler" width="320" /></a></div>
<br /></div>
<div>
Now What actually happen when you compile a java program:-</div>
<div>
<ol style="text-align: left;">
<li>Firstly it is compiled for any error like Syntax error,etc.</li>
<li>Once it is compiled, code is generated by the compiler known as BYTE Code which is some binary code can't be understandable by the Humans.The file generated by compiler has a extension of .class</li>
<li>Like if you compile a file named First.java, then compiler generates a file named First.class which can be viewed using notepad but can't be understanded.</li>
<li>Once the byte code is generated, it can be run on any platform.Here run means Interpreting the byte code and providing the appropriate output.</li>
<li>There is one another thing in java which makes it more efficient i.e JIT(Just In Time Compiler) which is a part of JVM( Java Virtual Machine) which converts only necessary code to executable code e.g. if then is an if condition which is already known that else part will be executed then JIT converts only that else part to the executable code but not the if part. JIT Comes in action during Run Time.</li>
<li>After that the appropriate output is shown on the screen.</li>
</ol>
</div>
</div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0tag:blogger.com,1999:blog-2624188554438759336.post-53777100092248791922012-07-23T18:31:00.000+05:302013-01-31T13:01:28.922+05:30Java(J2SE) Intro<div dir="ltr" style="text-align: left;" trbidi="on">
<a href="http://3.bp.blogspot.com/-df7uUtIiCLk/UA1G5VwQ-KI/AAAAAAAAACI/9u4jz3X4IdY/s1600/41eff1e0-1a3e-42aa-84f8-0bfd200c8a54.jpg" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img alt="Java Introduction" border="0" height="200" src="http://3.bp.blogspot.com/-df7uUtIiCLk/UA1G5VwQ-KI/AAAAAAAAACI/9u4jz3X4IdY/s200/41eff1e0-1a3e-42aa-84f8-0bfd200c8a54.jpg" title="Java Introduction" width="200" /></a><br />
<b>JAVA INTRO</b> <br />
<br />
<br />
J2SE Programming<br />
<br />
Java , a programming language which is fully based on oops concept was developed by James Gosling in 1992 at Sun Microsystem.It was initially called as OAK.<br />
Java is accepted as a core component of the organisation in 1995<br />
Syntax used in java are much similar to used in C and C++.<br />
<br />
Java is both Compiled and interpreted which is the best feature of it to make it secure.<br />
<br />
<br />
<br />
<br />
It is an <b>platform independent programming language</b> in which following work can be carried out:-<br />
<br />
<ul style="text-align: left;">
<li><span style="background-color: white;">Console Based applications</span></li>
<li><span style="background-color: white;">Window Based Applications
</span></li>
<li><span style="background-color: white;">Web Based Applications</span></li>
</ul>
<br />
<b>Features In Java:-</b><br />
<br />
<br />
<ul style="text-align: left;">
<li><span style="background-color: white;">Simple</span></li>
<li><span style="background-color: white;">Object Oriented language.
</span></li>
<li><span style="background-color: white;">Robust</span></li>
<li><span style="background-color: white;">Secure Language</span></li>
<li><span style="background-color: white;">Easy-to-understand</span></li>
<li><span style="background-color: white;">Multi-threded</span></li>
<li><span style="background-color: white;">Interpreted</span></li>
<li><span style="background-color: white;">Distributed</span></li>
<li><span style="background-color: white;">Dynamic</span></li>
<li><span style="background-color: white;">Portable</span></li>
</ul>
<br />
<br />
<br /></div>
Anonymoushttp://www.blogger.com/profile/16199793346131098071noreply@blogger.com0