<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-7191641637792066842</id><updated>2011-11-27T15:33:11.604-08:00</updated><category term='Java lesson 18'/><category term='Graphical User Interfaces in Java'/><category term='Data with phonetic characters using Easy IPA'/><category term='Assignment and Equality in Java'/><category term='Managing Simple Events and Interactivity'/><category term='and Effects'/><category term='Appendix C'/><category term='Java lesson 12'/><category term='Ballworld'/><category term='Java lesson 20'/><category term='Design Patterns for Sorting'/><category term='Exceptions in Java'/><category term='List Structure and the Composite Design Pattern'/><category term='Learning Objects for Arrays in Java'/><category term='Java lesson 19'/><category term='Drag and Drop Basics'/><category term='Java lesson 21'/><category term='List Structure and the Interpreter Design Pattern'/><category term='Events'/><category term='Visitor Design Pattern'/><category term='Composite Design PatternComposite Design Pattern'/><category term='Appendix B'/><category term='Java lesson 5'/><category term='Java lesson 11'/><category term='Executing a Java Program'/><category term='Arrays and Array Processing'/><category term='What is exception?'/><category term='Java GUI Programming'/><category term='Java lesson 6'/><category term='Mutable Linear Recursive Structure'/><category term='Recursion'/><category term='java basics'/><category term='Algorithm Overview'/><category term='2011 latest J2SE Projects - JAVA'/><category term='Handling Keyboard Events'/><category term='Union Design Pattern: Inheritance and Polymorphism'/><category term='Java lesson 10'/><category term='Mobile Application Development using JME (J2ME)'/><category term='composition-based'/><category term='Java lesson 7'/><category term='What is OOP and Why Should I Care?'/><category term='2011 latest J2ME Projects - JAVA'/><category term='Learning Objects for Java (Overview)'/><category term='Strategy Design Pattern'/><category term='Structural Errors in Java'/><category term='Java lesson 8'/><category term='Digging Deeper into ActionScript Events'/><category term='Abstraction'/><category term='Ordering Object and Priority Queue'/><category term='Java lesson 16'/><category term='Restricted Access Containers'/><category term='Java lesson 2'/><category term='Debugging Java Programs Without a Debugger'/><category term='Appendix A'/><category term='Learning Objects for Inheritance in Java'/><category term='Bitmap Basics'/><category term='Animation Fundamentals'/><category term='Java lesson 24'/><category term='Parallel Programming with MapReduce'/><category term='Learning Objects for Methods in Java'/><category term='Objects and Classes'/><category term='UML Diagrams'/><category term='Java lesson 15'/><category term='State Design Pattern'/><category term='Java lesson 9'/><category term='Learning Objects for Constructors in Java'/><category term='DrJava'/><category term='Computers and Programming'/><category term='Adapter Design Pattern'/><category term='Finite State Machines and the State Design Pattern'/><category term='Binary Search Tree'/><category term='Java lesson 1'/><category term='Syntax Errors in Java'/><category term='Unit Testing with JUnit in DrJava'/><category term='Java Syntax Primer'/><category term='Introducing Compile and Runtime Errors in Java'/><category term='Creating Custom Effects'/><category term='getting started java programs'/><category term='Binary Tree Structure'/><category term='Java tutorials'/><category term='Java design pattern'/><category term='java downloads'/><category term='Combining Sound with Motion and Image Animation'/><category term='Triggers'/><category term='inheritance-based'/><category term='Advanced CNXML using Edit-in-Place'/><category term='Decorator Design Pattern'/><category term='StarUML Tutorial'/><category term='Java lesson 14'/><category term='Java lesson 4'/><category term='Learning Objects for Control Structures in Java'/><category term='Encapsulation - The Big Picture'/><category term='Objects and Object-Orientated Programming'/><category term='Abstract Factory Design Pattern'/><category term='Sound in ActionScript'/><category term='Threads and I / O non-blocking'/><category term='Inner Classes'/><category term='Java lesson 13'/><category term='Inheritance - The Big Picture'/><category term='Image Pixel Processing'/><category term='Java lesson 3'/><category term='Object Relationships'/><title type='text'>Java</title><subtitle type='html'>Share Your Ideas Through Comments</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>96</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-4794525524128026396</id><published>2011-02-06T12:31:00.000-08:00</published><updated>2011-02-06T12:31:32.223-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='2011 latest J2ME Projects - JAVA'/><title type='text'>2011 latest J2ME Projects - JAVA</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #282828; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 18px;"&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;&lt;b&gt;2011 latest J2ME Projects - JAVA&amp;nbsp;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #cc0000;"&gt;Share your J2me Project ideas through comments&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: #cc0000;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; share your&amp;nbsp;&lt;span class="IL_AD" id="IL_AD12" style="background-attachment: scroll !important; background-clip: initial !important; background-color: transparent !important; background-image: none !important; background-origin: initial !important; background-position: 0% 50%; background-repeat: repeat repeat !important; border-bottom-color: rgb(255, 102, 0) !important; border-bottom-style: dotted !important; border-bottom-width: 1px !important; color: rgb(255, 102, 0) !important; cursor: pointer !important; display: inline !important; float: none !important; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif !important; font-size: 13px !important; font-style: normal !important; font-weight: bold !important; padding-bottom: 1px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static;"&gt;knowledge&lt;/span&gt;&amp;nbsp;and help others&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: #cc0000;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; Share your data and&amp;nbsp;&lt;span class="IL_AD" id="IL_AD5" style="background-attachment: scroll !important; background-clip: initial !important; background-color: transparent !important; background-image: none !important; background-origin: initial !important; background-position: 0% 50%; background-repeat: repeat repeat !important; border-bottom-color: rgb(255, 102, 0) !important; border-bottom-style: dotted !important; border-bottom-width: 1px !important; color: rgb(255, 102, 0) !important; cursor: pointer !important; display: inline !important; float: none !important; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif !important; font-size: 13px !important; font-style: normal !important; font-weight: bold !important; padding-bottom: 1px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static;"&gt;project codes&lt;/span&gt;&amp;nbsp;through comments&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Study on Travel Route Intelligent Navigation System Based on WEBGIS&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;this paper presents the system architecture, key technology and system realization for the travel route intelligent navigation system based on WEBGIS. Combining with Oracle spatial database and MapXtreme technology and using comprehensively position service, GIS and data mining and according to the traveler’s type, preference, characteristics and requirement, the system can provide user information management, intelligent information processing and travel route planning services intelligently and personally.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Data Mining, WEBGIS, GIS, MaxExtreme.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;web gis; tourism; travel route planning; travel route navigation&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java, J2ME.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Speedy, Mini and Totally Fuzzy: Three Ways for Fuzzy Sequential Patterns Mining&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Most real world databases are constituted from historical and numerical data such as sensors, scienti c or even demographic data. In this context, algorithms extracting sequential patterns, which are well adapted to the temporal aspect of the data, do not allow processing numerical information. Therefore the data are pre-processed to be transformed into a binary representation which leads to a loss of information. Algorithms have been proposed to process numerical data using intervals and particularly fuzzy intervals. With regards to the search of sequential patterns based on fuzzy intervals, both existing methods are incomplete either in the processing of sequences or in the support computation. Therefore this paper proposes three methods to mine fuzzy sequential patterns (SPEEDYFUZZY MINIFUZZY and TOTALLYFUZZY). We detail these algorithms by highlighting their different fuzzi cation levels.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Fuzzy Sequential Pattern, Data Minining&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;SPEEDYFUZZY, MINIFUZZY&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,Windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Automatic Form Filling on Mobile Devices&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Filling out forms of web based services on mobile devices is a very time consuming and frustrating task for users because of the limited text input capabilities. This is a critical point to get a wide acceptance of such services, especially mobile commerce that often requires filling user data. We developed an architecture based on a local proxy on a mobile device and a lightweight algorithm for a comprehensive analysis of forms, which leads to the highest probable user data to be filled in, driven by an initial rule set [1]. We further discuss our implementation and the evaluation results of the algorithm as well as the usability of the prototype.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;J2ME, J2SE&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile, NTT DoCoMo, PDA,&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,Windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Optimal resource allocation on grid systems for maximizing service reliability using a genetic algorithm&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid computing system is different from conventional distributed computing systems by its focus on large-scale resource sharing and open architecture for services. The global grid technologies and the Globus Toolkit in particular, are evolving toward an open grid service architecture (OGSA) with which a grid system provides an extensible infrastructure so that various organizations can offer their own services and integrate their resources. Hence, this paper aims at solving the problem of optimally allocating services on the grid tomaximize the grid service reliability. Since no existing study has analyzed the grid service reliability, this paper develops initial modeling and evaluation algorithms to evaluate the grid service reliability. Based on the grid service reliability evaluation, we present an optimization model for the grid service allocation problem and develop a genetic algorithm (GA) to effectively solve it. A numerical example is given to show the modeling procedures and efficiency of the GAs.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid Computing, Open grid servic architecture&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid service reliability; Genetic algorithm; Graph theory; Optimization; Resource management&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Service Composition in UML&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;As the number of available web services is steadily increasing, there is a growing interest for reusing basic web services in new, composite web services. Several organizations have proposed composition languages (BPML, BPMN, BPEL4WS, BPSS, WSCI), but no winner has been declared so far. This paper proposes a method that uses UML Activity models to design web service compositions, and OMG's Model Driven Architecture (MDA) to generate executable specifications in different composition languages. The method utilizes standard UML constructs with a minimal set of extensions for web services. An important step in the method is the transformation of WSDL descriptions into UML. This information is used to complete the composition models.Another key aspect of the method is its independence of the web service composition language. The user can thus select his preferred composition language.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Service,UML&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;BPML, BPMN, BPEL4WS, BPSS, WSCI, WSDL, WorkSCo&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,Windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Ping Identity over the cloud computing&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Now days, the mechanism of ping identity is widely in order to provide the security and digital identity to the important products. Thus the services of ping identity means the digital identity management are crucial in order to authenticate the users and providing the dynamic access control to services in the infrastructures of cloud computing. These kinds of mechanisms are mostly based on the properties of user identity and histories of past interactions. This services needs to preserve the user’s privacy, during the same time enhancing the multiple domains interoperability and simplifying the identity verification management. Therefore in this proposed research work, we are introducing the new methods and approaches in order to address such requirement which is based on the policies for the high level verification presented in terms of protocols of zero knowledge proof, identity attributes, techniques of semantic matching etc. Our main aim is to design the architecture with the proposed basic techniques and analyze the performance results for the same.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Cloud Computing, Ping Idenity&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Users Privacy, Zero Knowledge proof, Web Policies&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java and Ms-Sqlserver&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java Based Intelligent Drip Irrigation Control&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This project defines the implementation of a Java driven intelligent and completely automated drip irrigation system. The software and hardware combined together provide a very advanced control over the currently implemented manual system. The implementation involves use of valve control, drip control and pump control using a microcontroller based board. The java driven software is used to interface and control the valve timings. An additional ADC board is provided to collect moisture level feedback from various regions of the field. This helps the user in collecting different feedback from different areas of the field where separate breeds of crops can be cultivated accordingly.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Networking Based&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ADC board&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile Based Remote Process Control&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This project describes mobile remote hardware control architecture. It is very suitable for industries, remote laboratories, etc. The idea is to set up a central terminal equipped with a GSM Modem at the industry/laboratory, which can be used to transmit/receive data and/or commands to and from the administrator/s. The data can be anything from boiler temperature to gas concentration values, etc. and the commands can be anything from Relay on/off to Motor control, speed control, PWM control, threshold setting, etc. The entire process control job can be made remote using this architecture.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile Computing&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;STP,T145,GSM,PWM control.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,J2ME&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Enforcing Minimum-Cost Multicast Routing against Selfish Information Flows&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;We study multicast in a noncooperative environment where information flows selfishly route themselves through the cheapest paths available. The main challenge is to enforce such selfish multicast flows to stabilize at a socially optimal operating point incurring minimum total edge cost, through appropriate cost allocation and other economic measures, with replicable and encodable properties of information flows considered. We show that known cost allocation schemes are not sufficient. We provide a shadow-price-based cost allocation for networks without capacity limits and show that it enforces minimum-cost multicast. This improves previous result where a approximate multicast flow is enforced. For capacitated networks, computing cost allocation by ignoring edge capacities will not yield correct results. We show that an edge tax scheme can be combined with a cost allocation to strictly enforce optimal multicast flows in this more realistic case. If taxes are not desirable, they can be returned to flows while maintaining weak enforcement of the optimal flow. We relate the taxesto VCGpaymentschemesand discussan efficientprimal-dualalgorithmthatsimultaneously computesthe taxes,the cost allocation, and the optimal multicast flow, with potential of fully distributed implementations.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Parallel &amp;amp; Distributed Systems&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;LP Formulations, Primal &amp;amp; Dual, Communication/networking, multicast, graph algorithms.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java with windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Encrypted Voice Calls with IP enabled Wireless Phones over GSM/ CDMA/ WiFi Networks&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;A research on the related technology and implementation of IP phone based on WiFi network is discussed in this paper; it includes the net structure of the technology used in designing the terminal of IP phone. This technology is a form of telecommunication that allows data and voice transmissions to be sent across a wide range of interconnected networks. A WiFi enabled IP phone is used which is preinstalled with the Symbian Operating System and a software application is developed using J2ME which allows free and secured communication between selected IP phones in the WiFi network. This communication is done with the use of routing tables organized in the WiFi routers. Using the free bandwidth of 2.4 GHz communication channels are established. The communication channel being a free bandwidth is vulnerable to external attacks and hacking. Thereby this challenge of creating a secure communication channel is addressed by using two different encryption mechanisms. The payload and header of the voice data packets encrypted using two different algorithm techniques. Hence the communication system is made almost fully secure. Also the WiFi server can tunnel the calls to the GSM network using UNC. Moreover the creation of a vertical handoff protocol will provide seamless communication for users. This handoff is defined in the context of a diverse network environment. It is cost effective, it allows easier communication, is great for international usages, and it can be very useful for large corporations. In time this will become a cheap and secure way to communicate and will have a large effect on university, business and personal communication.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile Computing, Network Security.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;IP phones, Wifi ,Symbian, J2ME, encryption, GSM,UNC.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java with windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Remote Surveillance and Face Tracking with Mobile Phones (Smart Eyes)&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This thesis addresses analysis, evaluation and simulation of low complexity face detection algorithms and tracking that could be used on mobile phones. Network access control using face recognition increases the user-friendliness in human-computer interaction. In order to realize a real time system implemented on handheld devices with low computing power, low complexity algorithms for face detection and face tracking are implemented. Skin color detection algorithms and face matching have low implementation complexity suitable for authentication of cellular network services. Novel approaches for reducing the complexities of these algorithms and fast implementation are introduced in this thesis. This includes a fast algorithm for face detection in video sequences, using a skin color model in the HSV (Hue-Saturation-Value) color space. It is combined with a Gaussian model of the H and S statistics and adaptive thresholds. These algorithms permit segmentation and detection of multiple faces in thumbnail images. Furthermore we evaluate and compare our results with those of a method implemented in the Chromatic Color space (YCbCr). We also test our test data on face detection method using Convolutional Neural Network architecture to study the suitability of using other approaches besides skin color as the basic feature for face detection. Finally, face tracking is done in 2D color video streams using HSV as the histogram color space. The program is used to compute 3D trajectories for a remote surveillance system.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile Computing, Intelligant Systems, J2ME.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Remote Surveillance, Face Tracking, Mobile Phones, Face Detection, HSV Color Space, Face Recognition, Color Histogram, Skin Color Pixel, intensity gradient.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java with windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid Banking System Structure&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Highly computational resource sharing environments like grids pose major security issues. Secure interoperability has been a growing concern for such multi domain computing systems. Collaboration in such a diverse environment requires integration of all local policies to compose a global access control policy for controlling information and resource. Access control in such an environment is still an open problem. The much standardized Role Based Access Control (RBAC) is yet to be fully utilized in a multi domain grid environment like the Grids. Here, we present an architectural framework for adaptation and implementation of RBAC for grid access control. Our approach includes solutions for delegation and revocation in a single domain grid enterprise like bank. The classical Role Based Access Control, though an effective access control standard, does not address the issue of resolving a local role into a global role. So, we also propose architecture based on RBAC, which can establish role equivalence among the domains by mapping a local domain role to its equivalent global role. We use the approach of weighted ranking for the same. The final authorization decision is made based on the mapped global role ranking. And also the resource access policies.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid Banking, Grid Computing.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Role Based Access Control, Grid Banking, resource sharing, authorization policies.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java with windows 2000 onwards and Linux,SQL server 2000 onwards&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;A Role and Attribute Based Access Control System Using Semantic Web Technologies&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;We show how Semantic Web technologies can be used to build an access control system. We follow the role-based access control approach (RBAC) and extend it with contextual attributes. Our approach provides for the dynamic association of roles with users. A Description Logic (DL) reasoner is used to classify both users and resources, and verify the consistency of the access control policies. We mitigate the limited expressive power of the DL formalism by refining the output of the DL reasoner with SPARQL queries. Finally, we provide a proof-ofconcept implementation of the system written in Java&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Based Collaboration, Authorization Models&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;RBAC (Role based access control), ABAC (Attribute Based access control),&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java, J2ME, windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;A Fully Automatic CAD-CTC System Based on Curvature Analysis for Standard and Low-Dose CT Data&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Computed tomography colonography (CTC) is a rapidly evolving noninvasive medical investigation that is viewed by radiologists as a potential screening technique for the detecby radiologists as a potential screening technique for the detection of colorectal polyps. Due to the technical advances in CT system design, the volume of data required to be processed by radiologists has increased significantly, and as a consequence the manual analysis of this information has become an increasingly time consuming process whose results can be affected by inter time consuming process whose results can be affected by interand intrauser variability. The aim of this paper is to detail the implementation of a fully integrated CAD-CTC system that is able to robustly identify the clinically significant polyps in the CT data.The CAD-CTC system described in this paper is a multistage implementation whose main system components are: 1) automatic colon segmentation; 2) candidate surface extraction; 3) feature extraction; and 4) classification. Our CAD-CTC system performs at 100% sensitivity for polyps larger than 10 mm, 92% sensitivity for polyps in the range 5 to 10 mm, and 57.14% sensitivity for polyps smaller than 5 mm with an average of 3.38 false positives per dataset. The developed system has been evaluated on synthetic and real patient CT data acquired with standard and low-dose radiation levels.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Image Processing.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Classification, computed tomography (CT), convexity&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java,windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Patient Centric Medical Information System using Web Services&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This Software Requirements Specification provides a complete description of all the functions and specifications for the purpose of the project on Patient Centric Medical Information System Using Web Services. This Medical Information System deals with the Tuberculosis related data for the patients provided by means of Web Services. This system is beneficial for use mainly by the outdoor patients and medical professionals.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Services&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Proxy Server,Web Portal.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,J2ME.windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-size: 12px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;ProjectName&lt;/td&gt;&lt;td&gt;E-Learning as a Web Service&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;Abstract&lt;/td&gt;&lt;td&gt;E-learning has been a topic of increasing interest in recent years. It is often perceived as a group effort, where content authors, instructional designers, multimedia technicians, teachers, trainers, database administrators, and people from various other areas of expertise come together in order to serve a community of learners On the other hand, there are increasingly many activities which aim at providing services of any kind on the Web [9]; these can occur as business-tobusiness or as business-to-consumer services and are generally subsumed under the term Web services. In this paper we suggest to combine the areas of e-learning and Web services, by providing electronic learning offerings as (individual ) Web services as well. We elaborate on this by showing how content providers and content consumers (i.e., learners) can communicate appropriately through a Web service platform with its common description publication, and retrieval functionalities. Finally, we indicate how a corresponding system can be realized.&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;Domains&lt;/td&gt;&lt;td&gt;Web Services&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;Keywords&lt;/td&gt;&lt;td&gt;SOAP, WDSL, UML, BPEL.&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;H/w &amp;amp; S/w&lt;/td&gt;&lt;td&gt;Java,J2ME.Windows/Linux&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7191641637792066842-4794525524128026396?l=java-basics.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/4794525524128026396/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://java-basics.blogspot.com/2011/02/2011-latest-j2me-projects-java.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/4794525524128026396'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/4794525524128026396'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/2011/02/2011-latest-j2me-projects-java.html' title='2011 latest J2ME Projects - JAVA'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-6015185541584011258</id><published>2011-02-06T12:20:00.000-08:00</published><updated>2011-02-06T12:20:26.556-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='2011 latest J2SE Projects - JAVA'/><title type='text'>2011 latest J2SE Projects - JAVA</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;&lt;b&gt;2011 latest J2SE Projects - JAVA&amp;nbsp;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/span&gt;&lt;span class="Apple-style-span" style="color: #cc0000;"&gt;Share your J2Se Project ideas through comments&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: #cc0000;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; share your knowledge and help others&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: #cc0000;"&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; Share your data and project codes through comments&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Advanced Star Coordinates&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;With the development of data collection technology,effective visualization tools are needed urgently to understand the abundant multidimensional and multivariate data and information in the science,engineering and commerce fields. Star Coordinates is a traditional multivariate data visualization technique,but there are some limitations of it. In the paper we propose the Advanced Star Coordinates (ASC), which addresses these drawbacks. ASC uses the diameter instead of the radius as the dimension axis, projects the multidimensional information object to low dimension visual space, which is meaningful to users, and designs the dimension configuration strategy to optimize the order and angle of the dimension axes. The experiment results show that the dimension configuration strategy reduces the user operation burden greatly and helps them explore the connotative characteristics of the multidimensional information aggregation quickly and exactly. The visualization result is easily understandable and expresses the dimension distribution information effectively.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Data Mining, Data Processing.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Star coordinates,data visualization&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Study on Travel Route Intelligent Navigation System Based on WEBGIS&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;this paper presents the system architecture, key technology and system realization for the travel route intelligent navigation system based on WEBGIS. Combining with Oracle spatial database and MapXtreme technology and using comprehensively position service, GIS and data mining and according to the traveler’s type, preference, characteristics and requirement, the system can provide user information management, intelligent information processing and travel route planning services intelligently and personally.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Data Mining, WEBGIS, GIS, MaxExtreme.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;web gis; tourism; travel route planning; travel route navigation&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java, J2ME.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Speedy, Mini and Totally Fuzzy: Three Ways for Fuzzy Sequential Patterns Mining&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Most real world databases are constituted from historical and numerical data such as sensors, scienti c or even demographic data. In this context, algorithms extracting sequential patterns, which are well adapted to the temporal aspect of the data, do not allow processing numerical information. Therefore the data are pre-processed to be transformed into a binary representation which leads to a loss of information. Algorithms have been proposed to process numerical data using intervals and particularly fuzzy intervals. With regards to the search of sequential patterns based on fuzzy intervals, both existing methods are incomplete either in the processing of sequences or in the support computation. Therefore this paper proposes three methods to mine fuzzy sequential patterns (SPEEDYFUZZY MINIFUZZY and TOTALLYFUZZY). We detail these algorithms by highlighting their different fuzzi cation levels.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Fuzzy Sequential Pattern, Data Minining&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;SPEEDYFUZZY, MINIFUZZY&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,Windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Automatic Form Filling on Mobile Devices&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Filling out forms of web based services on mobile devices is a very time consuming and frustrating task for users because of the limited text input capabilities. This is a critical point to get a wide acceptance of such services, especially mobile commerce that often requires filling user data. We developed an architecture based on a local proxy on a mobile device and a lightweight algorithm for a comprehensive analysis of forms, which leads to the highest probable user data to be filled in, driven by an initial rule set [1]. We further discuss our implementation and the evaluation results of the algorithm as well as the usability of the prototype.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;J2ME, J2SE&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile, NTT DoCoMo, PDA,&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,Windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Optimal resource allocation on grid systems for maximizing service reliability using a genetic algorithm&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid computing system is different from conventional distributed computing systems by its focus on large-scale resource sharing and open architecture for services. The global grid technologies and the Globus Toolkit in particular, are evolving toward an open grid service architecture (OGSA) with which a grid system provides an extensible infrastructure so that various organizations can offer their own services and integrate their resources. Hence, this paper aims at solving the problem of optimally allocating services on the grid tomaximize the grid service reliability. Since no existing study has analyzed the grid service reliability, this paper develops initial modeling and evaluation algorithms to evaluate the grid service reliability. Based on the grid service reliability evaluation, we present an optimization model for the grid service allocation problem and develop a genetic algorithm (GA) to effectively solve it. A numerical example is given to show the modeling procedures and efficiency of the GAs.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid Computing, Open grid servic architecture&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid service reliability; Genetic algorithm; Graph theory; Optimization; Resource management&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Service Composition in UML&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;As the number of available web services is steadily increasing, there is a growing interest for reusing basic web services in new, composite web services. Several organizations have proposed composition languages (BPML, BPMN, BPEL4WS, BPSS, WSCI), but no winner has been declared so far. This paper proposes a method that uses UML Activity models to design web service compositions, and OMG's Model Driven Architecture (MDA) to generate executable specifications in different composition languages. The method utilizes standard UML constructs with a minimal set of extensions for web services. An important step in the method is the transformation of WSDL descriptions into UML. This information is used to complete the composition models.Another key aspect of the method is its independence of the web service composition language. The user can thus select his preferred composition language.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Service,UML&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;BPML, BPMN, BPEL4WS, BPSS, WSCI, WSDL, WorkSCo&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,Windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Ping Identity over the cloud computing&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Now days, the mechanism of ping identity is widely in order to provide the security and digital identity to the important products. Thus the services of ping identity means the digital identity management are crucial in order to authenticate the users and providing the dynamic access control to services in the infrastructures of cloud computing. These kinds of mechanisms are mostly based on the properties of user identity and histories of past interactions. This services needs to preserve the user’s privacy, during the same time enhancing the multiple domains interoperability and simplifying the identity verification management. Therefore in this proposed research work, we are introducing the new methods and approaches in order to address such requirement which is based on the policies for the high level verification presented in terms of protocols of zero knowledge proof, identity attributes, techniques of semantic matching etc. Our main aim is to design the architecture with the proposed basic techniques and analyze the performance results for the same.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Cloud Computing, Ping Idenity&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Users Privacy, Zero Knowledge proof, Web Policies&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java and Ms-Sqlserver&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java Based Intelligent Drip Irrigation Control&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This project defines the implementation of a Java driven intelligent and completely automated drip irrigation system. The software and hardware combined together provide a very advanced control over the currently implemented manual system. The implementation involves use of valve control, drip control and pump control using a microcontroller based board. The java driven software is used to interface and control the valve timings. An additional ADC board is provided to collect moisture level feedback from various regions of the field. This helps the user in collecting different feedback from different areas of the field where separate breeds of crops can be cultivated accordingly.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Networking Based&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ADC board&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile Based Remote Process Control&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This project describes mobile remote hardware control architecture. It is very suitable for industries, remote laboratories, etc. The idea is to set up a central terminal equipped with a GSM Modem at the industry/laboratory, which can be used to transmit/receive data and/or commands to and from the administrator/s. The data can be anything from boiler temperature to gas concentration values, etc. and the commands can be anything from Relay on/off to Motor control, speed control, PWM control, threshold setting, etc. The entire process control job can be made remote using this architecture.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile Computing&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;STP,T145,GSM,PWM control.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,J2ME&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;2D/3D Web Content Visualization Toolkit&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This project describes a three-dimensional search engine visualization tool that is used to explore and display search results from a standard search engine. This tool provides an alternate representation of the conventional search engines and allows three-dimensional navigation through the file system. This tool can be developed using Java2D and its three-dimensional extension API called Java 3D. The tool allows different customization options such as change the shape of objects in the world, and their colour. The design and implementation of the tool is discussed and further extensions are provided.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Application&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java2D,Java 3D.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java J2SE&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Enforcing Minimum-Cost Multicast Routing against Selfish Information Flows&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;We study multicast in a noncooperative environment where information flows selfishly route themselves through the cheapest paths available. The main challenge is to enforce such selfish multicast flows to stabilize at a socially optimal operating point incurring minimum total edge cost, through appropriate cost allocation and other economic measures, with replicable and encodable properties of information flows considered. We show that known cost allocation schemes are not sufficient. We provide a shadow-price-based cost allocation for networks without capacity limits and show that it enforces minimum-cost multicast. This improves previous result where a approximate multicast flow is enforced. For capacitated networks, computing cost allocation by ignoring edge capacities will not yield correct results. We show that an edge tax scheme can be combined with a cost allocation to strictly enforce optimal multicast flows in this more realistic case. If taxes are not desirable, they can be returned to flows while maintaining weak enforcement of the optimal flow. We relate the taxesto VCGpaymentschemesand discussan efficientprimal-dualalgorithmthatsimultaneously computesthe taxes,the cost allocation, and the optimal multicast flow, with potential of fully distributed implementations.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Parallel &amp;amp; Distributed Systems&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;LP Formulations, Primal &amp;amp; Dual, Communication/networking, multicast, graph algorithms.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java with windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Encrypted Voice Calls with IP enabled Wireless Phones over GSM/ CDMA/ WiFi Networks&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;A research on the related technology and implementation of IP phone based on WiFi network is discussed in this paper; it includes the net structure of the technology used in designing the terminal of IP phone. This technology is a form of telecommunication that allows data and voice transmissions to be sent across a wide range of interconnected networks. A WiFi enabled IP phone is used which is preinstalled with the Symbian Operating System and a software application is developed using J2ME which allows free and secured communication between selected IP phones in the WiFi network. This communication is done with the use of routing tables organized in the WiFi routers. Using the free bandwidth of 2.4 GHz communication channels are established. The communication channel being a free bandwidth is vulnerable to external attacks and hacking. Thereby this challenge of creating a secure communication channel is addressed by using two different encryption mechanisms. The payload and header of the voice data packets encrypted using two different algorithm techniques. Hence the communication system is made almost fully secure. Also the WiFi server can tunnel the calls to the GSM network using UNC. Moreover the creation of a vertical handoff protocol will provide seamless communication for users. This handoff is defined in the context of a diverse network environment. It is cost effective, it allows easier communication, is great for international usages, and it can be very useful for large corporations. In time this will become a cheap and secure way to communicate and will have a large effect on university, business and personal communication.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile Computing, Network Security.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;IP phones, Wifi ,Symbian, J2ME, encryption, GSM,UNC.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java with windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Remote Surveillance and Face Tracking with Mobile Phones (Smart Eyes)&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This thesis addresses analysis, evaluation and simulation of low complexity face detection algorithms and tracking that could be used on mobile phones. Network access control using face recognition increases the user-friendliness in human-computer interaction. In order to realize a real time system implemented on handheld devices with low computing power, low complexity algorithms for face detection and face tracking are implemented. Skin color detection algorithms and face matching have low implementation complexity suitable for authentication of cellular network services. Novel approaches for reducing the complexities of these algorithms and fast implementation are introduced in this thesis. This includes a fast algorithm for face detection in video sequences, using a skin color model in the HSV (Hue-Saturation-Value) color space. It is combined with a Gaussian model of the H and S statistics and adaptive thresholds. These algorithms permit segmentation and detection of multiple faces in thumbnail images. Furthermore we evaluate and compare our results with those of a method implemented in the Chromatic Color space (YCbCr). We also test our test data on face detection method using Convolutional Neural Network architecture to study the suitability of using other approaches besides skin color as the basic feature for face detection. Finally, face tracking is done in 2D color video streams using HSV as the histogram color space. The program is used to compute 3D trajectories for a remote surveillance system.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Mobile Computing, Intelligant Systems, J2ME.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Remote Surveillance, Face Tracking, Mobile Phones, Face Detection, HSV Color Space, Face Recognition, Color Histogram, Skin Color Pixel, intensity gradient.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java with windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid Banking System Structure&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Highly computational resource sharing environments like grids pose major security issues. Secure interoperability has been a growing concern for such multi domain computing systems. Collaboration in such a diverse environment requires integration of all local policies to compose a global access control policy for controlling information and resource. Access control in such an environment is still an open problem. The much standardized Role Based Access Control (RBAC) is yet to be fully utilized in a multi domain grid environment like the Grids. Here, we present an architectural framework for adaptation and implementation of RBAC for grid access control. Our approach includes solutions for delegation and revocation in a single domain grid enterprise like bank. The classical Role Based Access Control, though an effective access control standard, does not address the issue of resolving a local role into a global role. So, we also propose architecture based on RBAC, which can establish role equivalence among the domains by mapping a local domain role to its equivalent global role. We use the approach of weighted ranking for the same. The final authorization decision is made based on the mapped global role ranking. And also the resource access policies.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Grid Banking, Grid Computing.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Role Based Access Control, Grid Banking, resource sharing, authorization policies.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java with windows 2000 onwards and Linux,SQL server 2000 onwards&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;A Role and Attribute Based Access Control System Using Semantic Web Technologies&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;We show how Semantic Web technologies can be used to build an access control system. We follow the role-based access control approach (RBAC) and extend it with contextual attributes. Our approach provides for the dynamic association of roles with users. A Description Logic (DL) reasoner is used to classify both users and resources, and verify the consistency of the access control policies. We mitigate the limited expressive power of the DL formalism by refining the output of the DL reasoner with SPARQL queries. Finally, we provide a proof-ofconcept implementation of the system written in Java&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Based Collaboration, Authorization Models&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;RBAC (Role based access control), ABAC (Attribute Based access control),&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java, J2ME, windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;A Fully Automatic CAD-CTC System Based on Curvature Analysis for Standard and Low-Dose CT Data&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Computed tomography colonography (CTC) is a rapidly evolving noninvasive medical investigation that is viewed by radiologists as a potential screening technique for the detecby radiologists as a potential screening technique for the detection of colorectal polyps. Due to the technical advances in CT system design, the volume of data required to be processed by radiologists has increased significantly, and as a consequence the manual analysis of this information has become an increasingly time consuming process whose results can be affected by inter time consuming process whose results can be affected by interand intrauser variability. The aim of this paper is to detail the implementation of a fully integrated CAD-CTC system that is able to robustly identify the clinically significant polyps in the CT data.The CAD-CTC system described in this paper is a multistage implementation whose main system components are: 1) automatic colon segmentation; 2) candidate surface extraction; 3) feature extraction; and 4) classification. Our CAD-CTC system performs at 100% sensitivity for polyps larger than 10 mm, 92% sensitivity for polyps in the range 5 to 10 mm, and 57.14% sensitivity for polyps smaller than 5 mm with an average of 3.38 false positives per dataset. The developed system has been evaluated on synthetic and real patient CT data acquired with standard and low-dose radiation levels.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Image Processing.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Classification, computed tomography (CT), convexity&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;java,windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: inherit; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;ProjectName&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Patient Centric Medical Information System using Web Services&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Abstract&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This Software Requirements Specification provides a complete description of all the functions and specifications for the purpose of the project on Patient Centric Medical Information System Using Web Services. This Medical Information System deals with the Tuberculosis related data for the patients provided by means of Web Services. This system is beneficial for use mainly by the outdoor patients and medical professionals.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Domains&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Web Services&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Keywords&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;SOAP, WDSL, UML, BPEL.&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;H/w &amp;amp; S/w&lt;/span&gt;&lt;/td&gt;&lt;td&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Java,J2ME.windows/Linux&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-size: 12px;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;table border="0" cellpadding="4" cellspacing="0" id="DetailsView1" style="border-collapse: collapse; color: #333333; height: 50px; text-align: justify; width: 550px;"&gt;&lt;tbody&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;ProjectName&lt;/td&gt;&lt;td&gt;E-Learning as a Web Service&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;Abstract&lt;/td&gt;&lt;td&gt;E-learning has been a topic of increasing interest in recent years. It is often perceived as a group effort, where content authors, instructional designers, multimedia technicians, teachers, trainers, database administrators, and people from various other areas of expertise come together in order to serve a community of learners On the other hand, there are increasingly many activities which aim at providing services of any kind on the Web [9]; these can occur as business-tobusiness or as business-to-consumer services and are generally subsumed under the term Web services. In this paper we suggest to combine the areas of e-learning and Web services, by providing electronic learning offerings as (individual ) Web services as well. We elaborate on this by showing how content providers and content consumers (i.e., learners) can communicate appropriately through a Web service platform with its common description publication, and retrieval functionalities. Finally, we indicate how a corresponding system can be realized.&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;Domains&lt;/td&gt;&lt;td&gt;Web Services&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: #eff3fb;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;Keywords&lt;/td&gt;&lt;td&gt;Learning Management System (LMS), LOM, SCORM, UDDI.&lt;/td&gt;&lt;/tr&gt;&lt;tr align="justify" style="background-color: white;"&gt;&lt;td style="background-color: #dee8f5; font-weight: bold;"&gt;H/w &amp;amp; S/w&lt;/td&gt;&lt;td&gt;Java,J2ME.Windows/Linux&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7191641637792066842-6015185541584011258?l=java-basics.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/6015185541584011258/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://java-basics.blogspot.com/2011/02/2011-latest-j2se-projects-java.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/6015185541584011258'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/6015185541584011258'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/2011/02/2011-latest-j2se-projects-java.html' title='2011 latest J2SE Projects - JAVA'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-7586226530759105540</id><published>2011-01-21T09:51:00.000-08:00</published><updated>2011-01-21T09:51:51.130-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Java tutorials'/><category scheme='http://www.blogger.com/atom/ns#' term='java downloads'/><category scheme='http://www.blogger.com/atom/ns#' term='getting started java programs'/><title type='text'>Java tutorials</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;&lt;div id="TutBody" style="margin-bottom: 10px; margin-left: 3em; margin-right: 20em; margin-top: 10px;"&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="color: purple; font-family: inherit;"&gt;Click on below links to download&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The Java SE Tutorials primarily describe features in Java SE 6. For best results,&amp;nbsp;&lt;a class="OutsideLink" href="http://www.oracle.com/technetwork/java/javase/downloads/index.html" target="_blank"&gt;download JDK 6&lt;/a&gt;.&lt;/span&gt;&lt;/div&gt;&lt;h3 style="color: #f90000; margin-bottom: 3px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit; font-size: small;"&gt;What's New&lt;/span&gt;&lt;/h3&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;As part of the Oracle Author Podcast Series, a podcast on the Java Tutorials has just been released. You can hear the 10-minute podcast through the&amp;nbsp;&lt;a href="http://www.oracle.com/podcasts/author-podcasts.html"&gt;Oracle Author Podcasts&lt;/a&gt;&amp;nbsp;website.&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Enjoy quizzes? Take a minute to answer this quiz about Java applets.&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorialJWS/flash/AppletQuiz/AppletQuiz.html" target="_blank"&gt;&lt;img alt="Java Applets Quiz" src="http://download.oracle.com/javase/tutorial/images/quiz.jpg" title="Java Applets Quiz" /&gt;&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The Java Tutorials are continuously updated to keep up with changes to the Java Platform and to incorporate feedback from our readers. Included in the most recent release:&lt;/span&gt;&lt;/div&gt;&lt;ul&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;For several months the Java SE Tutorials were not available as a download. We are happy to report that the very popular bundle is back and available through the link under the "Tutorial Resources" box to the right.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Do the Java Tutorials seem overwhelming to you? We have added a new&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorial/tutorialLearningPaths.html"&gt;Learning Paths&lt;/a&gt;&amp;nbsp;page. Please&amp;nbsp;&lt;a href="http://download.oracle.com/javase/feedback.html"&gt;let us know&lt;/a&gt;&amp;nbsp;what you think!&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The new&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorial/essential/concurrency/forkjoin.html"&gt;Fork/Join&lt;/a&gt;&amp;nbsp;page, part of the&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorial/essential/concurrency/index.html"&gt;Concurrency lesson&lt;/a&gt;, describes how you can use the Fork/Join framework to take advantage of multiple processors. This feature is available now in the Java SE 7 release available on&amp;nbsp;&lt;a href="http://dlc.sun.com.edgesuite.net/jdk7/binaries/index.html"&gt;java.net&lt;/a&gt;.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;The&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorial/jdbc/basics"&gt;JDBC Basics&lt;/a&gt;&amp;nbsp;lesson has been completely revamped, including updated sample code that you can download, compile, and run – the code has been configured for Java DB and MySQL. See&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorial/jdbc/basics/gettingstarted.html"&gt;Getting Started&lt;/a&gt;&amp;nbsp;for more information.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;Finally, a small, but notable, change is that the standalone JNDI tutorial, previously available on java.sun.com, has been moved to the Java SE documentation archive on&amp;nbsp;&lt;a href="http://download.oracle.com/javase/jndi/tutorial/"&gt;download.oracle.com&lt;/a&gt;&amp;nbsp;and many broken links in the tutorial have been fixed. The&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorial/jndi/"&gt;front page of the JNDI tutorial&lt;/a&gt;&amp;nbsp;has been modified accordingly, and redirects are in place ensuring a seamless transition.&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;h3 style="color: #f90000; margin-bottom: 3px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit; font-size: small;"&gt;Trails Covering the Basics&lt;/span&gt;&lt;/h3&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;These trails are available in book form as&amp;nbsp;&lt;i&gt;The Java Tutorial, Fourth Edition&lt;/i&gt;. To buy this book, refer to the box to the right.&lt;/span&gt;&lt;/div&gt;&lt;ul class="BlueArrows" style="list-style-image: url(http://download.oracle.com/javase/tutorial/images/ar_dbl_blue.gif);"&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/getStarted/index.html" style="text-decoration: none;"&gt;Getting Started&lt;/a&gt;&amp;nbsp;— An introduction to Java technology and lessons on installing Java development software and using it to create a simple program.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/java/index.html" style="text-decoration: none;"&gt;Learning the Java Language&lt;/a&gt;&amp;nbsp;— Lessons describing the essential concepts and features of the Java Programming Language.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/essential/index.html" style="text-decoration: none;"&gt;Essential Java Classes&lt;/a&gt;&amp;nbsp;— Lessons on exceptions, basic input/output, concurrency, regular expressions, and the platform environment.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/collections/index.html" style="text-decoration: none;"&gt;Collections&lt;/a&gt;&amp;nbsp;— Lessons on using and extending the Java Collections Framework.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/ui/index.html" style="text-decoration: none;"&gt;Swing&lt;/a&gt;&amp;nbsp;— An introduction to the Swing GUI toolkit, with an overview of features and a visual catalog of components. See below for a more comprehensive tutorial on Swing.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/deployment/index.html" style="text-decoration: none;"&gt;Deployment&lt;/a&gt;&amp;nbsp;— How to package applications and applets using JAR files, and deploy them using Java Web Start and Java Plug-in.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/extra/certification/index.html" style="text-decoration: none;"&gt;Preparation for Java Programming Language Certification&lt;/a&gt;&amp;nbsp;— List of available training and tutorial resources.&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;h3 style="color: #f90000; margin-bottom: 3px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit; font-size: small;"&gt;Creating Graphical User Interfaces&lt;/span&gt;&lt;/h3&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;This trail is available in book form as&amp;nbsp;&lt;i&gt;The JFC Swing Tutorial&lt;/i&gt;. To buy this book, refer to the box to the right.&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;ul class="BlueArrows" style="list-style-image: url(http://download.oracle.com/javase/tutorial/images/ar_dbl_blue.gif);"&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/uiswing/index.html" style="text-decoration: none;"&gt;Creating a GUI with Swing&lt;/a&gt;&amp;nbsp;— A comprehensive introduction to GUI creation on the Java platform.&lt;/span&gt;&lt;/li&gt;&lt;/ul&gt;&lt;h3 style="color: #f90000; margin-bottom: 3px; text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit; font-size: small;"&gt;Specialized Trails and Lessons&lt;/span&gt;&lt;/h3&gt;&lt;div style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;These trails and lessons are only available as web pages.&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;ul class="BlueArrows" style="list-style-image: url(http://download.oracle.com/javase/tutorial/images/ar_dbl_blue.gif);"&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/networking/index.html" style="text-decoration: none;"&gt;Custom Networking&lt;/a&gt;&amp;nbsp;— An introduction to the Java platform's powerful networking features.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/ext/index.html" style="text-decoration: none;"&gt;The Extension Mechanism&lt;/a&gt;&amp;nbsp;— How to make custom APIs available to all applications running on the Java platform.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/extra/fullscreen/index.html" style="text-decoration: none;"&gt;Full-Screen Exclusive Mode API&lt;/a&gt;&amp;nbsp;— How to write applications that more fully utilize the user's graphics hardware.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/extra/generics/index.html" style="text-decoration: none;"&gt;Generics&lt;/a&gt;&amp;nbsp;— An enhancement to the type system that supports operations on objects of various types while providing compile-time type safety. Note that this lesson is for advanced users. The&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorial/java/index.html" style="text-decoration: none;"&gt;Java Language&lt;/a&gt;&amp;nbsp;trail contains a&amp;nbsp;&lt;a href="http://download.oracle.com/javase/tutorial/java/generics/index.html" style="text-decoration: none;"&gt;Generics&lt;/a&gt;&amp;nbsp;lesson that is suitable for beginners.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/i18n/index.html" style="text-decoration: none;"&gt;Internationalization&lt;/a&gt;&amp;nbsp;— An introduction to designing software so that it can be easily be adapted (localized) to various languages and regions.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/javabeans/index.html" style="text-decoration: none;"&gt;JavaBeans&lt;/a&gt;&amp;nbsp;— The Java platform's component technology.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/jdbc/index.html" style="text-decoration: none;"&gt;JDBC Database Access&lt;/a&gt;&amp;nbsp;— Introduces an API for connectivity between the Java applications and a wide range of databases and a data sources.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/jmx/index.html" style="text-decoration: none;"&gt;JMX&lt;/a&gt;— Java Management Extensions provides a standard way of managing resources such as applications, devices, and services.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/jndi/index.html" style="text-decoration: none;"&gt;JNDI&lt;/a&gt;— Java Naming and Directory Interface enables accessing the Naming and Directory Service such as DNS and LDAP.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/jaxp/index.html" style="text-decoration: none;"&gt;JAXP&lt;/a&gt;&amp;nbsp;— Introduces the Java API for XML Processing (JAXP) 1.4 technology.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/rmi/index.html" style="text-decoration: none;"&gt;RMI&lt;/a&gt;&amp;nbsp;— The Remote Method Invocation API allows an object to invoke methods of an object running on another Java Virtual Machine.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/reflect/index.html" style="text-decoration: none;"&gt;Reflection&lt;/a&gt;&amp;nbsp;— An API that represents ("reflects") the classes, interfaces, and objects in the current Java Virtual Machine.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/security/index.html" style="text-decoration: none;"&gt;Security&lt;/a&gt;&amp;nbsp;— Java platform features that help protect applications from malicious software.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/sound/index.html" style="text-decoration: none;"&gt;Sound&lt;/a&gt;&amp;nbsp;— An API for playing sound data from applications.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/2d/index.html" style="text-decoration: none;"&gt;2D Graphics&lt;/a&gt;&amp;nbsp;— How to display and print 2D graphics in applications.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;span class="Apple-style-span" style="font-family: inherit;"&gt;&lt;a href="http://download.oracle.com/javase/tutorial/sdp/index.html" style="text-decoration: none;"&gt;Sockets Direct Protocol&lt;/a&gt;&amp;nbsp;— How to enable the Sockets Direct Protocol to take advantage of InfiniBand.&lt;/span&gt;&lt;/li&gt;&lt;li style="text-align: justify;"&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7191641637792066842-7586226530759105540?l=java-basics.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/7586226530759105540/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://java-basics.blogspot.com/2011/01/java-tutorials.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/7586226530759105540'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/7586226530759105540'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/2011/01/java-tutorials.html' title='Java tutorials'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-7308310124653149103</id><published>2011-01-14T01:40:00.001-08:00</published><updated>2011-01-14T01:40:15.827-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Computers and Programming'/><title type='text'>Computers and Programming</title><content type='html'>&lt;div class="section" id="id-803755378301" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Hardware and Software&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id38176052" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;computer&lt;/em&gt;&amp;nbsp;is a device capable of performing computations and making logical decisions at speeds millions and even billions of times faster than human beings can. For example, many of today’s personal computers can perform hundreds of millions of additions per second.&lt;/div&gt;&lt;div class="para" id="id41463590" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Computers process data under the control of sets of instructions called&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;computer programs&lt;/em&gt;. These computer programs guide the computer through orderly sets of actions specified by people called computer programmers.&lt;/div&gt;&lt;div class="para" id="id41295639" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A computer is comprised of various devices (such as the keyboard, screen, “mouse”, disks, memory, CD-ROM and processing units) that are referred to as&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;hardware&lt;/em&gt;. The computer programs that run on a computer are referred to as&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;software&lt;/em&gt;.&lt;/div&gt;&lt;div class="section" id="id-753462756963" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Computer Hardware&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id36127903" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Almost every computer may be seen as being divided into six logical units. Figure 1 illustrates the main computer components.&lt;/div&gt;&lt;div class="section" id="id-949981397446" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Input Unit&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id40661677" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This unit obtains information from various input devices and places this information at the disposal of the other units so that the information may be processed. The information is entered into computers today through keyboards and mouse devices.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-551609325772" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Output Unit&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id37964905" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This unit takes information that has been processed by the computer and places it on various output devices to make information available for use outside the computer. Most output from computer today is displayed on screens, printed on paper, or used to control other devices.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-305393307728" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Memory Unit&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id32798240" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The memory unit stores information. Each computer contains memory of two main types:&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;RAM&lt;/em&gt;&amp;nbsp;and&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;ROM&lt;/em&gt;.&lt;/div&gt;&lt;div class="para" id="id40899014" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;RAM&lt;/em&gt;&amp;nbsp;(random access memory) is volatile. Your program and data are stored in RAM when you are using the computer.&lt;/div&gt;&lt;div class="figure" id="id40724352" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 1:&amp;nbsp;&lt;/strong&gt;Basic hardware units of a computer&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id11402263"&gt;&lt;img alt="Figure 1 (graphics1.png)" height="391" src="http://cnx.org/content/m27277/latest/graphics1.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="505" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="id41562776" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;ROM&lt;/em&gt;&amp;nbsp;(read only memory) contains fundamental instructions that cannot be lost or changed by the user. ROM is non-volatile.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-808682571958" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Arithmetic and Logic Unit (ALU)&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id41283070" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The ALU performs all the arithmetic and logic operations. Ex: addition, subtraction, comparison, etc.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-809051257092" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Central Processing Unit (CPU)&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id36487401" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The unit supervises the overall operation of the computer. The CPU tells the input unit when information should be read into the memory unit, tell the ALU when information from the memory should be used in calculations and tells the output unit when to send information from the memory unit to certain output devices.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-434223450155" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Secondary Storage&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id41489256" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Secondary storage devices are used to be permanent storage area for programs and data.&lt;/div&gt;&lt;div class="para" id="id38838773" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Virtually all secondary storage is now done on magnetic tapes, magnetic disks and CD-ROMs.&lt;/div&gt;&lt;div class="para" id="id41293972" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A magnetic hard disk consists of either a single rigid platter or several platters that spin together on a common spindle. A movable access arm positions the read and write mechanisms over, but not quite touching, the recordable surfaces. Such a configuration is shown in Figure 2.&lt;/div&gt;&lt;div class="figure" id="id41111380" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 2:&amp;nbsp;&lt;/strong&gt;The internal structure of a magnetic hard disk drive&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id15525409"&gt;&lt;img alt="Figure 2 (graphics2.png)" height="283" src="http://cnx.org/content/m27277/latest/graphics2.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="367" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-327370937125" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Computer Software&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id41109162" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;computer program&lt;/em&gt;&amp;nbsp;is a set of instructions used to operate a computer to produce a specific result.&lt;/div&gt;&lt;div class="para" id="id41572144" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Another term for a program or a set of programs is&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;software&lt;/em&gt;, and we use both terms interchangeably throughout the text.&lt;/div&gt;&lt;div class="para" id="id39923000" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Writing computer programs is called&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;computer programming&lt;/em&gt;.&lt;/div&gt;&lt;div class="para" id="id40510617" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The languages used to create computer programs are called&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;programming languages&lt;/em&gt;.&lt;/div&gt;&lt;div class="para" id="id41167230" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;To understand C++ programming, it is helpful to know a little background about how current programming languages evolved.&lt;/div&gt;&lt;div class="section" id="id-578648055732" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Machine and Assembly Languages&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id40596802" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Machine languages&lt;/em&gt;&amp;nbsp;are the lowest level of computer languages. Programs written in machine language consist of entirely of 1s and 0s.&lt;/div&gt;&lt;div class="para" id="id40862214" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Programs in machine language can control directly to the computer’s hardware.&lt;/div&gt;&lt;div class="para" id="id37723018" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;00101010 000000000001 000000000010&lt;/div&gt;&lt;div class="para" id="id41488813" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;10011001 000000000010 000000000011&lt;/div&gt;&lt;div class="para" id="id41295634" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A machine language instruction consists of two parts: an instruction part and an address part.&lt;/div&gt;&lt;div class="para" id="id41126929" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;instruction part&lt;/em&gt;&amp;nbsp;(opcode) is the leftmost group of bits in the instruction and tells the computer the operation to be performed.&lt;/div&gt;&lt;div class="para" id="id41190366" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;address part&lt;/em&gt;&amp;nbsp;specifies the memory address of the data to be used in the instruction.&lt;/div&gt;&lt;div class="para" id="id40950384" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Assembly languages&amp;nbsp;&lt;/em&gt;perform the same tasks as machine languages, but use symbolic names for opcodes and operands instead of 1s and 0s.&lt;/div&gt;&lt;div class="para" id="id41196353" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;LOAD BASEPAY&lt;/div&gt;&lt;div class="para" id="id41623558" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;ADD OVERPAY&lt;/div&gt;&lt;div class="para" id="id41623562" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;STORE GROSSPAY&lt;/div&gt;&lt;div class="para" id="id33786152" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Since computers can only execute machine language programs, an assembly language program must be translated into a machine language program before it can be executed on a computer.&lt;/div&gt;&lt;div class="figure" id="id40860263" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 3:&amp;nbsp;&lt;/strong&gt;Assembly translation&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id16199580"&gt;&lt;img alt="Figure 3 (graphics3.png)" height="107" src="http://cnx.org/content/m27277/latest/graphics3.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="453" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="id41907802" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Machine languages and assembly languages are called low-level languages since they are closest to computer hardware.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-592886343871" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;High-level Programming Languages&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id40996382" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;High-level programming languages create computer programs using instructions that much easier to understand than machine or assembly language instructions.&lt;/div&gt;&lt;div class="para" id="id41446616" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Programs written in a high-level language must be translated into a low level language using a program called a&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;compiler&lt;/em&gt;.&lt;/div&gt;&lt;div class="para" id="id40092399" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A compiler translates programming code into a low-level format.&lt;/div&gt;&lt;div class="para" id="id41050829" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;High-level languages allow programmers to write instructions that look like every English sentences and commonly used mathematical notations.&lt;/div&gt;&lt;div class="para" id="id36937483" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Each line in a high-level language program is called a&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;statement&lt;/em&gt;.&lt;/div&gt;&lt;div class="para" id="id40354761" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Ex: Result = (First + Second)*Third.&lt;/div&gt;&lt;div class="para" id="id41681521" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Once a program is written in a high-level language, it must also be translated into the machine language of the computer on which it will be run. This translation can be accomplished in two ways.&lt;/div&gt;&lt;div class="para" id="id38928468" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When each statement in a high-level source program is translated individually and executed immediately upon translation, the programming language used is called an&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;interpreted language&lt;/em&gt;, and the program doing the translation is called an&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;interpreter&lt;/em&gt;.&lt;/div&gt;&lt;div class="para" id="id41434758" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When all of the statements in a high-level source program are translated as a complete unit before any one statement is executed, the programming language used is called is called a&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;compiled language&lt;/em&gt;. In this case, the program doing the translation is called a&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;compiler&lt;/em&gt;.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-797358448543" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Application and System Software&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id37019648" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Two types of computer programs are: application software and system software.&lt;/div&gt;&lt;div class="para" id="id39871840" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Application software&lt;/em&gt;&amp;nbsp;consists of those programs written to perform particular tasks required by the users.&lt;/div&gt;&lt;div class="para" id="id40770126" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;System software&lt;/em&gt;&amp;nbsp;is the collection of programs that must be available to any computer system for it to operate.&lt;/div&gt;&lt;div class="para" id="id40093682" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The most important system software is the&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;operating system&lt;/em&gt;. Examples of some well-known operating systems include MS-DOS, UNIX, and MS WINDOWS. Many operating systems allow user to run multiple programs. Such operating systems are called&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;multitasking systems&lt;/em&gt;.&lt;/div&gt;&lt;div class="para" id="id40340396" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Beside operating systems, language translators are also system softwares.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-126099151623" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;High-Level Programming Languages&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id35600434" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Because of the difficulty of working with low-level languages, high-level languages were developed to make it easier to write computer programs. High level programming languages create computer programs using instructions that are much easier to understand than machine or assembly language code because you can use words that more clearly describe the task being performed. Examples of high-level languages include FORTRAN, COBOL, BASIC, PASCAL, C, C++ and JAVA.&lt;/div&gt;&lt;div class="para" id="id41572667" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;C and C++ are two separate, but related programming languages. In the 1970s, at Bell Laboratories, Dennis Ritchie and Brian Kernighan designed the C programming language. In 1985, at Bell Laboratories, Bjarne Stroutrup created C++ based on the C language. C++ is an extension of C that adds object-oriented programming capabilities.&lt;/div&gt;&lt;div class="section" id="id-570643059556" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;What is Syntax?&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id41471471" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A programming language’s&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;syntax&lt;/em&gt;&amp;nbsp;is the set of rules for writing grammatically correct language statements. In practice this means a C statement with correct syntax has a proper form specified for the compiler. As such, the compiler accepts the statement and does not generate an error message.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-317561924545" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;The C Programming Language&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id41276517" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;C was used exclusively on UNIX and on mini-computers. During the 1980s, C compilers were written for other platforms, including PCs.&lt;/div&gt;&lt;div class="para" id="id41321262" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;To provide a level of standardization for C language, in 1989, ANSI created a standard version of C that is called ANSI C.&lt;/div&gt;&lt;div class="para" id="id40772485" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;One main benefit of the C language is that it is much closer to assembly language other than other types of high-level programming languages.&lt;/div&gt;&lt;div class="para" id="id40280968" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The programs written in C often run much faster and more efficiently than programs written in other types of high-level programming language.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-30430404388" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;The C++ Programming Language&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id41173322" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;C++ is an extension of C that adds object-oriented programming capabilities. C++ is a popular programming language for writing graphical programs that run on Windows and Macintosh.&lt;/div&gt;&lt;div class="para" id="id36853949" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The standardized version of C++ is commonly referred to as ANSI C++.&lt;/div&gt;&lt;div class="para" id="id41257888" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The ANSI C and ANSI C++ standards define how C/C++ code can be written.&lt;/div&gt;&lt;div class="para" id="id40759965" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The ANSI standards also define&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;run-time libraries&lt;/em&gt;, which contains useful functions, variables, constants, and other programming items that you can add to your programs.&lt;/div&gt;&lt;div class="para" id="id41473235" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The ANSI C++ run-time library is also called the Standard Template Library or Standard C++ Library.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-846014631496" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Structured Programming and Object Oriented Programming&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id39562408" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;During the 1960s, many large software development effects encountered severe difficulties. Software schedules were typically late, costs greatly exceeded budgets and finished products were unreliable. People began to realize that software development was a far more complex activity than they had imagined. Research activity in the 1960s resulted in the evolution of structured programming – a discipline approach to writing programs that are clearer than unstructured programs, easier to test and debug and easier to modify. Chapter 5 discusses the principles of structured programming. Chapters 2 through 6 develop many structured programs.&lt;/div&gt;&lt;div class="para" id="id41311517" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;One of the more tangible results of this research was the development of the Pascal programming language by Niklaus Wirth in 1971. Pascal was designed for teaching structured programming in academic environments and rapidly became the preferred programming languages in most universities.&lt;/div&gt;&lt;div class="para" id="id40948294" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In the 1980s, there is a revolution brewing in the software community:&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;object- oriented programming&lt;/em&gt;. Objects are essentially reusable software components that model items in the real world. Software developers are discovering that using a modular, object-oriented design and implementation approach can make software development groups much more productive than with previous popular programming techniques such as structured programming.&lt;/div&gt;&lt;div class="para" id="id39346422" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Object-oriented programming refers to the creation of reusable software objects that can be easily incorporated into another program. An&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;object&lt;/em&gt;&amp;nbsp;is programming code and data that can be treated as an individual unit or component.&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Data&lt;/em&gt;&amp;nbsp;refers to information contained within variables, constants, or other types of storage structures. The procedures associated with an object are referred as&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;functions&lt;/em&gt;&amp;nbsp;or&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;methods&lt;/em&gt;. Variables that are associated with an object are referred to as&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;properties&lt;/em&gt;&amp;nbsp;or&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;attributes&lt;/em&gt;. Object-oriented programming allows programmers to use programming objects that they have written themselves or that have been written by others.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-371168805625" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Problem Solution and Software Development&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id36841703" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;No matter what field of work you choose, you may have to solve problems. Many of these can be solved quickly and easily. Still others require considerable planning and forethought if the solution is to be appropriate and efficient.&lt;/div&gt;&lt;div class="para" id="id40491712" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Creating a program is no different because a program is a solution developed to solve a particular problem. As such, writing a program is almost the last step in a process of first determining what the problem is and the method that will be used to solve the problem.&lt;/div&gt;&lt;div class="para" id="id40357808" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;One technique used by professional software developers for understanding the problem that is being solved and for creating an effective and appropriate software solution is called the software development procedure. The procedure consists of three overlapping phases&lt;/div&gt;&lt;div class="para" id="id40596945" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;- Development and Design&lt;/div&gt;&lt;div class="para" id="id40974617" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;- Documentation&lt;/div&gt;&lt;div class="para" id="id38119133" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;- Maintenance&lt;/div&gt;&lt;div class="para" id="id40168407" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As a discipline, software engineering is concerned with creating readable, efficient, reliable, and maintainable programs and systems.&lt;/div&gt;&lt;div class="section" id="id-677418201193" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Phase I: Development and Design&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id40348114" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The first phase consists of four steps:&lt;/div&gt;&lt;div class="section" id="id-0935155779432" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;1. Analyze the problem&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id39550000" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This step is required to ensure that the problem is clearly defined and understood. The person doing the analysis has to analyze the problem requirements in order to understand what the program must do, what outputs are required and what inputs are needed. Understanding the problem is very important. Do not start to solve the problem until you have understood clearly the problem.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-341763786807" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;2. Develop a Solution&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id41217223" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Programming is all about solving problems. In this step,&lt;/div&gt;&lt;div class="para" id="id41190358" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;you have to develop an algorithm to solve a given problem.&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Algorithm&lt;/em&gt;&amp;nbsp;is a sequence of steps that describes how the data are to be processed to produce the desired outputs.&lt;/div&gt;&lt;div class="para" id="id41281230" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;An algorithm should be (at least)&lt;/div&gt;&lt;div class="para" id="id41132091" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;–complete (i.e. cover all the parts)&lt;/div&gt;&lt;div class="para" id="id40738655" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;–unambiguous (no doubt about what it does)&lt;/div&gt;&lt;div class="para" id="id35380587" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;–finite (it should finish)&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-705202072994" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;3. Code the solution&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id41418333" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This step consists of translating the algorithm into a computer program using a programming language.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-102666802491" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;4. Test and correct the program&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="id40952070" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This step requires testing of the completed computer program to ensure that it does, in fact, provide a solution to the problem. Any errors that are found during the tests must be corrected.&lt;/div&gt;&lt;div class="para" id="id34714243" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Figure below lists the relative amount of effort that is typically expended on each of these four development and design steps in large commercial programming projects.&lt;/div&gt;&lt;div class="figure" id="id40351769" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 4:&amp;nbsp;&lt;/strong&gt;Four development and design steps in commercial programming projects&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id15101230"&gt;&lt;img alt="Figure 4 (graphics4.png)" height="117" src="http://cnx.org/content/m27277/latest/graphics4.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="489" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-356394259456" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Phase II: Documentation&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id40798550" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Documentation requires collecting critical documents during the analysis, design, coding, and testing.&lt;/div&gt;&lt;div class="para" id="id39448377" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;There are five documents for every program solution:&lt;/div&gt;&lt;div class="list" id="id40357860" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Program description&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Algorithm development and changes&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Well-commented program listing&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Sample test runs&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;User’s manual&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-462432833574" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Phase III: Maintenance&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id40753106" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This phase is concerned with the ongoing correction of problems, revisions to meet changing needs and the addition of new features. Maintenance is often the major effort, and the longest lasting of the three phases. While development may take days or months, maintenance may continue for years or decades.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-701769164664" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Algorithms&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id40410247" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;An algorithm is defined as a step-by-step sequence of instructions that describes how the data are to be processed to produce the desired outputs. In essence, an algorithm answers the question: “What method will you use to solve the problem?”&lt;/div&gt;&lt;div class="para" id="id40713336" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;You can describe an algorithm by using flowchart symbols. By that way, you obtain a flowchart which is an outline of the basic structure or logic of the program.&lt;/div&gt;&lt;div class="section" id="id-750419197486" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Flowchart Symbols&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id40065271" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;To draw flowchart, we employ the symbols shown in the Figure below.&lt;/div&gt;&lt;div class="figure" id="id41214247" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 5:&amp;nbsp;&lt;/strong&gt;Flowchart symbols&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id15050981"&gt;&lt;img alt="Figure 5 (graphics5.png)" height="416" src="http://cnx.org/content/m27277/latest/graphics5.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="347" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="id40523287" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The meaning of each flowchart symbol is given as follows.&lt;/div&gt;&lt;div class="figure" id="id41471208" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 6:&amp;nbsp;&lt;/strong&gt;Description of flowchart symbols&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id16027671"&gt;&lt;img alt="Figure 6 (graphics6.png)" height="226" src="http://cnx.org/content/m27277/latest/graphics6.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="600" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="id38943342" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;To illustrate an algorithm, we consider the simple program that computes the pay of a person. The flowchart for this program is given in the Figure below.&lt;/div&gt;&lt;div class="para" id="id40376650" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Note: Name, Hours and Pay are&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;variables&lt;/em&gt;&amp;nbsp;in the program.&lt;/div&gt;&lt;div class="figure" id="id40489502" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 7:&amp;nbsp;&lt;/strong&gt;A sample flowchart&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id8719669"&gt;&lt;img alt="Figure 7 (graphics7.png)" height="423" src="http://cnx.org/content/m27277/latest/graphics7.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="231" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-339723936142" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Algorithms in pseudo-code&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id41111377" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;You also can use English-like phases to describe an algorithm. In this case, the description is called pseudocode. Pseudocode is an artificial and informal language that helps programmers develop algorithms. Pseudocode has some ways to represent sequence, decision and repetition in algorithms. A carefully prepared pseudocode can be converted easily to a corresponding C++ program.&lt;/div&gt;&lt;div class="para" id="id41609068" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Example: The following set of instructions forms a detailed algorithm in pseudocode for calculating the payment of person.&lt;/div&gt;&lt;div class="para" id="id39562400" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;Input the three values into the variables Name, Hours, Rate.&lt;/code&gt;&lt;/div&gt;&lt;div class="para" id="id41644535" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;Calculate Pay = Hours&amp;nbsp;&lt;/code&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&lt;/code&gt;&amp;nbsp;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;Rate.&lt;/code&gt;&lt;/div&gt;&lt;div class="para" id="id39550534" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;Display Name and Pay.&lt;/code&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-683317673086" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Loops in Algorithms&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id39552104" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Many problems require repetition capability, in which the same calculation or sequence of instructions is repeated, over and over, using different sets of data.&lt;/div&gt;&lt;div class="para" id="id36121173" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Example 1.1. Write a program to do the task: Print a list of the numbers from 4 to 9, next to each number, print the square of the number.&lt;/div&gt;&lt;div class="para" id="id38928744" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The flowchart for the algorithm that solves this problem is given in Figure below. You will see in this figure the flowchart symbol for decision and the flowline that can connect backward to represent a loop.&lt;/div&gt;&lt;div class="figure" id="id41280012" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 8:&amp;nbsp;&lt;/strong&gt;Flowcharts of example 1.1&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id13104676"&gt;&lt;img alt="Figure 8 (graphics8.png)" height="507" src="http://cnx.org/content/m27277/latest/graphics8.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="334" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="id35512912" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Note:&lt;/div&gt;&lt;div class="list" id="id39134337" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ol class="arabic" style="display: block; list-style-image: none; list-style-type: decimal; margin-bottom: 0px; margin-left: 3em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;In the flowchart, the statement&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div class="para" id="id40948330" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;NUM = NUM + 1&lt;/div&gt;&lt;div class="para" id="id41470738" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;means “old value of NUM + 1 becomes new value of NUM ”.&lt;/div&gt;&lt;div class="para" id="id39850477" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The above algorithm can be described in pseudocode as follows:&lt;/div&gt;&lt;div class="para" id="id39850483" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;NUM = 4&lt;/code&gt;&lt;/div&gt;&lt;div class="para" id="id41544190" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;do&lt;/code&gt;&lt;/div&gt;&lt;div class="para" id="id40937682" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;SQNUM = NUM*NUM&lt;/code&gt;&lt;/div&gt;&lt;div class="para" id="id41047873" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;Print NUM, SQNUM&lt;/code&gt;&lt;/div&gt;&lt;div class="para" id="id41288696" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;NUM = NUM + 1&lt;/code&gt;&lt;/div&gt;&lt;div class="para" id="id36276452" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;code class="codeline" style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;while (NUM &amp;lt;= 9)&lt;/code&gt;&lt;/div&gt;&lt;div class="para" id="id41180699" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;You can compare the pseudo-code and the flowchart in Figure above to understand the meaning of the&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;do… while&lt;/em&gt;&amp;nbsp;construct used in the pseudo-code.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id-519319895815" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Flowchart versus pseudocode&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id40352087" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Since flowcharts are inconvenient to revise, they have fallen out of favor by programmers. Nowadays, the use of pseudocode has gained increasing acceptance.&lt;/div&gt;&lt;div class="para" id="id39847965" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Only after an algorithm has been selected and the programmer understands the steps required can the algorithm be written using computer-language statements. The writing of an algorithm using computer-language statements is called&amp;nbsp;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;coding&lt;/em&gt;&amp;nbsp;the algorithm, which is the third step in our program development process.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7191641637792066842-7308310124653149103?l=java-basics.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/7308310124653149103/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://java-basics.blogspot.com/2011/01/computers-and-programming.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/7308310124653149103'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/7308310124653149103'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/2011/01/computers-and-programming.html' title='Computers and Programming'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-3722262585340182708</id><published>2011-01-14T01:39:00.001-08:00</published><updated>2011-01-14T01:39:17.529-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Parallel Programming with MapReduce'/><title type='text'>Parallel Programming with MapReduce</title><content type='html'>&lt;div class="section" id="id9399195" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;MapReduce Overview&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id14020308" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;MapReduce is a framework designed by Google&amp;nbsp;&lt;a class="link" href="http://www.ece.rutgers.edu/~parashar/Classes/08-09/ece572/readings/mapreduce-osdi-04.pdf" style="color: #336699;"&gt;[1]&lt;/a&gt;. It is loosely based on the Map and Reduce programming constructs of functional languages like Lisp&amp;nbsp;&lt;a class="link" href="http://www-formal.stanford.edu/jmc/recursive.pdf" style="color: #336699;"&gt;[2]&lt;/a&gt;. Google’s MapReduce is used in a distributed computing, scalable platform. It was designed for data-intensive applications which need to process huge amounts of data.&lt;/div&gt;&lt;div class="para" id="id14297436" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Various open source implementations exist. The most popular one is Apache’s Hadoop&amp;nbsp;&lt;a class="link" href="http://hadoop.apache.org/" style="color: #336699;"&gt;[3]&lt;/a&gt;. Hadoop is a scalable distributed computing platform that includes a file system (HDFS) to store massive data, and a Java MapReduce implementation to process that data.&lt;/div&gt;&lt;div class="para" id="id14736551" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Other MapReduce implementations exist. QT Concurrent has a MapReduce implementation for multi-core processors.&lt;/div&gt;&lt;div class="para" id="eip-683" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This module provides an introduction to parallel programming with MapReduce, using QT Concurrent.&lt;/div&gt;&lt;div class="section" id="id13901292" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Programming with MapReduce&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="id13552627" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When we decide to solve a programming problem using MapReduce, we provide an implementation for a mapper and for a reducer.&amp;nbsp;&lt;i class="emphasis"&gt;N&lt;/i&gt;&amp;nbsp;mappers are executed simultaneously, executing the same task for different input data. One or more reducers receive the output generated by the mappers, and apply a reducing phase yielding a final result.&lt;/div&gt;&lt;div class="para" id="id9400179" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A simple program to count word occurrences in a text corpus is described in&amp;nbsp;&lt;a class="link" href="http://code.google.com/edu/submissions/mapreduce-minilecture/lec2-mapred.ppt" style="color: #336699;"&gt;[4]&lt;/a&gt;:&lt;/div&gt;&lt;div class="code" id="id5880442" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&lt;span class="preformat" id="id58804423" style="font-family: courier, 'courier new', monospace; font-size: 1.18em;"&gt;&lt;br /&gt;   map(String input_key, String input_value):&lt;br /&gt;       // input_key: document name &lt;br /&gt;       // input_value: document contents &lt;br /&gt;       for each word w in input_value: &lt;br /&gt;           EmitIntermediate(w, "1"); &lt;br /&gt;&lt;br /&gt;    reduce(String output_key, Iterator intermediate_values): &lt;br /&gt;       // output_key: a word &lt;br /&gt;       // output_values: a list of counts &lt;br /&gt;       int result = 0; &lt;br /&gt;    &lt;br /&gt;       for each v in intermediate_values: &lt;br /&gt;          result += ParseInt(v);&lt;br /&gt;       Emit(AsString(result));&lt;br /&gt;&lt;/span&gt; &lt;/code&gt;&lt;/pre&gt;&lt;div class="code-caption" style="border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; font-size: 0.9em; line-height: normal; margin-bottom: 0px; margin-left: auto; margin-right: auto; margin-top: 0.75em; padding-top: 0.5em; text-align: left;"&gt;MapReduce pseudocode that counts word occurrences in a text corpus.&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="id11819838" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As shown in the code above, a map function receives an input key and an input value (&amp;lt;key, value&amp;gt;), and generates one or more intermediate output &amp;lt;key,value(s)&amp;gt; pairs. A reduce function receives intermediate keys and values that were the ouput by the mappers, processes them in some way, and generates one or more final key-value(s) pairs (&amp;lt;key,value(s)).&lt;/div&gt;&lt;div class="para" id="id9686090" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;You can find a Hadoop implementation of the word count problem at&amp;nbsp;&lt;a class="link" href="http://wiki.apache.org/hadoop/WordCount" style="color: #336699;"&gt;[5]&lt;/a&gt;, and a QT concurrent implementation in the&amp;nbsp;&lt;a class="link" href="http://labs.trolltech.com/images/5/57/Qtconcurrent-0.1.2.zip" style="color: #336699;"&gt;QT Concurrent package&lt;/a&gt;&amp;nbsp;(path: qtconcurrent/examples/wordcount) which can be checked out with&amp;nbsp;&lt;a class="link" href="svn://labs.trolltech.com/svn/threads/qtconcurrent" style="color: #336699;"&gt;subversion&lt;/a&gt;.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id13484197" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;MapReduce in QT Concurrent&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id13656523" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;QT Concurrent&amp;nbsp;&lt;a class="link" href="http://labs.trolltech.com/page/Projects/Threads/QtConcurrent" style="color: #336699;"&gt;[6]&lt;/a&gt;&amp;nbsp;is a C++ library for multi-threaded applications. Among other things, it provides a MapReduce implementation for multi-core computers. The map function is called in parallel by multiple threads. The number of threads used in a program depends on the number of processor cores available.&lt;/div&gt;&lt;div class="para" id="id14555118" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Google’s original MapReduce runs in computer clusters. The data it processes is stored in a distributed file system called GFS (Google File System). To minimize I/O bottlenecks, mappers are usually executed in the same node where the data resides. Parallelism comes from multiple computers executing mappers (or reducers) at the same time.&lt;/div&gt;&lt;div class="para" id="id9515720" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;On the other hand, QT Concurrent’s MapReduce implementation works on shared-memory systems. Parallelism comes from multiple threads executing mappers at the same time, on multiple processor cores.&lt;/div&gt;&lt;div class="para" id="id7172370" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;To work with QT Concurrent’s MapReduce, you write a map function and a reduce function. You must also indicate the list of values (e.g., names of files, words, numbers, etc.) that you want to feed your mappers. To do this, use the following API:&lt;/div&gt;&lt;div class="code" id="id13912003" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&lt;span class="preformat" id="id139120033" style="font-family: courier, 'courier new', monospace; font-size: 1.18em;"&gt;&lt;br /&gt;QFuture&amp;lt;T&amp;gt; QtConcurrent::mappedReduced ( &lt;br /&gt;    const Sequence &amp;amp; sequence, &lt;br /&gt;    MapFunction mapFunction, &lt;br /&gt;    ReduceFunction reduceFunction, &lt;br /&gt;    QtConcurrent::ReduceOptions reduceOptions = UnorderedReduce | SequentialReduce )&lt;br /&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;div class="code-caption" style="border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; font-size: 0.9em; line-height: normal; margin-bottom: 0px; margin-left: auto; margin-right: auto; margin-top: 0.75em; padding-top: 0.5em; text-align: left;"&gt;Structure QTConcurrent::mappedReduced function&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="id9392045" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;For example:&lt;/div&gt;&lt;div class="code" id="id11525408" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&lt;span class="preformat" id="id115254083" style="font-family: courier, 'courier new', monospace; font-size: 1.18em;"&gt;&lt;br /&gt;QFuture&amp;lt;T&amp;gt; mappedReduced(theList, mapFunction, reduceFunction);&lt;br /&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;div class="code-caption" style="border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; font-size: 0.9em; line-height: normal; margin-bottom: 0px; margin-left: auto; margin-right: auto; margin-top: 0.75em; padding-top: 0.5em; text-align: left;"&gt;QFuture::mappedReduced function&lt;/div&gt;&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id12782034" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;Example: Determining if a (Big) Integer is a Probable Prime&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id14055529" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;An algorithm for finding a probable prime can be defined using the&amp;nbsp;&lt;a class="link" href="http://en.wikipedia.org/wiki/Miller-Rabin_primality_test" style="color: #336699;"&gt;Miller-Rabin primality test&lt;/a&gt;, as follows:&lt;/div&gt;&lt;div class="code" id="id13941441" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&lt;span class="preformat" id="id139414413" style="font-family: courier, 'courier new', monospace; font-size: 1.18em;"&gt;    &lt;br /&gt;    let n be a very big odd number&lt;br /&gt;    check n for divisibility for all primes &amp;lt; 2000&lt;br /&gt;    choose m positive integers less than n&lt;br /&gt;    for each of these bases apply the Miller-Rabin test&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;    &lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class="para" id="id9391501" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The algorithm described above can be easily parallelized using MapReduce as follows:&lt;/div&gt;&lt;div class="list" id="id14649151" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ol class="other" style="display: block; list-style-image: none; list-style-type: none; margin-bottom: 0px; margin-left: 1.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="item-decoration" style="margin-right: 0.5em;"&gt;Step 1.&lt;/span&gt;&amp;nbsp;Randomly generate an odd (big) integer&amp;nbsp;&lt;i class="emphasis"&gt;n&lt;/i&gt;&amp;nbsp;greater than 2.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="item-decoration" style="margin-right: 0.5em;"&gt;Step 2.&lt;/span&gt;&amp;nbsp;Generate (or read a list of) all primes less than 2000.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="item-decoration" style="margin-right: 0.5em;"&gt;Step 3.&lt;/span&gt;&amp;nbsp;MapReduce-Part1:&lt;div class="list" id="id9436928" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="other" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: none; margin-bottom: 0px; margin-left: 1.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Map function:&lt;/em&gt;&amp;nbsp;Each mapper receives a distinct prime number&amp;nbsp;&lt;i class="emphasis"&gt;p&lt;sub class="sub"&gt;i&lt;/sub&gt;&lt;/i&gt;, and checks if&amp;nbsp;&lt;i class="emphasis"&gt;n&lt;/i&gt;&amp;nbsp;is divisible by this number. A mapper emits (outputs) a 1 if&amp;nbsp;&lt;i class="emphasis"&gt;n&lt;/i&gt;&amp;nbsp;is divisible by&amp;nbsp;&lt;i class="emphasis"&gt;p&lt;sub class="sub"&gt;i&lt;/sub&gt;&lt;/i&gt;&amp;nbsp;or 0 otherwise.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Reduce function:&amp;nbsp;&lt;/em&gt;Counts the number of divisors. If the number of divisors is greater than zero, it is not a prime number, so the test is terminated.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="item-decoration" style="margin-right: 0.5em;"&gt;Step 4.&lt;/span&gt;&amp;nbsp;Generate 100 random positive integers less than&amp;nbsp;&lt;i class="emphasis"&gt;n&lt;/i&gt;.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="item-decoration" style="margin-right: 0.5em;"&gt;Step 5.&lt;/span&gt;&amp;nbsp;MapReduce-Part2:&lt;div class="list" id="id9522822" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="other" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: none; margin-bottom: 0px; margin-left: 1.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Map function:&amp;nbsp;&lt;/em&gt;Each mapper receives a different random number&amp;nbsp;&lt;i class="emphasis"&gt;r&lt;sub class="sub"&gt;i&lt;/sub&gt;&lt;/i&gt;&amp;nbsp;and applies the Miller-Rabin primality test. A mapper emits (outputs) a 1 if&amp;nbsp;&lt;i class="emphasis"&gt;n&lt;/i&gt;&amp;nbsp;does not pass the test, or a 0 if it passes the test.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;em class="emphasis" style="font-style: normal; font-weight: bold;"&gt;Reduce function:&amp;nbsp;&lt;/em&gt;Counts the number of 1s emitted by the mappers. If the number of divisors is zero,&amp;nbsp;&lt;i class="emphasis"&gt;n&lt;/i&gt;&amp;nbsp;is a probable prime.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div class="para" id="id14037761" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The next section shows a MapReduce implementation of the algorithm described above, using QT Concurrent. You can find a Hadoop implementation&amp;nbsp;&lt;a class="link" href="http://cnx.org/content/m20644/latest/QTPrimeValidator.zip" style="color: #336699;"&gt;here&lt;/a&gt;.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id7548638" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;A MapReduce Implementation Using QT Concurrent&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id14062336" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The main program needs to call the&amp;nbsp;&lt;span class="foreign" style="font-style: italic;"&gt;mappedReduced&lt;/span&gt;&amp;nbsp;function twice (steps 3 and 5 in the algorithm described earlier):&lt;/div&gt;&lt;div class="code" id="id13975034" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&lt;span class="preformat" id="id139750343" style="font-family: courier, 'courier new', monospace; font-size: 1.18em;"&gt;&lt;br /&gt;    qDebug() &amp;lt;&amp;lt; "\nJob: Divisibility for primes less than 2000";&lt;br /&gt;    qDebug() &amp;lt;&amp;lt; "Starting Job";&lt;br /&gt;    &lt;br /&gt;    time.start();&lt;br /&gt;    Counting final = mappedReduced(primes,mapperLess2000,reducerLess2000);&lt;br /&gt;    mapReduce2000Time = time.elapsed();&lt;br /&gt;    qDebug() &amp;lt;&amp;lt; "End Job";&lt;br /&gt;    qDebug() &amp;lt;&amp;lt; "MapReduce elapsed time: " &amp;lt;&amp;lt; (mapReduce2000Time) &amp;lt;&amp;lt; "msegs\n";&lt;br /&gt;    &lt;br /&gt;    //Counter of exacts divisors equals to zero&lt;br /&gt;    if(final[exactDiv] == 0) {&lt;br /&gt;&lt;br /&gt;       de = Decomposition&amp;lt;2048&amp;gt;(number - 1);&lt;br /&gt;&lt;br /&gt;       qDebug() &amp;lt;&amp;lt; "Job: Divisibility for random numbers less than number to evaluate";&lt;br /&gt;       qDebug() &amp;lt;&amp;lt; "Starting Job";&lt;br /&gt;       time.start();&lt;br /&gt;       Counting finalRand = mappedReduced(randomPrimes,mapperRandom,reducerRandom);&lt;br /&gt;       mapReduceRandomTime = time.elapsed();&lt;br /&gt;       qDebug() &amp;lt;&amp;lt; "End Job";&lt;br /&gt;       qDebug() &amp;lt;&amp;lt; "MapReduce elapsed time: " &amp;lt;&amp;lt; (mapReduceRandomTime) &amp;lt;&amp;lt; "msegs\n";&lt;br /&gt;    &lt;br /&gt;       //Counter of random numbers&lt;br /&gt;       if(finalRand[falseMiller] &amp;gt; 0) {&lt;br /&gt;          qDebug() &amp;lt;&amp;lt; "Result: Non-prime";&lt;br /&gt;       } else&lt;br /&gt;          qDebug() &amp;lt;&amp;lt; "Result: Probably prime";&lt;br /&gt;    } else qDebug() &amp;lt;&amp;lt; "Result: Non-prime";&lt;br /&gt;&lt;/span&gt;    &lt;/code&gt;&lt;/pre&gt;&lt;div class="code-caption" style="border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; font-size: 0.9em; line-height: normal; margin-bottom: 0px; margin-left: auto; margin-right: auto; margin-top: 0.75em; padding-top: 0.5em; text-align: left;"&gt;Main program&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="id9108955" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;span class="foreign" style="font-style: italic;"&gt;Decomposition&lt;/span&gt;&amp;nbsp;function used in the main program because number decomposition is needed before the Miller-Rabin test is performed. This means that the number minus one is represented as product of 2&lt;sup class="sup"&gt;k&lt;/sup&gt;&amp;nbsp;and m, where m is odd.&lt;/div&gt;&lt;div class="para" id="id13574076" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Two MapReduce processes are implemented. The first MapReduce process, evaluates divisibility for all primes less than 2000. Each map function receives a prime as argument and the reduce function counts the number of divisors, as shown below:&lt;/div&gt;&lt;div class="code" id="id13141674" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&lt;span class="preformat" id="id131416743" style="font-family: courier, 'courier new', monospace; font-size: 1.18em;"&gt;&lt;br /&gt;    Counting mapperLess2000(const unsigned long &amp;amp;prime) {&lt;br /&gt;       Counting rMap; &lt;br /&gt;       BigInt2048 myPrime(prime);&lt;br /&gt;    &lt;br /&gt;       if( number % myPrime == 0 )&lt;br /&gt;          divisors &amp;lt;&amp;lt; prime; &lt;br /&gt;    &lt;br /&gt;       rMap[( number % myPrime == 0 )?exactDiv:inexactDiv];&lt;br /&gt;       return rMap;&lt;br /&gt;    }&lt;br /&gt;    &lt;br /&gt;    void reducerLess2000(Counting &amp;amp;result, const Counting &amp;amp;w) {&lt;br /&gt;        QMapIterator&amp;lt;QString, int&amp;gt; i(w); &lt;br /&gt;    &lt;br /&gt;        while(i.hasNext()) {&lt;br /&gt;           i.next();&lt;br /&gt;           result[i.key()]++;&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;div class="code-caption" style="border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; font-size: 0.9em; line-height: normal; margin-bottom: 0px; margin-left: auto; margin-right: auto; margin-top: 0.75em; padding-top: 0.5em; text-align: left;"&gt;MapReduce code to test for primality&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="id11819899" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The second MapReduce process is executed only if the random number was not divisible by any of the prime numbers less than 2000:&lt;/div&gt;&lt;div class="code" id="id13970160" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&lt;span class="preformat" id="id139701603" style="font-family: courier, 'courier new', monospace; font-size: 1.18em;"&gt;&lt;br /&gt;    Counting mapperRandom(const BigInt2048 &amp;amp;prime) {&lt;br /&gt;        &lt;br /&gt;        Counting rMap;&lt;br /&gt;        BigInt2048 z( getZ(prime,de.getM()).bits );&lt;br /&gt;    &lt;br /&gt;        // This is the easy case; the first term in the sequence&lt;br /&gt;        // is correct, so we pass the test.&lt;br /&gt;    &lt;br /&gt;        if(z == 1) {&lt;br /&gt;&lt;br /&gt;           rMap[trueMiller];&lt;br /&gt;           divisors &amp;lt;&amp;lt; z;&lt;br /&gt;           return rMap;&lt;br /&gt;&lt;br /&gt;        } else {&lt;br /&gt;    &lt;br /&gt;           for (int j = 0; j &amp;lt; de.getK(); j++) {&lt;br /&gt;               BigInt2048 zSquared = BigInt2048(newZ(z).bits);&lt;br /&gt;           &lt;br /&gt;               if (zSquared == 1 &amp;amp;&amp;amp; z == (number - 1) ) {&lt;br /&gt;    &lt;br /&gt;                  // We've passed the hard version of the Rabin Miller test.&lt;br /&gt;                  rMap[trueMiller];&lt;br /&gt;                  divisors &amp;lt;&amp;lt; z;&lt;br /&gt;                  return rMap;&lt;br /&gt;&lt;br /&gt;               }&lt;br /&gt;           &lt;br /&gt;               z = zSquared;&lt;br /&gt;           }&lt;br /&gt;        &lt;br /&gt;           rMap[falseMiller];&lt;br /&gt;           return rMap;&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;    &lt;br /&gt;    &lt;br /&gt;    void reducerRandom(Counting &amp;amp;result, const Counting &amp;amp;w) {&lt;br /&gt;&lt;br /&gt;        QMapIterator&amp;lt;QString, int&amp;gt; i(w);&lt;br /&gt;        while(i.hasNext()) {&lt;br /&gt;            i.next();&lt;br /&gt;            result[i.key()]++;&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;&lt;/span&gt;    &lt;/code&gt;&lt;/pre&gt;&lt;div class="code-caption" style="border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; font-size: 0.9em; line-height: normal; margin-bottom: 0px; margin-left: auto; margin-right: auto; margin-top: 0.75em; padding-top: 0.5em; text-align: left;"&gt;MapReduce code that applies the Miller-Rabin test&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="id12904586" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;a class="link" href="http://cnx.org/content/m20644/latest/#id14518840" style="color: #336699;"&gt;Figure 1&lt;/a&gt;&amp;nbsp;shows the results of one run of the program.&lt;/div&gt;&lt;div class="para" id="id14655678" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;/div&gt;&lt;div class="figure" id="id14518840" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 1:&amp;nbsp;&lt;/strong&gt;Prime Validator program&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="id14518840_media"&gt;&lt;img alt="Figure 1 (graphics1.png)" height="301" id="id14518840__onlineimage" src="http://cnx.org/content/m20644/latest/graphics1.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="599" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;/div&gt;&lt;div class="para" id="eip-345" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;You can download the complete source of this example&amp;nbsp;&lt;a class="link" href="http://cnx.org/content/m20644/latest/QTPrimeValidator.zip" style="color: #336699;"&gt;here&lt;/a&gt;.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="id93991953" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;References&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="id10211464" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;/div&gt;&lt;div class="list" id="references" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="other" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: none; margin-bottom: 0px; margin-left: 1.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="link" href="http://www.ece.rutgers.edu/~parashar/Classes/08-09/ece572/readings/mapreduce-osdi-04.pdf" style="color: #336699;"&gt;[1]&amp;nbsp;&lt;/a&gt;Jeffrey Dean, Sanjay Ghemawat. “MapReduce: Simplified Data Processing on Large Clusters.” In Communications of the ACM, vol. 51, no. 1 (2008). pp. 107-113.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="link" href="http://www-formal.stanford.edu/jmc/recursive.pdf" style="color: #336699;"&gt;[2]&amp;nbsp;&lt;/a&gt;McCarthy, J. "Recursive functions of symbolic expressions and their computation by machine, Part I". In Communications of the ACM. Vol 3 (4), pp. 184-195. Apr. 1960.&amp;nbsp;&lt;a class="link" href="http://www-formal.stanford.edu/jmc/recursive.pdf" style="color: #336699;"&gt;http://www-formal.stanford.edu/jmc/recursive.pdf&lt;/a&gt;&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="link" href="http://hadoop.apache.org/" style="color: #336699;"&gt;[3]&amp;nbsp;&lt;/a&gt;Apache Hadoop,&amp;nbsp;&lt;a class="link" href="http://hadoop.apache.org/" style="color: #336699;"&gt;http://hadoop.apache.org/&lt;/a&gt;, 03/17/2009&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="link" href="http://code.google.com/edu/submissions/mapreduce-minilecture/lec2-mapred.ppt" style="color: #336699;"&gt;[4]&amp;nbsp;&lt;/a&gt;Aaron Kimball, Sierra Michels-Slettvet, Christophe Bisciglia, et al. , “Lecture 2 - MapReduce: Theory and Implementation”. Introduction to Problem Solving on Large Scale Clusters. Spring 2007. Available for download at:&amp;nbsp;&lt;a class="link" href="http://code.google.com/edu/submissions/uwspr2007_clustercourse/listing.html" style="color: #336699;"&gt;http://code.google.com/edu/submissions/uwspr2007_clustercourse/listing.html&lt;/a&gt;&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="link" href="http://wiki.apache.org/hadoop/WordCount" style="color: #336699;"&gt;[5]&amp;nbsp;&lt;/a&gt;Hadoop Wiki WordCount,&amp;nbsp;&lt;a class="link" href="http://wiki.apache.org/hadoop/WordCount" style="color: #336699;"&gt;http://wiki.apache.org/hadoop/WordCount&lt;/a&gt;, 24/09/2008&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="link" href="http://labs.trolltech.com/page/Projects/Threads/QtConcurrent" style="color: #336699;"&gt;[6]&amp;nbsp;&lt;/a&gt;Qt Concurrent,&amp;nbsp;&lt;a class="link" href="http://labs.trolltech.com/page/Projects/Threads/QtConcurrent" style="color: #336699;"&gt;http://labs.trolltech.com/page/Projects/Threads/QtConcurrent&amp;nbsp;&lt;/a&gt;, 12/02/2008&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7191641637792066842-3722262585340182708?l=java-basics.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/3722262585340182708/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://java-basics.blogspot.com/2011/01/parallel-programming-with-mapreduce.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/3722262585340182708'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/3722262585340182708'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/2011/01/parallel-programming-with-mapreduce.html' title='Parallel Programming with MapReduce'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-888637046049106718</id><published>2011-01-14T01:30:00.001-08:00</published><updated>2011-01-14T01:30:04.367-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Decorator Design Pattern'/><title type='text'>Decorator Design Pattern</title><content type='html'>&lt;div class="para" id="delete_me" style="display: block; font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The Decorator Pattern is used for adding additional functionality to a particular object as opposed to a class of objects. It is easy to add functionality to an entire class of objects by subclassing an object, but it is impossible to extend a single object this way. With the Decorator Pattern, you can add functionality to a single object and leave others like it unmodified.&lt;/div&gt;&lt;div class="para" id="eip-205" style="display: block; font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A Decorator, also known as a Wrapper, is an object that has an interface identical to an object that it contains. Any calls that the decorator gets, it relays to the object that it contains, and adds its own functionality along the way, either before or after the call. This gives you a lot of flexibility, since you can change what the decorator does at runtime, as opposed to having the change be static and determined at compile time by subclassing. Since a Decorator complies with the interface that the object that it contains, the Decorator is indistinguishable from the object that it contains. That is, a Decorator is a concrete instance of the abstract class, and thus is indistinguishable from any other concrete instance, including other decorators. This can be used to great advantage, as you can recursively nest decorators without any other objects being able to tell the difference, allowing a near infinite amount of customization.&lt;/div&gt;&lt;div class="figure" id="decorator" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 1:&amp;nbsp;&lt;/strong&gt;Decorator example showing two concrete decorators that add additional state and behavior respectively.&lt;/caption&gt;&lt;thead&gt;&lt;tr&gt;&lt;th class="figure-name" style="border-collapse: collapse; padding-bottom: 0.3em; padding-left: 0.3em; padding-right: 0.3em; padding-top: 0.3em; text-align: center;"&gt;&lt;strong class="title"&gt;UML diagram of a decorator design pattern example&lt;/strong&gt;&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="dogpic"&gt;&lt;img alt="UML diagram of decorator example" src="http://cnx.org/content/m26102/latest/decorator.jpg" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;/div&gt;&lt;div class="para" id="eip-398" style="display: block; font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Decorators add the ability to dynamically alter the behavior of an object because a decorator can be added or removed from an object without the client realizing that anything changed. It is a good idea to use a Decorator in a situation where you want to change the behaviour of an object repeatedly (by adding and subtracting functionality) during runtime. The dynamic behavior modification capability also means that decorators are useful for adapting objects to new situations without re-writing the original object's code. The code for a decorator would something like this:&lt;/div&gt;&lt;div class="code" id="eip-601" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;void doStuff() {&lt;br /&gt;   // any pre-processing code goes here.&lt;br /&gt;   aComponent.doStuff();  // delegate to the decoree &lt;br /&gt;   // any post-processing code goes here&lt;br /&gt;}&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;div class="code-caption" style="border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; font-size: 0.9em; line-height: normal; margin-bottom: 0px; margin-left: auto; margin-right: auto; margin-top: 0.75em; padding-top: 0.5em; text-align: left;"&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="eip-824" style="display: block; font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Note that the decorator can opt to not delegate to the decoree, if, for instance, some condition was not met. A very nice example of decorators is Java's I/O stream implementation.&lt;/div&gt;&lt;div class="para" id="eip-967" style="display: block; font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This module is based on work originally written by Antonio Garcia&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7191641637792066842-888637046049106718?l=java-basics.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/888637046049106718/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://java-basics.blogspot.com/2011/01/decorator-design-pattern.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/888637046049106718'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/888637046049106718'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/2011/01/decorator-design-pattern.html' title='Decorator Design Pattern'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-7953131884200893817</id><published>2011-01-14T01:27:00.003-08:00</published><updated>2011-01-14T01:27:59.628-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Data with phonetic characters using Easy IPA'/><title type='text'>Data with phonetic characters using Easy IPA</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px;"&gt;&lt;span class="cnx_before" style="font-weight: bold;"&gt;Summary:&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px;"&gt;&lt;span class="span"&gt;The whole IPA alphabet, including diacritics and modifiers, is available to you through Easy IPA. If you touch type, you'll find yourself touch typing the IPA characters you use frequently in your collection.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px;"&gt;&lt;span class="span"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px;"&gt;&lt;span class="span"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px;"&gt;&lt;span class="span"&gt;&lt;span class="Apple-style-span" style="line-height: 18px;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;div class="para" id="delete_me" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;You can type anything the International Phonetic Alphabet offers without having to lift your hands from the keyboard. Here's how Easy IPA works:&lt;/div&gt;&lt;div class="list" id="element-790" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ol class="bullet" style="display: block; list-style-image: none; margin-bottom: 0px; margin-left: 3em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Type the character from a to z that looks most like the character you want.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Type Control-space by putting your little finger on the Control key, and while holding it down, tap the space bar once with your index finger.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Look at the popup box that contains all the IPA characters that are kind of like the one you typed in Step 1.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Choose the IPA character you want.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Type the number or letter associated with it.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;The IPA character replaces the a to z character you typed.&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div class="para" id="element-3" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;That's Easy IPA in a nutshell. Say you type an "a" to get an a-like vowel symbol such as ash (also called digraph). Then you type Control-space. Up come all the a-like characters:&lt;/div&gt;&lt;div class="figure" id="element-787" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 1:&amp;nbsp;&lt;/strong&gt;Characters kind of like&amp;nbsp;&lt;span class="foreign" style="font-style: italic;"&gt;a&lt;/span&gt;&amp;nbsp;in Wordcorr's Easy IPA table.&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media"&gt;&lt;img alt="Figure 1 (01003TableFor a Ctrl-space.jpg)" src="http://cnx.org/content/m13708/latest/01003TableFor%20a%20Ctrl-space.jpg" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="element-331" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Ash is indexed as "2", so you type 2. It replaces the "a" you typed before the Control-space. If you wanted "a-breve" (not an IPA symbol, but comparative linguists use it anyway so we stuck it in the table) you'd type "c" to select it.&lt;/div&gt;&lt;div class="para" id="element-684" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;For IPA modifiers and some other characters, you type certain characters outside the a-z range before you type Control-space:&lt;/div&gt;&lt;div class="list" id="element-570" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Glottal stop and similar characters: type&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;"?"&lt;/dfn&gt;&amp;nbsp;and Control-space.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Symbols for clicks: type&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;"!"&lt;/dfn&gt;&amp;nbsp;and Control-space.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Modifier characters: type&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;"^"&lt;/dfn&gt;&amp;nbsp;(Shift-6) and Control-space for some,&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;":"&lt;/dfn&gt;&amp;nbsp;(colon) and Control-space for others.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Prosodic modifier characters: type&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;":"&lt;/dfn&gt;&amp;nbsp;(colon) and Control-space.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="element-784" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;For IPA diacritics that go under, above or through the base character proper:&lt;/div&gt;&lt;div class="list" id="element-883" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Diacritics that mainly go under the base character, type&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;","&lt;/dfn&gt;&amp;nbsp;(comma) and Control-space.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Diacritics that go above the base character, type&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;"~"&lt;/dfn&gt;&amp;nbsp;(tilde) and Control-space.&lt;/li&gt;&lt;li class="item" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Diacritics that mainly go through the base character, type&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;"-"&lt;/dfn&gt;&amp;nbsp;(tilde) and Control-space.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="element-12" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Or, on a single line:&amp;nbsp;&lt;dfn class="term" style="color: #336699; display: inline; font-style: normal; font-weight: bold;"&gt;Ctrl-Sp after ? glottal; ! click; ^ : modifier; , ~ - diacritic&lt;/dfn&gt;&lt;/div&gt;&lt;div class="figure" id="element-307" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 2:&amp;nbsp;&lt;/strong&gt;IPA transcriptions from the Wordcorr Data panel. Diacritical marks are not well aligned here, but they are elsewhere.&lt;/caption&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media"&gt;&lt;img alt="Figure 2 (Data-IPA.jpg)" src="http://cnx.org/content/m13708/latest/Data-IPA.jpg" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="note" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 0.75em; margin-left: 3em; margin-right: 3em; margin-top: 0.5em; padding-bottom: 0.75em; padding-left: 0.75em; padding-right: 0.75em; padding-top: 0.75em;"&gt;&lt;h2 class="note-header" style="display: inline; font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;HINT:&amp;nbsp;&lt;/span&gt;&lt;/h2&gt;When you're typing in data, you don't use all the characters in the International Phonetic Alphabet. For the ones you use a lot, your brain quickly learns the motor sequence (like "a" Control-space "2" for ash). If you touch type, you'll soon find yourself touch typing the part of IPA you use without a blink. You don't even have to take your hands off the keyboard to look for a mouse or a reference card.&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/col10339/latest/" style="color: #336699; font-weight: bold;"&gt;Install&lt;/a&gt;&amp;nbsp;Wordcorr and give it a try.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7191641637792066842-7953131884200893817?l=java-basics.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/7953131884200893817/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://java-basics.blogspot.com/2011/01/data-with-phonetic-characters-using.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/7953131884200893817'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/7953131884200893817'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/2011/01/data-with-phonetic-characters-using.html' title='Data with phonetic characters using Easy IPA'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-3136053789626923714</id><published>2011-01-14T01:27:00.001-08:00</published><updated>2011-01-14T01:27:02.648-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Drag and Drop Basics'/><title type='text'>Drag and Drop Basics</title><content type='html'>&lt;div class="section" id="h11001" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;div class="section" id="h21001" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;div class="para" id="p1008" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I recommend that you open another copy of this document in a separate browser window and use the following links to easily find and view the figures and listings while you are reading about them.&lt;/div&gt;&lt;div class="section" id="h31000" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Figures"&gt;Figures&lt;/b&gt;&lt;/strong&gt;&lt;/h4&gt;&lt;div class="list" id="ul1004" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1015" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Figure_1" id="a1017" style="color: #336699; font-weight: bold;"&gt;Figure 1&amp;nbsp;&lt;/a&gt;. Program output at startup.&lt;/li&gt;&lt;li class="item" id="li1016" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Figure_2" id="a1018" style="color: #336699; font-weight: bold;"&gt;Figure 2&amp;nbsp;&lt;/a&gt;. Program file structure.&lt;/li&gt;&lt;li class="item" id="li1017" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Figure_3" id="a1019" style="color: #336699; font-weight: bold;"&gt;Figure 3&amp;nbsp;&lt;/a&gt;. Program output after dragging the images.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h31001" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listings"&gt;Listings&lt;/b&gt;&lt;/strong&gt;&lt;/h4&gt;&lt;div class="list" id="ul1005" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1018" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_1" id="a1020" style="color: #336699; font-weight: bold;"&gt;Listing 1&amp;nbsp;&lt;/a&gt;. The MXML file for DragAndDrop01.&lt;/li&gt;&lt;li class="item" id="li1019" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_2" id="a1021" style="color: #336699; font-weight: bold;"&gt;Listing 2&amp;nbsp;&lt;/a&gt;. Beginning of the Driver class for DragAndDrop01.&lt;/li&gt;&lt;li class="item" id="li1020" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_3" id="a1022" style="color: #336699; font-weight: bold;"&gt;Listing 3&amp;nbsp;&lt;/a&gt;. Beginning of the constructor for the Driver class.&lt;/li&gt;&lt;li class="item" id="li1021" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_4" id="a1023" style="color: #336699; font-weight: bold;"&gt;Listing 4&amp;nbsp;&lt;/a&gt;. Prepare the three images.&lt;/li&gt;&lt;li class="item" id="li1022" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_5" id="a1024" style="color: #336699; font-weight: bold;"&gt;Listing 5&amp;nbsp;&lt;/a&gt;. Register a creationComplete event handler.&lt;/li&gt;&lt;li class="item" id="li1023" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_6" id="a1025" style="color: #336699; font-weight: bold;"&gt;Listing 6&amp;nbsp;&lt;/a&gt;. Beginning of the creationComplete event handler.&lt;/li&gt;&lt;li class="item" id="li1024" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_7" id="a1026" style="color: #336699; font-weight: bold;"&gt;Listing 7&amp;nbsp;&lt;/a&gt;. Register a mouseDown event handler on each Image object.&lt;/li&gt;&lt;li class="item" id="li1025" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_8" id="a1027" style="color: #336699; font-weight: bold;"&gt;Listing 8&amp;nbsp;&lt;/a&gt;. Register dragDrop and dragEnter event handlers on the Canvas object.&lt;/li&gt;&lt;li class="item" id="li1026" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_9" id="a1028" style="color: #336699; font-weight: bold;"&gt;Listing 9&amp;nbsp;&lt;/a&gt;. Beginning of the mouseDown event handler.&lt;/li&gt;&lt;li class="item" id="li1027" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_10" id="a1029" style="color: #336699; font-weight: bold;"&gt;Listing 10&amp;nbsp;&lt;/a&gt;. Get and save the drag initiator.&lt;/li&gt;&lt;li class="item" id="li1028" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_11" id="a1030" style="color: #336699; font-weight: bold;"&gt;Listing 11&amp;nbsp;&lt;/a&gt;. Populate a DragSource object with a copy of the image being dragged.&lt;/li&gt;&lt;li class="item" id="li1029" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_12" id="a1031" style="color: #336699; font-weight: bold;"&gt;Listing 12&amp;nbsp;&lt;/a&gt;. Initiate the drag and drop operation by calling the doDrag method.&lt;/li&gt;&lt;li class="item" id="li1030" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_13" id="a1032" style="color: #336699; font-weight: bold;"&gt;Listing 13&amp;nbsp;&lt;/a&gt;. The dragEnter event handler.&lt;/li&gt;&lt;li class="item" id="li1031" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_14" id="a1033" style="color: #336699; font-weight: bold;"&gt;Listing 14&amp;nbsp;&lt;/a&gt;. Beginning of the dragDrop event handler.&lt;/li&gt;&lt;li class="item" id="li1032" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_15" id="a1034" style="color: #336699; font-weight: bold;"&gt;Listing 15&amp;nbsp;&lt;/a&gt;. Do the drop.&lt;/li&gt;&lt;li class="item" id="li1033" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_16" id="a1035" style="color: #336699; font-weight: bold;"&gt;Listing 16&amp;nbsp;&lt;/a&gt;. The MXML file for DragAndDrop01.&lt;/li&gt;&lt;li class="item" id="li1034" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Listing_17" id="a1036" style="color: #336699; font-weight: bold;"&gt;Listing 17&amp;nbsp;&lt;/a&gt;. The ActionScript file for DragAndDrop01.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h21002" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Supplementary_material"&gt;Supplemental material&lt;/b&gt;&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="p1009" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I recommend that you also study the other lessons in my extensive collection of online programming tutorials. You will find a consolidated index at&amp;nbsp;&lt;a class="link" href="http://www.dickbaldwin.com/toc.htm" id="a1037" style="color: #336699;"&gt;www.DickBaldwin.com&amp;nbsp;&lt;/a&gt;.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11002" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="GeneralBackgroundInformation"&gt;General Background Information&lt;/b&gt;&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1010" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;For Adobe online documentation on this topic, see&amp;nbsp;&lt;a class="link" href="http://livedocs.adobe.com/flex/3/html/help.html?content=dragdrop_1.html" id="a1038" style="color: #336699;"&gt;Using Drag and Drop&amp;nbsp;&lt;/a&gt;.&lt;/div&gt;&lt;div class="para" id="p1011" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A drag and drop operation is carried out in three stages:&lt;/div&gt;&lt;div class="list" id="ul1006" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1035" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Initiation&lt;/li&gt;&lt;li class="item" id="li1036" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Dragging&lt;/li&gt;&lt;li class="item" id="li1037" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Dropping&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="p1012" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1004"&gt;Initiation&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1013" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As you are probably already aware, initiation consists of the user pointing to an item with the mouse and pressing the mouse button.&lt;/div&gt;&lt;div class="para" id="p1014" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1005"&gt;Dragging&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1015" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;During the drag operation, the user drags the item to another location on the screen without releasing the mouse button.&lt;/div&gt;&lt;div class="para" id="p1016" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1006"&gt;Dropping&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1017" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When the item has been dragged to the new location, the user releases the mouse button causing the item to remain in the new location.&lt;/div&gt;&lt;div class="para" id="p1018" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1007"&gt;Copying&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1019" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;It is also possible to copy an item using the drag and drop gestures, but that capability won't be illustrated in this lesson. Instead, this lesson will concentrate on moving a Flex component from one location in its container to a different location in its container.&lt;/div&gt;&lt;div class="para" id="p1020" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1008"&gt;Classes and events&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1021" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The sample program that I will explain in this lesson will use the following classes, methods, and events:&lt;/div&gt;&lt;div class="list" id="ul1007" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1038" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;MouseEvent class&lt;div class="list" id="ul1008" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1039" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;mouseDown event&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/li&gt;&lt;li class="item" id="li1040" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;DragEvent class&lt;div class="list" id="ul1009" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1041" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;dragDrop event&lt;/li&gt;&lt;li class="item" id="li1042" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;dragEnter event&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/li&gt;&lt;li class="item" id="li1043" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;DragManager class&lt;div class="list" id="ul1010" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1044" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;acceptDragDrop method&lt;/li&gt;&lt;li class="item" id="li1045" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;doDrag method&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/li&gt;&lt;li class="item" id="li1046" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;DragSource class&lt;div class="list" id="ul1011" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1047" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;addData method&lt;/li&gt;&lt;li class="item" id="li1048" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;hasFormat method&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11003" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Preview"&gt;Preview&lt;/b&gt;&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1022" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will explain a program named&amp;nbsp;&lt;b class="emphasis" id="strong1009"&gt;DragAndDrop01&amp;nbsp;&lt;/b&gt;. This program illustrates the fundamentals of drag and drop in ActionScript 3. The program places three images in the upper-left corner of a&lt;b class="emphasis" id="strong1010"&gt;Canvas&amp;nbsp;&lt;/b&gt;object as shown in Figure 1.&lt;/div&gt;&lt;div class="figure" id="figure1000" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 1:&amp;nbsp;&lt;/strong&gt;Program output at startup.&lt;/caption&gt;&lt;thead&gt;&lt;tr&gt;&lt;th class="figure-name" style="border-collapse: collapse; padding-bottom: 0.3em; padding-left: 0.3em; padding-right: 0.3em; padding-top: 0.3em; text-align: center;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Figure_1"&gt;&lt;/b&gt;Program output at startup.&lt;/strong&gt;&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="media1000"&gt;&lt;img alt="Program output at startup image." height="526" id="img1000" src="http://cnx.org/content/m34479/latest/as0140a.jpg" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="456" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="p1023" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1011"&gt;The program file structure&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1024" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The program file structure, taken from the Flex Builder 3 Navigator panel is as shown in Figure 2.&lt;/div&gt;&lt;div class="figure" id="figure1001" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 2:&amp;nbsp;&lt;/strong&gt;Program file structure.&lt;/caption&gt;&lt;thead&gt;&lt;tr&gt;&lt;th class="figure-name" style="border-collapse: collapse; padding-bottom: 0.3em; padding-left: 0.3em; padding-right: 0.3em; padding-top: 0.3em; text-align: center;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Figure_2"&gt;&lt;/b&gt;Program file structure.&lt;/strong&gt;&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="media1001"&gt;&lt;img alt="Program file structure." height="290" id="img1001" src="http://cnx.org/content/m34479/latest/as0140b.jpg" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="317" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="p1025" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1012"&gt;Three image files&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1026" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As you can see in Figure 2, the program uses&amp;nbsp;&lt;b class="emphasis" id="following"&gt;the following image files&amp;nbsp;&lt;/b&gt;:&lt;/div&gt;&lt;div class="list" id="ul1012" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1049" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;0 - space.jpg&lt;/li&gt;&lt;li class="item" id="li1050" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;1 - snowscene.jpg&lt;/li&gt;&lt;li class="item" id="li1051" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;2 - frog.jpg&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="p1027" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1013"&gt;The z-axes indices&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1028" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The program sets the z-axis indices in the order shown in the above&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#following" id="a1039" style="color: #336699; font-weight: bold;"&gt;list&amp;nbsp;&lt;/a&gt;on the&amp;nbsp;&lt;b class="emphasis" id="strong1014"&gt;Image&amp;nbsp;&lt;/b&gt;objects produced using the image files. This causes the&amp;nbsp;&lt;i class="emphasis" id="em1002"&gt;space&amp;nbsp;&lt;/i&gt;image to be in the back (0), the&amp;nbsp;&lt;i class="emphasis" id="em1003"&gt;frog&lt;/i&gt;image to be in the front (2), and the&amp;nbsp;&lt;i class="emphasis" id="em1004"&gt;snowscene&amp;nbsp;&lt;/i&gt;image to be in the middle (1).&lt;/div&gt;&lt;div class="para" id="p1029" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The three images are initially placed in the upper-left corner of the canvas, which is shown as a cyan rectangle in Figure 1.&lt;/div&gt;&lt;div class="para" id="p1030" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1015"&gt;Any image can be dragged&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1031" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;If you&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Click" id="a1040" style="color: #336699; font-weight: bold;"&gt;run&amp;nbsp;&lt;/a&gt;this program, you will see that any any of the images can be dragged and dropped anywhere within the canvas as long as the mouse pointer doesn't leave the canvas. However, if the edge of the dragged image goes outside the left edge or the top of the canvas, the drag and drop operation is aborted.&lt;/div&gt;&lt;div class="para" id="p1032" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;If the dragged image goes outside the right side or the bottom of the canvas, scroll bars automatically appear on the canvas as shown in Figure 3.&lt;/div&gt;&lt;div class="para" id="p1033" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1016"&gt;Program output after dragging the images&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1034" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Figure 3 shows the program output after dragging the three images to different locations.&lt;/div&gt;&lt;div class="figure" id="figure1002" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 3:&amp;nbsp;&lt;/strong&gt;Program output after dragging the images.&lt;/caption&gt;&lt;thead&gt;&lt;tr&gt;&lt;th class="figure-name" style="border-collapse: collapse; padding-bottom: 0.3em; padding-left: 0.3em; padding-right: 0.3em; padding-top: 0.3em; text-align: center;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Figure_3"&gt;&lt;/b&gt;Program output after dragging the images.&lt;/strong&gt;&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="media1002"&gt;&lt;img alt="Program output after dragging the images." height="526" id="img1002" src="http://cnx.org/content/m34479/latest/as0140c.jpg" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="456" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="p1035" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11004" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="DiscussionandSamplePrograms"&gt;&lt;/b&gt;Discussion and sample code&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1036" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1017"&gt;Will explain in fragments&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1037" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will explain the code for this program in fragments. Complete listings of the MXML code and the ActionScript code are provided in Listing 16 and Listing 17 near the end of the lesson.&lt;/div&gt;&lt;div class="section" id="h21003" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="The_MXML_file"&gt;The MXML file&lt;/b&gt;&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="p1038" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The MXML file is shown in Listing 1 and also in Listing 16 for your convenience.&lt;/div&gt;&lt;div class="example" id="listing1000" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 1:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_1"&gt;&lt;/b&gt;he MXML file for DragAndDrop01.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1000" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&lt;br /&gt;&amp;lt;!--DragAndDrop01--&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;mx:Application &lt;br /&gt;  xmlns:mx="http://www.adobe.com/2006/mxml" &lt;br /&gt;  xmlns:cc="CustomClasses.*"&amp;gt;&lt;br /&gt;  &lt;br /&gt;  &amp;lt;cc:Driver/&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;/mx:Application&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1039" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As you can see, the MXML file is very simple because the program was coded almost entirely in ActionScript. The MXML code simply instantiates an object of the&amp;nbsp;&lt;b class="emphasis" id="strong1018"&gt;Driver&amp;nbsp;&lt;/b&gt;class. From that point forward, the behavior of the program is controlled by ActionScript code.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h21004" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="The_ActionScript_file"&gt;The ActionScript file&lt;/b&gt;&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="p1040" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1019"&gt;Beginning of the Driver class&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1041" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The Driver class begins in Listing 2.&lt;/div&gt;&lt;div class="example" id="listing1001" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 2:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_2"&gt;&lt;/b&gt;Beginning of the Driver class for DragAndDrop01.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1001" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;package CustomClasses{&lt;br /&gt;  import flash.events.MouseEvent;&lt;br /&gt;  &lt;br /&gt;  import mx.containers.Canvas;&lt;br /&gt;  import mx.controls.Image;&lt;br /&gt;  import mx.core.DragSource;&lt;br /&gt;  import mx.events.DragEvent;&lt;br /&gt;  import mx.events.FlexEvent;&lt;br /&gt;  import mx.managers.DragManager;&lt;br /&gt;&lt;br /&gt;  //====================================================//&lt;br /&gt;  &lt;br /&gt;  public class Driver extends Canvas {&lt;br /&gt;    private var imageA:Image = new Image();&lt;br /&gt;    private var imageB:Image = new Image();&lt;br /&gt;    private var imageC:Image = new Image();&lt;br /&gt;    private var localX:Number;&lt;br /&gt;    private var localY:Number;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1042" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1020"&gt;Extends the Canvas class&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1043" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As you can see in Listing 2, the&amp;nbsp;&lt;b class="emphasis" id="strong1021"&gt;Driver&amp;nbsp;&lt;/b&gt;class extends the&amp;nbsp;&lt;b class="emphasis" id="strong1022"&gt;Canvas&amp;nbsp;&lt;/b&gt;class. Therefore, an object of the&amp;nbsp;&lt;b class="emphasis" id="strong1023"&gt;Driver&amp;nbsp;&lt;/b&gt;class is a&amp;nbsp;&lt;b class="emphasis" id="strong1024"&gt;Canvas&amp;nbsp;&lt;/b&gt;object and has all of the attributes associated with a&amp;nbsp;&lt;b class="emphasis" id="strong1025"&gt;Canvas&lt;/b&gt;object. Among those attributes is the following, which was taken from the&amp;nbsp;&lt;a class="link" href="http://livedocs.adobe.com/flex/3/langref/mx/containers/Canvas.html" id="a1041" style="color: #336699;"&gt;documentation&amp;nbsp;&lt;/a&gt;:&lt;/div&gt;&lt;blockquote class="quote" id="blockquote1000" style="font-style: italic; line-height: normal; margin-bottom: 1em; margin-left: 3em; margin-right: 3em; margin-top: 1em;"&gt;&lt;div class="para" id="p1044" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;"A Canvas layout container defines a rectangular region in which you place child containers and controls. It is the only container that lets you explicitly specify the location of its children within the container by using the x and y properties of each child."&lt;/div&gt;&lt;/blockquote&gt;&lt;div class="para" id="p1045" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As you will see, the new location of each image is explicitly specified each time it is dragged to a new location.&lt;/div&gt;&lt;div class="para" id="p1046" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1026"&gt;Instantiate three new Image objects&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1047" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The code in Listing 2 instantiates three new&amp;nbsp;&lt;b class="emphasis" id="strong1027"&gt;Image&amp;nbsp;&lt;/b&gt;objects, which will be loaded with the contents of the three image files listed&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#following" id="a1042" style="color: #336699; font-weight: bold;"&gt;earlier&amp;nbsp;&lt;/a&gt;. The code in Listing 2 also declares two instance variables that will be used to store the position of the mouse pointer within an image when the drag operation is initiated.&lt;/div&gt;&lt;div class="para" id="p1048" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1028"&gt;Beginning of the constructor for the Driver class&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1049" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The constructor for the&amp;nbsp;&lt;b class="emphasis" id="strong1029"&gt;Driver&amp;nbsp;&lt;/b&gt;class begins in Listing 3.&lt;/div&gt;&lt;div class="example" id="listing1002" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 3:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_3"&gt;&lt;/b&gt;Beginning of the constructor for the Driver class.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1002" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;    public function Driver(){//constructor&lt;br /&gt;      setStyle("backgroundColor",0x00FFFF);&lt;br /&gt;      setStyle("backgroundAlpha",1.0);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1050" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1030"&gt;Make the canvas visible&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1051" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Normally a&amp;nbsp;&lt;b class="emphasis" id="strong1031"&gt;Canvas&amp;nbsp;&lt;/b&gt;object is not visible. The code in Listing 3 sets the alpha value for the&amp;nbsp;&lt;b class="emphasis" id="strong1032"&gt;Canvas&amp;nbsp;&lt;/b&gt;object to 1.0 making it opaque and visible. Listing 3 also sets the background color of the&amp;nbsp;&lt;b class="emphasis" id="strong1033"&gt;Canvas&amp;nbsp;&lt;/b&gt;object to cyan as shown in Figure 1.&lt;/div&gt;&lt;div class="para" id="p1052" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The size of the&amp;nbsp;&lt;b class="emphasis" id="strong1034"&gt;Canvas&amp;nbsp;&lt;/b&gt;object will be set later when the&amp;nbsp;&lt;b class="emphasis" id="strong1035"&gt;Canvas&amp;nbsp;&lt;/b&gt;object and all of its children have been constructed.&lt;/div&gt;&lt;div class="para" id="p1053" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1036"&gt;Prepare the three images&lt;/b&gt;&lt;b class="emphasis" id="strong1037"&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1054" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 4 prepares the three images for use by the program.&lt;/div&gt;&lt;div class="example" id="listing1003" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 4:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_4"&gt;&lt;/b&gt;Prepare the three images.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1003" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      //Embed the image files in the SWF file.&lt;br /&gt;      [Embed("snowscene.jpg")]&lt;br /&gt;      var imgA:Class;&lt;br /&gt;      &lt;br /&gt;      [Embed("space.jpg")]&lt;br /&gt;      var imgB:Class;&lt;br /&gt;      &lt;br /&gt;      [Embed("frog.jpg")]&lt;br /&gt;      var imgC:Class;&lt;br /&gt;      &lt;br /&gt;      //Load the images from the embedded image files&lt;br /&gt;      // into the Image objects.&lt;br /&gt;      imageA.load(imgA);&lt;br /&gt;      imageB.load(imgB);&lt;br /&gt;      imageC.load(imgC);&lt;br /&gt;      &lt;br /&gt;      // Set the z-axes indices such that the frog is&lt;br /&gt;      // in front, the snowscene is in the middle and the &lt;br /&gt;      // space image is at the back.&lt;br /&gt;      addChildAt(imageB,0);//set index to 0&lt;br /&gt;      addChildAt(imageA,1);//set index to 1&lt;br /&gt;      addChildAt(imageC,2);//set index to 2&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1055" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 4 begins by embedding the three image files in the SWF file. Then it loads the contents of the image files into the&amp;nbsp;&lt;b class="emphasis" id="strong1038"&gt;Image&amp;nbsp;&lt;/b&gt;objects instantiated in Listing 2. Finally Listing 3 adds the&amp;nbsp;&lt;b class="emphasis" id="strong1039"&gt;Image&amp;nbsp;&lt;/b&gt;objects as children of the&amp;nbsp;&lt;b class="emphasis" id="strong1040"&gt;Canvas&amp;nbsp;&lt;/b&gt;object.&lt;/div&gt;&lt;div class="para" id="p1056" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1041"&gt;Set the z-axis indices&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1057" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The z-axis index of each&amp;nbsp;&lt;b class="emphasis" id="strong1042"&gt;Image&amp;nbsp;&lt;/b&gt;object is set in Figure 4 so as to place the space image at the back, the frog image at the front, and the snowscene image between the other two.&lt;/div&gt;&lt;div class="para" id="p1058" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1043"&gt;Register a creationComplete event handler&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1059" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 5 registers a&amp;nbsp;&lt;b class="emphasis" id="strong1044"&gt;creationComplete&amp;nbsp;&lt;/b&gt;event handler on the&amp;nbsp;&lt;b class="emphasis" id="strong1045"&gt;Canvas&amp;nbsp;&lt;/b&gt;object. This event handler will be executed after the&amp;nbsp;&lt;b class="emphasis" id="strong1046"&gt;Canvas&amp;nbsp;&lt;/b&gt;object and all of its children are fully constructed.&lt;/div&gt;&lt;div class="example" id="listing1004" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 5:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_5"&gt;&lt;/b&gt;Register a creationComplete event handler.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1004" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      this.addEventListener(FlexEvent.CREATION_COMPLETE,&lt;br /&gt;                                         completeHandler);&lt;br /&gt;    } //end constructor&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1060" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1047"&gt;Beginning of the creationComplete event handler&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1061" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;b class="emphasis" id="strong1048"&gt;creationComplete&amp;nbsp;&lt;/b&gt;event handler begins in Listing 6. This handler is executed once when the&amp;nbsp;&lt;b class="emphasis" id="strong1049"&gt;Canvas&amp;nbsp;&lt;/b&gt;object and all of its children have been constructed.&lt;/div&gt;&lt;div class="example" id="listing1005" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 6:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_6"&gt;&lt;/b&gt;Beginning of the creationComplete event handler.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1005" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;    private function completeHandler(&lt;br /&gt;                          event:mx.events.FlexEvent):void{&lt;br /&gt;      //Set the width and height of the canvas based on &lt;br /&gt;      // the dimensions of imageB.&lt;br /&gt;      this.width = 1.3*imageB.width;&lt;br /&gt;      this.height = 1.3*imageB.height;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1062" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1050"&gt;Set the size of the Canvas object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1063" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 6 sets the width and height of the&amp;nbsp;&lt;b class="emphasis" id="strong1051"&gt;Canvas&amp;nbsp;&lt;/b&gt;object based on the dimensions of the&amp;nbsp;&lt;b class="emphasis" id="strong1052"&gt;Image&amp;nbsp;&lt;/b&gt;object referred to by&amp;nbsp;&lt;b class="emphasis" id="strong1053"&gt;imageB&amp;nbsp;&lt;/b&gt;. It was not possible to reliably execute this code in the constructor because the code might be executed before the contents of the image file were fully loaded into the&amp;nbsp;&lt;b class="emphasis" id="strong1054"&gt;Image&amp;nbsp;&lt;/b&gt;object.&lt;/div&gt;&lt;div class="para" id="p1064" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1055"&gt;Register a mouseDown event handler on each&amp;nbsp;&lt;b class="emphasis" id="strong1056"&gt;Image&amp;nbsp;&lt;/b&gt;object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1065" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A drag and drop operation is heavily dependent on the handling of different types of events. The remaining code in the&amp;nbsp;&lt;b class="emphasis" id="strong1057"&gt;creationComplete&amp;nbsp;&lt;/b&gt;event handler registers appropriate event handlers on the images and on the&amp;nbsp;&lt;b class="emphasis" id="strong1058"&gt;Canvas&amp;nbsp;&lt;/b&gt;object to support the drag and drop operation with the&amp;nbsp;&lt;b class="emphasis" id="strong1059"&gt;Canvas&amp;nbsp;&lt;/b&gt;object as the drag target.&lt;/div&gt;&lt;div class="para" id="p1066" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As you will see later, a drag operation is initialized when an image dispatches a&amp;nbsp;&lt;b class="emphasis" id="strong1060"&gt;mouseDown&amp;nbsp;&lt;/b&gt;event. Listing 7 registers the same&amp;nbsp;&lt;b class="emphasis" id="strong1061"&gt;mouseDown&amp;nbsp;&lt;/b&gt;event handler on all three&amp;nbsp;&lt;b class="emphasis" id="strong1062"&gt;Image&amp;nbsp;&lt;/b&gt;objects.&lt;/div&gt;&lt;div class="example" id="listing1006" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 7:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_7"&gt;&lt;/b&gt;Register a mouseDown event handler on each Image object.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1006" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      imageA.addEventListener(MouseEvent.MOUSE_DOWN,&lt;br /&gt;                                        mouseDownHandler);&lt;br /&gt;      imageB.addEventListener(MouseEvent.MOUSE_DOWN,&lt;br /&gt;                                        mouseDownHandler);&lt;br /&gt;      imageC.addEventListener(MouseEvent.MOUSE_DOWN,&lt;br /&gt;                                        mouseDownHandler);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1067" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1063"&gt;Register dragDrop and dragEnter event handlers on the&amp;nbsp;&lt;b class="emphasis" id="strong1064"&gt;Canvas&amp;nbsp;&lt;/b&gt;object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1068" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Two different event handlers must be registered on the drag target, which is the&amp;nbsp;&lt;b class="emphasis" id="strong1065"&gt;Canvas&amp;nbsp;&lt;/b&gt;object in this case. The registration of those event handlers on the&amp;nbsp;&lt;b class="emphasis" id="strong1066"&gt;Canvas&amp;nbsp;&lt;/b&gt;object is accomplished in Listing 8.&lt;/div&gt;&lt;div class="example" id="listing1007" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 8:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_8"&gt;&lt;/b&gt;Register dragDrop and dragEnter event handlers on the Canvas object.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1007" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      this.addEventListener(DragEvent.DRAG_DROP,&lt;br /&gt;                                             dropHandler);&lt;br /&gt;      this.addEventListener(DragEvent.DRAG_ENTER,&lt;br /&gt;                                        enterHandler);&lt;br /&gt;    } //end completeHandler&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1069" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1067"&gt;Beginning of the mouseDown event handler&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1070" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;b class="emphasis" id="strong1068"&gt;mouseDown&amp;nbsp;&lt;/b&gt;event handler that was registered on the&amp;nbsp;&lt;b class="emphasis" id="strong1069"&gt;Image&amp;nbsp;&lt;/b&gt;objects in Listing 7 begins in Listing 9. This event handler initiates the drag and drop operation on the&amp;nbsp;&lt;b class="emphasis" id="strong1070"&gt;Image&amp;nbsp;&lt;/b&gt;object that dispatches the event.&lt;/div&gt;&lt;div class="example" id="listing1008" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 9:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_9"&gt;&lt;/b&gt;Beginning of the mouseDown event handler.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1008" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;    private function mouseDownHandler(&lt;br /&gt;                                   event:MouseEvent):void{&lt;br /&gt;&lt;br /&gt;      //Save the location of the mouse within the image&lt;br /&gt;      // being dragged. This information will be used&lt;br /&gt;      // later to properly position the dropped image in&lt;br /&gt;      // the drop target.&lt;br /&gt;      this.localX = event.localX;&lt;br /&gt;      this.localY = event.localY;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1071" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1071"&gt;Positioning the dropped object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1072" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The easiest approach simply drops the image with its upper-left corner at the position of the mouse pointer when the mouse button is released. However, in my opinion, that is somewhat less than satisfactory from a visual viewpoint.&lt;/div&gt;&lt;div class="para" id="p1073" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1072"&gt;The drag proxy&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1074" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When you drag an image, there is a default drag proxy that moves along with the mouse.&amp;nbsp;&lt;i class="emphasis" id="em1005"&gt;(It is possible to replace the default drag proxy with a drag proxy of your choice.)&amp;nbsp;&lt;/i&gt;The default drag proxy is a partially transparent rectangle that is the same size as the image.&lt;/div&gt;&lt;div class="para" id="p1075" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1073"&gt;Adjust the position of the upper-left corner&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1076" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="tendency"&gt;My preference is to manually adjust&amp;nbsp;&lt;/b&gt;the drop location of the image based on the upper-left corner of the drag proxy and not based on the location of the mouse pointer. The code in Listing 9 gets and saves the coordinates of the mouse pointer within the image when the event is dispatched. As you will see later, I use these coordinates later to set the drop location on the basis of the upper-left corner of the proxy.&lt;/div&gt;&lt;div class="para" id="p1077" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1074"&gt;Get and save the drag initiator&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1078" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The documentation refers to the object being dragged as the&amp;nbsp;&lt;i class="emphasis" id="em1006"&gt;drag initiator&amp;nbsp;&lt;/i&gt;.&lt;/div&gt;&lt;div class="example" id="listing1009" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 10:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_10"&gt;&lt;/b&gt;Get and save the drag initiator.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1009" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      //Get the drag initiator component from the event&lt;br /&gt;      // object and cast it to the correct type.&lt;br /&gt;      var dragInitiator:Image = Image(&lt;br /&gt;                                     event.currentTarget);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1079" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In this program, the drag initiator could be any of the three images shown in Figure 1 and Figure 3.&lt;/div&gt;&lt;div class="para" id="p1080" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The code in Listing 10&lt;/div&gt;&lt;div class="list" id="ul1013" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1052" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Gets a reference to the&amp;nbsp;&lt;b class="emphasis" id="strong1075"&gt;Image&amp;nbsp;&lt;/b&gt;object that dispatched the&amp;nbsp;&lt;b class="emphasis" id="strong1076"&gt;mouseDown&amp;nbsp;&lt;/b&gt;event from the incoming method parameter&lt;/li&gt;&lt;li class="item" id="li1053" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Casts it to type&amp;nbsp;&lt;b class="emphasis" id="strong1077"&gt;Image&amp;nbsp;&lt;/b&gt;, and&lt;/li&gt;&lt;li class="item" id="li1054" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Saves it in the variable named&amp;nbsp;&lt;b class="emphasis" id="strong1078"&gt;dragInitiator&amp;nbsp;&lt;/b&gt;.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="p1081" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1079"&gt;Populate a DragSource object with a copy of the image being dragged&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1082" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Here is part of what the&amp;nbsp;&lt;a class="link" href="http://livedocs.adobe.com/flex/3/langref/mx/core/DragSource.html" id="a1043" style="color: #336699;"&gt;documentation&amp;nbsp;&lt;/a&gt;has to say about the&amp;nbsp;&lt;b class="emphasis" id="strong1080"&gt;DragSource&amp;nbsp;&lt;/b&gt;class.&lt;/div&gt;&lt;blockquote class="quote" id="blockquote1001" style="font-style: italic; line-height: normal; margin-bottom: 1em; margin-left: 3em; margin-right: 3em; margin-top: 1em;"&gt;&lt;div class="para" id="p1083" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;"The DragSource class contains the data being dragged. The data can be in multiple formats, depending on the type of control that initiated the drag.&lt;/div&gt;&lt;div class="para" id="p1084" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Each format of data is identified with a string. ... Data can be added directly using the addData() method, or indirectly using the addHandler() method."&lt;/div&gt;&lt;/blockquote&gt;&lt;div class="para" id="p1085" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 11 adds the image being dragged to a new&amp;nbsp;&lt;b class="emphasis" id="strong1081"&gt;DragSource&amp;nbsp;&lt;/b&gt;object and provides an identifier for the format as a string. You will see later how this string is used to establish the drop target.&lt;/div&gt;&lt;div class="example" id="listing1010" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 11:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_11"&gt;&lt;/b&gt;Populate a DragSource object with a copy of the image being dragged.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1010" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      var dragSource:DragSource = new DragSource();&lt;br /&gt;&lt;br /&gt;      dragSource.addData(dragInitiator,"imageObject");&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1086" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1082"&gt;Initiate the drag and drop operation by calling the doDrag method&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1087" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 12 initiates the drag and drop operation by calling the static&amp;nbsp;&lt;b class="emphasis" id="strong1083"&gt;doDrag&amp;nbsp;&lt;/b&gt;method of the&amp;nbsp;&lt;b class="emphasis" id="strong1084"&gt;DragManager&amp;nbsp;&lt;/b&gt;class.&lt;/div&gt;&lt;div class="example" id="listing1011" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 12:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_12"&gt;&lt;/b&gt;Initiate the drag and drop operation by calling the doDrag method.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1011" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      DragManager.doDrag(dragInitiator,dragSource,event);&lt;br /&gt;&lt;br /&gt;    }//end mouseDownHandler&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1088" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1085"&gt;What does the documentation have to say about the DragManager class?&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1089" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Here is part of what the&amp;nbsp;&lt;a class="link" href="http://livedocs.adobe.com/flex/3/langref/mx/managers/DragManager.html" id="a1044" style="color: #336699;"&gt;documentation&amp;nbsp;&lt;/a&gt;has to say about the&amp;nbsp;&lt;b class="emphasis" id="strong1086"&gt;DragManager&amp;nbsp;&lt;/b&gt;class.&lt;/div&gt;&lt;blockquote class="quote" id="blockquote1002" style="font-style: italic; line-height: normal; margin-bottom: 1em; margin-left: 3em; margin-right: 3em; margin-top: 1em;"&gt;&lt;div class="para" id="p1090" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;"The&amp;nbsp;&lt;b class="emphasis" id="strong1087"&gt;DragManager&amp;nbsp;&lt;/b&gt;class manages drag and drop operations, which let you move data from one place to another in a Flex application. For example, you can select an object, such as an item in a List control or a Flex control, such as an Image control, and then drag it over another component to add it to that component.&lt;/div&gt;&lt;div class="para" id="p1091" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;All methods and properties of the&amp;nbsp;&lt;b class="emphasis" id="strong1088"&gt;&lt;/b&gt;DragManager&amp;nbsp;&lt;b class="emphasis" id="strong1089"&gt;&lt;/b&gt;are static, so you do not need to create an instance of it. ...&lt;/div&gt;&lt;div class="para" id="p1092" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When the user selects an item with the mouse, the selected component is called the drag initiator. The image displayed during the drag operation is called the drag proxy.&lt;/div&gt;&lt;div class="para" id="p1093" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When the user moves the drag proxy over another component, the&amp;nbsp;&lt;b class="emphasis" id="dragEnter"&gt;dragEnter&amp;nbsp;&lt;/b&gt;event is sent to that component. If the component accepts the drag, it becomes the drop target and receives dragOver, dragExit, and&amp;nbsp;&lt;b class="emphasis" id="strong1090"&gt;&lt;/b&gt;dragDrop&amp;nbsp;&lt;b class="emphasis" id="strong1091"&gt;&lt;/b&gt;events.&lt;/div&gt;&lt;div class="para" id="p1094" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When the drag is complete, a dragComplete event is sent to the drag initiator."&lt;/div&gt;&lt;/blockquote&gt;&lt;div class="para" id="p1095" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1092"&gt;What about the doDrag method?&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1096" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The documentation states simply that the&amp;nbsp;&lt;b class="emphasis" id="strong1093"&gt;doDrag&amp;nbsp;&lt;/b&gt;method&lt;/div&gt;&lt;div class="para" id="p1097" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;"Initiates a drag and drop operation."&lt;/div&gt;&lt;div class="para" id="p1098" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1094"&gt;The doDrag method parameters&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1099" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;b class="emphasis" id="strong1095"&gt;doDrag&amp;nbsp;&lt;/b&gt;method has several parameters with default values in addition to the three shown in Listing 12. Here is part of what the documentation has to say about the three parameters passed to the&amp;nbsp;&lt;b class="emphasis" id="strong1096"&gt;doDrag&amp;nbsp;&lt;/b&gt;method in Listing 12.&lt;/div&gt;&lt;div class="list" id="ul1014" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1055" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;b class="emphasis" id="strong1097"&gt;dragInitiator&amp;nbsp;&lt;/b&gt;&lt;b class="emphasis" id="strong1098"&gt;:IUIComponent&amp;nbsp;&lt;/b&gt;- IUIComponent that specifies the component initiating the drag.&lt;/li&gt;&lt;li class="item" id="li1056" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;b class="emphasis" id="strong1099"&gt;dragSource&amp;nbsp;&lt;/b&gt;&lt;b class="emphasis" id="strong1100"&gt;:DragSource&amp;nbsp;&lt;/b&gt;- DragSource object that contains the data being dragged.&lt;/li&gt;&lt;li class="item" id="li1057" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;b class="emphasis" id="strong1101"&gt;event:MouseEvent&amp;nbsp;&lt;/b&gt;- The MouseEvent that contains the mouse information from the start of the drag.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="p1100" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1102"&gt;The end of the mouseDown event handler&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1101" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 12 signals the end of the&amp;nbsp;&lt;b class="emphasis" id="strong1103"&gt;mouseDown&amp;nbsp;&lt;/b&gt;event handler. This leaves two more event handlers to be discussed. The remaining two event handlers were registered on the drop target&amp;nbsp;&lt;i class="emphasis" id="em1007"&gt;(&amp;nbsp;&lt;/i&gt;&lt;b class="emphasis" id="strong1104"&gt;&lt;i class="emphasis" id="em1008"&gt;Canvas&amp;nbsp;&lt;/i&gt;&lt;/b&gt;&lt;i class="emphasis" id="em1009"&gt;object)&amp;nbsp;&lt;/i&gt;by the code in Listing 8.&lt;/div&gt;&lt;div class="para" id="p1102" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1105"&gt;The dragEnter event handler&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1103" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As you learned&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#dragEnter" id="a1045" style="color: #336699; font-weight: bold;"&gt;earlier&amp;nbsp;&lt;/a&gt;, when the user moves the drag proxy over another component, that component dispatches a&amp;nbsp;&lt;b class="emphasis" id="strong1106"&gt;dragEnter&amp;nbsp;&lt;/b&gt;event.&lt;/div&gt;&lt;div class="para" id="p1104" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;If a&amp;nbsp;&lt;b class="emphasis" id="strong1107"&gt;dragEnter&amp;nbsp;&lt;/b&gt;event handler has been registered on that component, the handler method is executed. If the code in the event handler accepts the drag, it becomes the drop target and receives&amp;nbsp;&lt;b class="emphasis" id="strong1108"&gt;dragOver&amp;nbsp;&lt;/b&gt;,&amp;nbsp;&lt;b class="emphasis" id="strong1109"&gt;dragExit&amp;nbsp;&lt;/b&gt;, and&amp;nbsp;&lt;b class="emphasis" id="strong1110"&gt;dragDrop&amp;nbsp;&lt;/b&gt;events.&lt;/div&gt;&lt;div class="para" id="p1105" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In this case the intended drop target is the&amp;nbsp;&lt;b class="emphasis" id="strong1111"&gt;Canvas&amp;nbsp;&lt;/b&gt;object and the event handler shown in Listing 13 is registered on that object.&lt;/div&gt;&lt;div class="example" id="listing1012" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 13:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_13"&gt;&lt;/b&gt;The dragEnter event handler.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1012" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;    private function enterHandler(event:DragEvent):void{&lt;br /&gt;      if (event.dragSource.hasFormat("imageObject")){&lt;br /&gt;          DragManager.acceptDragDrop(&lt;br /&gt;                             Canvas(event.currentTarget));&lt;br /&gt;      } //end if&lt;br /&gt;    } //end enterHandler&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1106" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1112"&gt;Confirm the correct format string&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1107" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The code in Listing 13 checks to confirm that the format string in the&amp;nbsp;&lt;b class="emphasis" id="strong1113"&gt;DragSource&amp;nbsp;&lt;/b&gt;object matches "imageObject" (see Listing 11). If so, it calls the static&amp;nbsp;&lt;b class="emphasis" id="strong1114"&gt;acceptDragDrop&amp;nbsp;&lt;/b&gt;method on the&amp;nbsp;&lt;b class="emphasis" id="strong1115"&gt;DragManager&amp;nbsp;&lt;/b&gt;class, passing a reference to itself as a parameter in the method call.&lt;/div&gt;&lt;div class="para" id="p1108" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1116"&gt;Accept the dragged object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1109" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The call to the&amp;nbsp;&lt;b class="emphasis" id="strong1117"&gt;acceptDragDrop&amp;nbsp;&lt;/b&gt;method notifies the&amp;nbsp;&lt;b class="emphasis" id="strong1118"&gt;DragManager&amp;nbsp;&lt;/b&gt;that the&amp;nbsp;&lt;b class="emphasis" id="strong1119"&gt;Canvas&amp;nbsp;&lt;/b&gt;object is willing to accept the contents of the&amp;nbsp;&lt;b class="emphasis" id="strong1120"&gt;DragSource&amp;nbsp;&lt;/b&gt;object being dropped onto itself.&lt;/div&gt;&lt;div class="para" id="p1110" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1121"&gt;Beginning of the dragDrop event handler&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1111" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;b class="emphasis" id="strong1122"&gt;dragDrop&amp;nbsp;&lt;/b&gt;event handler was registered on the&amp;nbsp;&lt;b class="emphasis" id="strong1123"&gt;Canvas&amp;nbsp;&lt;/b&gt;object in Listing 8. This method is executed after the&amp;nbsp;&lt;b class="emphasis" id="strong1124"&gt;Canvas&amp;nbsp;&lt;/b&gt;object accepts the drag and the user releases the mouse button while the drag proxy is over the&amp;nbsp;&lt;b class="emphasis" id="strong1125"&gt;Canvas&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="para" id="p1112" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1126"&gt;Correct the drop position for the image&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1113" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The code in Listing 14 uses the current location of the mouse pointer along with the values stored in&amp;nbsp;&lt;b class="emphasis" id="strong1127"&gt;localX&amp;nbsp;&lt;/b&gt;and&amp;nbsp;&lt;b class="emphasis" id="strong1128"&gt;localY&amp;nbsp;&lt;/b&gt;to compute the new location for the upper-left corner of the image when it is dropped on the canvas.&lt;/div&gt;&lt;blockquote class="quote" id="blockquote1003" style="font-style: italic; line-height: normal; margin-bottom: 1em; margin-left: 3em; margin-right: 3em; margin-top: 1em;"&gt;&lt;div class="para" id="p1114" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1010" style="font-style: normal;"&gt;(Recall that&amp;nbsp;&lt;/i&gt;&lt;b class="emphasis" id="strong1129"&gt;&lt;i class="emphasis" id="em1011" style="font-style: normal;"&gt;localX&amp;nbsp;&lt;/i&gt;&lt;/b&gt;&lt;i class="emphasis" id="em1012" style="font-style: normal;"&gt;and&amp;nbsp;&lt;/i&gt;&lt;b class="emphasis" id="strong1130"&gt;&lt;i class="emphasis" id="em1013" style="font-style: normal;"&gt;localY&amp;nbsp;&lt;/i&gt;&lt;/b&gt;&lt;i class="emphasis" id="em1014" style="font-style: normal;"&gt;contain the coordinates of the mouse pointer relative to the upper-left corner of the image when the&amp;nbsp;&lt;/i&gt;&lt;b class="emphasis" id="strong1131"&gt;&lt;i class="emphasis" id="em1015" style="font-style: normal;"&gt;mouseDown&amp;nbsp;&lt;/i&gt;&lt;/b&gt;&lt;i class="emphasis" id="em1016" style="font-style: normal;"&gt;event was dispatched by the image and the drag and drop operation began.)&lt;/i&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;div class="para" id="p1115" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I explained the need for this position adjustment&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#tendency" id="a1046" style="color: #336699; font-weight: bold;"&gt;earlier&amp;nbsp;&lt;/a&gt;.&lt;/div&gt;&lt;div class="example" id="listing1013" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 14:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_14"&gt;&lt;/b&gt;Beginning of the dragDrop event handler.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1013" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;    private function dropHandler(event:DragEvent):void{      &lt;br /&gt;&lt;br /&gt;      var cornerX:Number = (Canvas(event.currentTarget).&lt;br /&gt;                                         mouseX) - localX;&lt;br /&gt;      var cornerY:Number = (Canvas(event.currentTarget).&lt;br /&gt;                                         mouseY) - localY;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1116" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1132"&gt;Do the drop&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1117" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 15 checks to confirm that the location at which the upper-left corner of the image will be placed is within the bounds of the canvas on the left side and the top. If so, it sets the coordinates of the&amp;nbsp;&lt;b class="emphasis" id="strong1133"&gt;Image&amp;nbsp;&lt;/b&gt;object that dispatched the original&amp;nbsp;&lt;b class="emphasis" id="strong1134"&gt;mouseDown&amp;nbsp;&lt;/b&gt;event to the coordinates that were computed in Listing 14. This causes that&amp;nbsp;&lt;b class="emphasis" id="strong1135"&gt;Image&amp;nbsp;&lt;/b&gt;object to move to the new position on the&amp;nbsp;&lt;b class="emphasis" id="strong1136"&gt;Canvas&amp;nbsp;&lt;/b&gt;object.&lt;/div&gt;&lt;div class="example" id="listing1014" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h4 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 15:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_15"&gt;&lt;/b&gt;Do the drop.&lt;/strong&gt;&lt;/h4&gt;&lt;div class="code" id="pre1014" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      if((cornerX &amp;gt; 0.0) &amp;amp;&amp;amp; (cornerY &amp;gt; 0.0)){&lt;br /&gt;        Image(event.dragInitiator).x = cornerX;&lt;br /&gt;        Image(event.dragInitiator).y = cornerY&lt;br /&gt;      } //end if&lt;br /&gt;    } //end dropHandler&lt;br /&gt;    //--------------------------------------------------//&lt;br /&gt;      &lt;br /&gt;  } //end class&lt;br /&gt;} //end package&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1118" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1137"&gt;The end of the program&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1119" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 15 also signals the end of the&amp;nbsp;&lt;b class="emphasis" id="strong1138"&gt;dragDrop&amp;nbsp;&lt;/b&gt;event handler, the end of the&amp;nbsp;&lt;b class="emphasis" id="strong1139"&gt;Driver&amp;nbsp;&lt;/b&gt;class, and the end of the program.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11005" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Runtheprogram"&gt;&lt;/b&gt;Run the program&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1120" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I encourage you to&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34479/latest/#Click" id="a1047" style="color: #336699; font-weight: bold;"&gt;run&amp;nbsp;&lt;/a&gt;this program from the web. Then copy the code from Listing 16 and Listing 17. Use that code to create a Flex project. Compile and run the project. Experiment with the code, making changes, and observing the results of your changes. Make certain that you can explain why your changes behave as they do.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11006" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Resources"&gt;Resources&lt;/b&gt;&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1121" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will publish a list containing links to ActionScript resources as a separate document. Search for ActionScript Resources in the Connexions search box.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11007" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="CompleteProgramListings"&gt;&lt;/b&gt;Complete program listings&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1122" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Complete listings for the MXML and ActionScript code discussed in this lesson are provided in Listing 16 and Listing 17 below.&lt;/div&gt;&lt;div class="example" id="listing1015" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h3 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 16:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_16"&gt;&lt;/b&gt;The MXML file for DragAndDrop01.&lt;/strong&gt;&lt;/h3&gt;&lt;div class="code" id="pre1015" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&lt;br /&gt;&amp;lt;!--DragAndDrop01&lt;br /&gt;--&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;mx:Application &lt;br /&gt;  xmlns:mx="http://www.adobe.com/2006/mxml" &lt;br /&gt;  xmlns:cc="CustomClasses.*"&amp;gt;&lt;br /&gt;  &lt;br /&gt;  &amp;lt;cc:Driver/&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;/mx:Application&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1123" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;/div&gt;&lt;div class="example" id="listing1016" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h3 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 17:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_17"&gt;&lt;/b&gt;The ActionScript file for DragAndDrop01.&lt;/strong&gt;&lt;/h3&gt;&lt;div class="code" id="pre1016" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;/*DragAndDrop01&lt;br /&gt;Illustrates the fundamentals of drag and drop in&lt;br /&gt;ActionScript 3.&lt;br /&gt;&lt;br /&gt;Places three images in a Canvas object:&lt;br /&gt;&lt;br /&gt;0 - space.jpg - largest&lt;br /&gt;1 - snowscene.jpg - midsize&lt;br /&gt;2 - frog.jpg - smallest&lt;br /&gt;&lt;br /&gt;Sets the z-axis indices as shown above. This causes the &lt;br /&gt;space image to be in the back, the frog image to be in the&lt;br /&gt;front, and the snowscene image to be in the middle.&lt;br /&gt;&lt;br /&gt;Any of the images can be dragged and dropped anywhere &lt;br /&gt;within the canvas so long as the mouse pointer doesn't &lt;br /&gt;leave the canvas. However, If the edge of the dragged &lt;br /&gt;image goes outside the left edge or the top of the canvas,&lt;br /&gt;the drag and drop operation is aborted. If the dragged &lt;br /&gt;image goes outside the right side or the bottom of the &lt;br /&gt;canvas, scroll bars automatically appear on the canvas.&lt;br /&gt;&lt;br /&gt;The size of the canvas is based on the size of the space&lt;br /&gt;image so that other images can be substituted for mine &lt;br /&gt;when the program is recompiled so long as the file names &lt;br /&gt;and paths are the same.&lt;br /&gt;*********************************************************/&lt;br /&gt;package CustomClasses{&lt;br /&gt;  import flash.events.MouseEvent;&lt;br /&gt;  &lt;br /&gt;  import mx.containers.Canvas;&lt;br /&gt;  import mx.controls.Image;&lt;br /&gt;  import mx.core.DragSource;&lt;br /&gt;  import mx.events.DragEvent;&lt;br /&gt;  import mx.events.FlexEvent;&lt;br /&gt;  import mx.managers.DragManager;&lt;br /&gt;&lt;br /&gt;  //====================================================//&lt;br /&gt;  &lt;br /&gt;  public class Driver extends Canvas {&lt;br /&gt;    private var imageA:Image = new Image();&lt;br /&gt;    private var imageB:Image = new Image();&lt;br /&gt;    private var imageC:Image = new Image();&lt;br /&gt;    private var localX:Number;&lt;br /&gt;    private var localY:Number;&lt;br /&gt;    &lt;br /&gt;    public function Driver(){//constructor&lt;br /&gt;      //Make the Canvas visible.&lt;br /&gt;      setStyle("backgroundColor",0x00FFFF);&lt;br /&gt;      setStyle("backgroundAlpha",1.0);&lt;br /&gt;&lt;br /&gt;      //Embed the image files in the SWF file.&lt;br /&gt;      [Embed("snowscene.jpg")]&lt;br /&gt;      var imgA:Class;&lt;br /&gt;      &lt;br /&gt;      [Embed("space.jpg")]&lt;br /&gt;      var imgB:Class;&lt;br /&gt;      &lt;br /&gt;      [Embed("frog.jpg")]&lt;br /&gt;      var imgC:Class;&lt;br /&gt;      &lt;br /&gt;      //Load the images from the embedded image files&lt;br /&gt;      // into the Image objects.&lt;br /&gt;      imageA.load(imgA);&lt;br /&gt;      imageB.load(imgB);&lt;br /&gt;      imageC.load(imgC);&lt;br /&gt;      &lt;br /&gt;      // Set the z-axes indices such that the frog is&lt;br /&gt;      // in front, the snowscene is in the middle and the &lt;br /&gt;      // space image is at the back.&lt;br /&gt;      addChildAt(imageB,0);//set index to 0&lt;br /&gt;      addChildAt(imageA,1);//set index to 1&lt;br /&gt;      addChildAt(imageC,2);//set index to 2&lt;br /&gt;&lt;br /&gt;      //Register an event handler that will be executed&lt;br /&gt;      // whcn the canvas and its children are fully &lt;br /&gt;      // constructed.&lt;br /&gt;      this.addEventListener(FlexEvent.CREATION_COMPLETE,&lt;br /&gt;                                         completeHandler);&lt;br /&gt;    } //end constructor&lt;br /&gt;    //--------------------------------------------------//&lt;br /&gt;&lt;br /&gt;    //This handler method is executed when the Canvas and&lt;br /&gt;    // its children have been fully created.&lt;br /&gt;    private function completeHandler(&lt;br /&gt;                          event:mx.events.FlexEvent):void{&lt;br /&gt;      //Set the width and height of the canvas based on &lt;br /&gt;      // the dimensions of imageB.&lt;br /&gt;      this.width = 1.3*imageB.width;&lt;br /&gt;      this.height = 1.3*imageB.height;&lt;br /&gt;      &lt;br /&gt;      //Register event listeners to support drag and drop &lt;br /&gt;      // operations on all three images with the canvas&lt;br /&gt;      // as the drag target.&lt;br /&gt;      imageA.addEventListener(MouseEvent.MOUSE_DOWN,&lt;br /&gt;                                        mouseDownHandler);&lt;br /&gt;      imageB.addEventListener(MouseEvent.MOUSE_DOWN,&lt;br /&gt;                                        mouseDownHandler);&lt;br /&gt;      imageC.addEventListener(MouseEvent.MOUSE_DOWN,&lt;br /&gt;                                        mouseDownHandler);&lt;br /&gt;      &lt;br /&gt;      this.addEventListener(DragEvent.DRAG_DROP,&lt;br /&gt;                                             dropHandler);&lt;br /&gt;      this.addEventListener(DragEvent.DRAG_ENTER,&lt;br /&gt;                                        enterHandler);&lt;br /&gt;    } //end completeHandler&lt;br /&gt;    //--------------------------------------------------//&lt;br /&gt;    &lt;br /&gt;    // This event handler initiates the drag-and-drop \&lt;br /&gt;    // operation for the image that dispatches the &lt;br /&gt;    // mouseDown event.&lt;br /&gt;    private function mouseDownHandler(&lt;br /&gt;                                   event:MouseEvent):void{&lt;br /&gt;&lt;br /&gt;      //Save the location of the mouse within the image&lt;br /&gt;      // being dragged. This information will be used&lt;br /&gt;      // later to properly position the dropped image in&lt;br /&gt;      // the drop target.&lt;br /&gt;      this.localX = event.localX;&lt;br /&gt;      this.localY = event.localY;&lt;br /&gt;&lt;br /&gt;      //Get the drag initiator component from the event&lt;br /&gt;      // object and cast it to the correct type.&lt;br /&gt;      var dragInitiator:Image = Image(&lt;br /&gt;                                     event.currentTarget);&lt;br /&gt;&lt;br /&gt;      //Add the image being dragged to a DragSource&lt;br /&gt;      // object and define an identifier as a string.&lt;br /&gt;      var dragSource:DragSource = new DragSource();&lt;br /&gt;      dragSource.addData(dragInitiator,"imageObject");&lt;br /&gt;           &lt;br /&gt;      //Call the static doDrag method on the DragManager&lt;br /&gt;      // class to manage the overall drag and drop &lt;br /&gt;      // operation.&lt;br /&gt;      DragManager.doDrag(dragInitiator,dragSource,event);&lt;br /&gt;    }//end mouseDownHandler&lt;br /&gt;    //--------------------------------------------------//&lt;br /&gt;    &lt;br /&gt;    //This dragEnter event handler causes the canvas to&lt;br /&gt;    // be a suitable drop target.&lt;br /&gt;    private function enterHandler(event:DragEvent):void{&lt;br /&gt;      if (event.dragSource.hasFormat("imageObject")){&lt;br /&gt;          DragManager.acceptDragDrop(&lt;br /&gt;                             Canvas(event.currentTarget));&lt;br /&gt;      } //end if&lt;br /&gt;    } //end enterHandler&lt;br /&gt;    //--------------------------------------------------//&lt;br /&gt;    &lt;br /&gt;    //Execute the dragDrop event handler to drop the image&lt;br /&gt;    // in its new location. Compensate for the fact that&lt;br /&gt;    // the mouse pointer is not at the upper-left corner &lt;br /&gt;    // of the image. Also don't allow the image to be &lt;br /&gt;    // dragged off the left side of the canvas or off the &lt;br /&gt;    // top of the canvas.&lt;br /&gt;    private function dropHandler(event:DragEvent):void{&lt;br /&gt;      &lt;br /&gt;      //Compute the position of the upper-left corner of&lt;br /&gt;      // the dropped image.&lt;br /&gt;      var cornerX:Number = (Canvas(event.currentTarget).&lt;br /&gt;                                         mouseX) - localX;&lt;br /&gt;      var cornerY:Number = (Canvas(event.currentTarget).&lt;br /&gt;                                         mouseY) - localY;&lt;br /&gt;      if((cornerX &amp;gt; 0.0) &amp;amp;&amp;amp; (cornerY &amp;gt; 0.0)){&lt;br /&gt;        Image(event.dragInitiator).x = cornerX;&lt;br /&gt;        Image(event.dragInitiator).y = cornerY&lt;br /&gt;      } //end if&lt;br /&gt;    } //end dropHandler&lt;br /&gt;    //--------------------------------------------------//&lt;br /&gt;      &lt;br /&gt;  } //end class&lt;br /&gt;} //end package&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/7191641637792066842-3136053789626923714?l=java-basics.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://java-basics.blogspot.com/feeds/3136053789626923714/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://java-basics.blogspot.com/2011/01/drag-and-drop-basics.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/3136053789626923714'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7191641637792066842/posts/default/3136053789626923714'/><link rel='alternate' type='text/html' href='http://java-basics.blogspot.com/2011/01/drag-and-drop-basics.html' title='Drag and Drop Basics'/><author><name>bharadwaj</name><uri>http://www.blogger.com/profile/16734318662617451979</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7191641637792066842.post-3528722485621949733</id><published>2011-01-14T01:25:00.001-08:00</published><updated>2011-01-14T01:25:00.823-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Image Pixel Processing'/><title type='text'>Image Pixel Processing</title><content type='html'>&lt;div class="section" id="h11001" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;div class="section" id="h21001" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;div class="para" id="p1008" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I recommend that you open another copy of this document in a separate browser window and use the following links to easily find and view the figures and listings while you are reading about them.&lt;/div&gt;&lt;div class="section" id="h31000" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Figures"&gt;Figures&lt;/b&gt;&lt;/strong&gt;&lt;/h4&gt;&lt;div class="list" id="ul1006" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1019" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Figure_1" id="a1022" style="color: #336699; font-weight: bold;"&gt;Figure 1&amp;nbsp;&lt;/a&gt;. Screen output for both programs.&lt;/li&gt;&lt;li class="item" id="li1020" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Figure_2" id="a1023" style="color: #336699; font-weight: bold;"&gt;Figure 2&amp;nbsp;&lt;/a&gt;. Program file structure for the program named Bitmap05.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h31001" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listings"&gt;Listings&lt;/b&gt;&lt;/strong&gt;&lt;/h4&gt;&lt;div class="list" id="ul1007" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1021" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_1" id="a1024" style="color: #336699; font-weight: bold;"&gt;Listing 1&amp;nbsp;&lt;/a&gt;. MXML code for the program named Bitmap05.&lt;/li&gt;&lt;li class="item" id="li1022" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_2" id="a1025" style="color: #336699; font-weight: bold;"&gt;Listing 2&amp;nbsp;&lt;/a&gt;. Beginning of the ActionScript Driver class.&lt;/li&gt;&lt;li class="item" id="li1023" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_3" id="a1026" style="color: #336699; font-weight: bold;"&gt;Listing 3&amp;nbsp;&lt;/a&gt;. Start the process of loading the image file.&lt;/li&gt;&lt;li class="item" id="li1024" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_4" id="a1027" style="color: #336699; font-weight: bold;"&gt;Listing 4&amp;nbsp;&lt;/a&gt;. Beginning of the complete event handler.&lt;/li&gt;&lt;li class="item" id="li1025" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_5" id="a1028" style="color: #336699; font-weight: bold;"&gt;Listing 5&amp;nbsp;&lt;/a&gt;. Encapsulate the Bitmap in an Image object.&lt;/li&gt;&lt;li class="item" id="li1026" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_6" id="a1029" style="color: #336699; font-weight: bold;"&gt;Listing 6&amp;nbsp;&lt;/a&gt;. Clone the original Bitmap to create a duplicate Bitmap.&lt;/li&gt;&lt;li class="item" id="li1027" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_7" id="a1030" style="color: #336699; font-weight: bold;"&gt;Listing 7&amp;nbsp;&lt;/a&gt;. Modify the duplicate Bitmap.&lt;/li&gt;&lt;li class="item" id="li1028" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_8" id="a1031" style="color: #336699; font-weight: bold;"&gt;Listing 8&amp;nbsp;&lt;/a&gt;. Beginning of the modify method.&lt;/li&gt;&lt;li class="item" id="li1029" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_9" id="a1032" style="color: #336699; font-weight: bold;"&gt;Listing 9&amp;nbsp;&lt;/a&gt;. Process pixels using the getPixels and setPixels methods.&lt;/li&gt;&lt;li class="item" id="li1030" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_10" id="a1033" style="color: #336699; font-weight: bold;"&gt;Listing 10&amp;nbsp;&lt;/a&gt;. Modify the pixels in the rectangular region.&lt;/li&gt;&lt;li class="item" id="li1031" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_11" id="a1034" style="color: #336699; font-weight: bold;"&gt;Listing 11&amp;nbsp;&lt;/a&gt;. Put the modified pixel data back into the same rectangular region.&lt;/li&gt;&lt;li class="item" id="li1032" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_12" id="a1035" style="color: #336699; font-weight: bold;"&gt;Listing 12&amp;nbsp;&lt;/a&gt;. Process pixels using the setPixel32 method.&lt;/li&gt;&lt;li class="item" id="li1033" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_13" id="a1036" style="color: #336699; font-weight: bold;"&gt;Listing 13&amp;nbsp;&lt;/a&gt;. Put borders on the top and bottom edges.&lt;/li&gt;&lt;li class="item" id="li1034" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_14" id="a1037" style="color: #336699; font-weight: bold;"&gt;Listing 14&amp;nbsp;&lt;/a&gt;. Return to the complete event handler.&lt;/li&gt;&lt;li class="item" id="li1035" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_15" id="a1038" style="color: #336699; font-weight: bold;"&gt;Listing 15&amp;nbsp;&lt;/a&gt;. Beginning of the invert method.&lt;/li&gt;&lt;li class="item" id="li1036" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_16" id="a1039" style="color: #336699; font-weight: bold;"&gt;Listing 16&amp;nbsp;&lt;/a&gt;. Apply the inversion algorithm.&lt;/li&gt;&lt;li class="item" id="li1037" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_17" id="a1040" style="color: #336699; font-weight: bold;"&gt;Listing 17&amp;nbsp;&lt;/a&gt;. Put the modified pixel data back into the BitmapData object.&lt;/li&gt;&lt;li class="item" id="li1038" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_18" id="a1041" style="color: #336699; font-weight: bold;"&gt;Listing 18&amp;nbsp;&lt;/a&gt;. Code that is different in the program named Bitmap06.&lt;/li&gt;&lt;li class="item" id="li1039" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_19" id="a1042" style="color: #336699; font-weight: bold;"&gt;Listing 19&amp;nbsp;&lt;/a&gt;. MXML code for the program named Bitmap05.&lt;/li&gt;&lt;li class="item" id="li1040" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_20" id="a1043" style="color: #336699; font-weight: bold;"&gt;Listing 20&amp;nbsp;&lt;/a&gt;. ActionScript code for the program named Bitmap05.&lt;/li&gt;&lt;li class="item" id="li1041" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Listing_21" id="a1044" style="color: #336699; font-weight: bold;"&gt;Listing 21&amp;nbsp;&lt;/a&gt;. ActionScript code for the program named Bitmap06.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h21002" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Supplementary_material"&gt;Supplemental material&lt;/b&gt;&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="p1009" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I recommend that you also study the other lessons in my extensive collection of online programming tutorials. You will find a consolidated index at&amp;nbsp;&lt;a class="link" href="http://www.dickbaldwin.com/toc.htm" id="a1045" style="color: #336699;"&gt;www.DickBaldwin.com&amp;nbsp;&lt;/a&gt;.&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11002" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="GeneralBackgroundInformation"&gt;General background information&lt;/b&gt;&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1010" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In an earlier lesson titled&amp;nbsp;&lt;b class="emphasis" id="strong1004"&gt;Bitmap Basics&amp;nbsp;&lt;/b&gt;, I explained the differences between Flex projects and ActionScript projects. I also introduced you to the classes named&amp;nbsp;&lt;b class="emphasis" id="strong1005"&gt;Bitmap&amp;nbsp;&lt;/b&gt;and&amp;nbsp;&lt;b class="emphasis" id="strong1006"&gt;BitmapData&amp;nbsp;&lt;/b&gt;. Now it's time to put that knowledge to work. In this lesson, I will show you how to:&lt;/div&gt;&lt;div class="list" id="ul1008" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1042" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Load the contents of an image file into a&amp;nbsp;&lt;b class="emphasis" id="strong1007"&gt;BitmapData&amp;nbsp;&lt;/b&gt;object encapsulated in a&amp;nbsp;&lt;b class="emphasis" id="strong1008"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object.&lt;/li&gt;&lt;li class="item" id="li1043" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Use the&amp;nbsp;&lt;b class="emphasis" id="strong1009"&gt;setPixel32&amp;nbsp;&lt;/b&gt;,&amp;nbsp;&lt;b class="emphasis" id="strong1010"&gt;getPixels&amp;nbsp;&lt;/b&gt;, and&amp;nbsp;&lt;b class="emphasis" id="strong1011"&gt;setPixels&amp;nbsp;&lt;/b&gt;methods to access and modify the color content of the individual pixels that make up an image.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="p1011" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Before getting into that, however, it will be useful to explain how image information is stored in files and in the computer's memory.&lt;/div&gt;&lt;div class="para" id="p1012" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1012"&gt;Vector graphics versus bitmap graphics&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1013" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Graphics programming typically involves two main types of data: bitmaps and vector graphics. This lesson deals with bitmap data only. I will deal with vector graphics in a future lesson.&lt;/div&gt;&lt;div class="para" id="p1014" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1013"&gt;A rectangular array of pixels&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1015" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When you take a picture with your digital camera, the scene is converted into a rectangular array containing millions of uniformly spaced colored dots. Those dots or picture elements&amp;nbsp;&lt;i class="emphasis" id="em1002"&gt;(pixels)&lt;/i&gt;are stored on the memory card in your camera until you download them into your computer.&lt;/div&gt;&lt;div class="para" id="p1016" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1014"&gt;Width, height, and color depth&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1017" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;An image that is stored in this way is defined by the width and height of the array of pixels along with the number of bits that are used to define the color.&lt;/div&gt;&lt;div class="para" id="p1018" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Up to a point, the more pixels that the camera produces to represent a given field of view, the better will be the image. Similarly, the more bits that are used to store the color, the better will be the overall quality of the image, particularly in terms of subtle shades of color.&lt;/div&gt;&lt;div class="para" id="p1019" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1015"&gt;The resolution&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1020" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The number of pixels per unit area is commonly referred to as resolution. For example, the display monitor that I am currently using displays an array of 1280 x1024 pixels in a rectangular area with a diagonal measurement of 19 inches. (This is not a particularly high resolution monitor.)&lt;/div&gt;&lt;div class="para" id="p1021" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1016"&gt;The color depth&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1022" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The number of bits used to represent the color of a pixel is commonly referred to as the color depth. Most modern computers routinely use a color depth of 32 bits. Note, however, that some file formats used for the storage and transmission of bitmap graphics data use fewer than 32 bits for the representation of each pixel in an image.&lt;/div&gt;&lt;div class="para" id="p1023" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1017"&gt;The RGB or ARGB color model&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1024" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;ActionScript supports a computer color model commonly known as the RGB model or the ARGB model. With this model, the color of each pixel is represented by three numeric color values and an optional transparency value&amp;nbsp;&lt;i class="emphasis" id="em1003"&gt;(alpha)&amp;nbsp;&lt;/i&gt;.&lt;/div&gt;&lt;div class="para" id="p1025" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Each of the three color values represents the contribution or strength of a primary color:&amp;nbsp;&lt;i class="emphasis" id="em1004"&gt;red, green, and blue.&amp;nbsp;&lt;/i&gt;The final color of the pixel is a mixture of the primary colors. This is similar to a kindergarten student mixing red, green, and blue clay to produce a color that is different from red, green or blue.&amp;nbsp;&lt;i class="emphasis" id="em1005"&gt;(I don't have a clay analogy for transparency, however.)&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1026" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1018"&gt;The effect of the transparency value&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1027" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In some cases, the pixel also contains another value referred to as the&amp;nbsp;&lt;i class="emphasis" id="em1006"&gt;alpha&amp;nbsp;&lt;/i&gt;value&amp;nbsp;&lt;i class="emphasis" id="em1007"&gt;(ARGB)&amp;nbsp;&lt;/i&gt;that represents the transparency of the pixel.&lt;/div&gt;&lt;div class="para" id="p1028" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Transparency comes into play when you draw a new image over an existing image. If the alpha value for a pixel is zero, there is no change in the color of the existing pixel because the new pixel is totally transparent.&amp;nbsp;&lt;i class="emphasis" id="em1008"&gt;(Although the effect is commonly referred to as transparency, the numeric value is actually proportional to opacity, which is the inverse of transparency.)&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1029" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1019"&gt;Total opacity&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1030" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;If the alpha value indicates total opacity&amp;nbsp;&lt;b class="emphasis" id="L2629"&gt;&lt;i class="emphasis" id="em1009"&gt;(often represented as either 1.0 or 255)&amp;nbsp;&lt;/i&gt;&lt;/b&gt;, the color of the existing pixel is completely replaced by the color of the new pixel.&amp;nbsp;&lt;i class="emphasis" id="em1010"&gt;(I will explain the difference between 1.0 and 255 later.)&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1031" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1020"&gt;Partial opacity&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1032" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;If the alpha value falls between 0 and 1.0&amp;nbsp;&lt;i class="emphasis" id="em1011"&gt;(0 and 255)&amp;nbsp;&lt;/i&gt;, the colors of the existing pixel and the new pixel are combined to produce a new blended color. The result is as if you are viewing the original scene through colored glass.&lt;/div&gt;&lt;div class="para" id="p1033" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1021"&gt;An unsigned 32-bit chunk of memory&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1034" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Typically, a pixel is represented in the computer by an unsigned 32-bit chunk of memory. Each of the three primary colors and the alpha value are represented by an eight-bit unsigned byte. The bytes are concatenated to form the 32-bit chunk of memory.&lt;/div&gt;&lt;div class="para" id="p1035" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1022"&gt;256 levels&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1036" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This results in 256 levels of intensity for each of the primary colors along with 256 levels of transparency for the alpha byte. For example, if the red, green, and alpha bytes are equal to 255 and the blue byte is zero, the pixel will be displayed as bright yellow on a typical computer screen.&lt;/div&gt;&lt;div class="para" id="p1037" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1023"&gt;Bitmap image file formats&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1038" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Different file formats are commonly used to store and transmit image data. It is usually desirable to reduce the size of the file required to store a given image while maintaining the quality of the image. This often results in a tradeoff between file size and image quality.&lt;/div&gt;&lt;div class="para" id="p1039" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Different formats use different compression algorithms to reduce the size of the file. The bitmap image formats supported by Adobe Flash Player and Adobe Air are GIF, JPG, and PNG.&lt;/div&gt;&lt;div class="para" id="p1040" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1024"&gt;The GIF format&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1041" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The Graphics Interchange Format&amp;nbsp;&lt;i class="emphasis" id="em1012"&gt;(GIF)&amp;nbsp;&lt;/i&gt;is a format that is often used to store low quality images in very small files. The format can store a maximum of 256 different colors and can designate one of those colors to represent a fully transparent pixel. By comparison, the typical ARGB format can represent more than sixteen million colors with 256 levels of transparency for each pixel.&lt;/div&gt;&lt;div class="para" id="p1042" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The GIF format would not be very satisfactory for images produced by your digital camera, but it is fine for many purposes such as screen icons where high color quality is not an important consideration.&lt;/div&gt;&lt;div class="para" id="p1043" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1025"&gt;The JPEG format&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1044" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This format, which is often written as JPG, was developed by the Joint Photographic Experts Group&amp;nbsp;&lt;i class="emphasis" id="em1013"&gt;(JPEG)&amp;nbsp;&lt;/i&gt;. This image format uses a lossy compression algorithm to allow 24-bit color depth with a small file size.&lt;/div&gt;&lt;div class="para" id="p1045" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Lossy compression means that what comes out of the compressed file is not identical to what went in. The loss in picture quality is often acceptable, however, given that the format allows for different degrees of lossiness which is inversely related to the size of the compressed file. All of the digital cameras that I have owned produce JPEG files as the standard output and some of them allow the user to select the degree of compression and hence the degree of lossiness.&lt;/div&gt;&lt;div class="para" id="p1046" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The JPEG format does not support alpha transparency. Therefore, it is not suitable as a file format for transmitting images with alpha data between computers.&lt;/div&gt;&lt;div class="para" id="p1047" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1026"&gt;The PNG format&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1048" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Apparently there are some patent issues with the GIF format. The Portable Network Graphics&amp;nbsp;&lt;i class="emphasis" id="em1014"&gt;(PNG)&amp;nbsp;&lt;/i&gt;format was produced as an open-source alternative to the GIF file format.&lt;/div&gt;&lt;div class="para" id="p1049" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The PNG format supports at least sixteen million colors and uses lossless compression. The PNG format also supports alpha transparency allowing for up to 256 levels of transparency in a compressed format.&lt;/div&gt;&lt;div class="para" id="p1050" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1027"&gt;The BitmapData class&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1051" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;b class="emphasis" id="strong1028"&gt;BitmapData&amp;nbsp;&lt;/b&gt;class in ActionScript 3 supports a 32-bit ARGB color model with more than sixteen million colors and 256 levels of alpha transparency per pixel.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11003" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Preview"&gt;Preview&lt;/b&gt;&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1052" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will explain two different programs in this lesson. One is named&amp;nbsp;&lt;b class="emphasis" id="strong1029"&gt;Bitmap05&amp;nbsp;&lt;/b&gt;and the other is named&amp;nbsp;&lt;b class="emphasis" id="strong1030"&gt;Bitmap06&amp;nbsp;&lt;/b&gt;. Both programs produce the same output, which is shown in Figure 1.&lt;/div&gt;&lt;div class="figure" id="figure1000" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 1:&amp;nbsp;&lt;/strong&gt;Screen output for both programs.&lt;/caption&gt;&lt;thead&gt;&lt;tr&gt;&lt;th class="figure-name" style="border-collapse: collapse; padding-bottom: 0.3em; padding-left: 0.3em; padding-right: 0.3em; padding-top: 0.3em; text-align: center;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Figure_1"&gt;&lt;/b&gt;Screen output for both programs.&lt;/strong&gt;&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="media1000"&gt;&lt;img alt="Missing image" height="925" id="img1000" src="http://cnx.org/content/m34461/latest/as0132a.jpg" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="316" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="p1053" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1031"&gt;Program file structure&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1054" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Figure 2 shows the program file structure taken from the Flex Builder 3 Navigator panel for the program named&amp;nbsp;&lt;b class="emphasis" id="strong1032"&gt;Bitmap05&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="figure" id="figure1001" style="margin-bottom: 1.5em; margin-left: auto; margin-right: auto; margin-top: 1.5em;"&gt;&lt;table align="center" border="0" cellpadding="0" cellspacing="0"&gt;&lt;caption align="bottom" class="figure-caption" style="font-size: 0.9em; font-weight: normal; line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;strong class="cnx_label"&gt;Figure 2:&amp;nbsp;&lt;/strong&gt;Program file structure for the program named Bitmap05.&lt;/caption&gt;&lt;thead&gt;&lt;tr&gt;&lt;th class="figure-name" style="border-collapse: collapse; padding-bottom: 0.3em; padding-left: 0.3em; padding-right: 0.3em; padding-top: 0.3em; text-align: center;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Figure_2"&gt;&lt;/b&gt;Program file structure for the program named Bitmap05.&lt;/strong&gt;&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="inner-figure" style="border-bottom-color: rgb(153, 153, 153); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(153, 153, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(153, 153, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(153, 153, 153); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.75em; padding-left: 0px; padding-right: 0px; padding-top: 0.5em; text-align: center;"&gt;&lt;span class="media" id="media1001"&gt;&lt;img alt="Missing image" height="229" id="img1001" src="http://cnx.org/content/m34461/latest/as0132b.jpg" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px;" width="193" /&gt;&lt;/span&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="p1055" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The program file structure for&amp;nbsp;&lt;b class="emphasis" id="strong1033"&gt;Bitmap06&amp;nbsp;&lt;/b&gt;is the same except for the name of MXML file.&lt;/div&gt;&lt;div class="para" id="p1056" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will use the programs named&amp;nbsp;&lt;b class="emphasis" id="strong1034"&gt;Bitmap05&amp;nbsp;&lt;/b&gt;and&amp;nbsp;&lt;b class="emphasis" id="strong1035"&gt;Bitmap06&amp;nbsp;&lt;/b&gt;to explain a variety of topics.&lt;/div&gt;&lt;div class="para" id="p1057" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1036"&gt;Skeleton code&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1058" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;First, I will provide skeleton code for creating a&amp;nbsp;&lt;b class="emphasis" id="strong1037"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object from an image file. You will learn how to use the skeleton code to create and display a bitmap from an image file as shown by the top image in Figure 1.&lt;/div&gt;&lt;div class="para" id="p1059" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1038"&gt;Extract the BitmapData object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1060" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will show you how to extract the&amp;nbsp;&lt;b class="emphasis" id="strong1039"&gt;BitmapData&amp;nbsp;&lt;/b&gt;object from the&amp;nbsp;&lt;b class="emphasis" id="strong1040"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object so that you can modify the pixels in the image. Once you are able to extract the&amp;nbsp;&lt;b class="emphasis" id="strong1041"&gt;BitmapData&amp;nbsp;&lt;/b&gt;object, you will have the bitmap data exposed to the point that you can implement a variety of image processing algorithms such as the following:&lt;/div&gt;&lt;div class="list" id="ul1009" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1044" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Smoothing&lt;/li&gt;&lt;li class="item" id="li1045" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Sharpening&lt;/li&gt;&lt;li class="item" id="li1046" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Edge detection&lt;/li&gt;&lt;li class="item" id="li1047" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Color filtering&lt;/li&gt;&lt;li class="item" id="li1048" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Color inversion&lt;/li&gt;&lt;li class="item" id="li1049" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Redeye correction&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="p1061" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1015"&gt;(For more information on how to implement image processing algorithms in general, see the tutorial lessons beginning with Lesson 340 in the section titled&amp;nbsp;&lt;b class="emphasis" id="strong1042"&gt;Multimedia Programming with Java&amp;nbsp;&lt;/b&gt;on my&amp;nbsp;&lt;a class="link" href="http://www.dickbaldwin.com/tocadv.htm" id="a1046" style="color: #336699;"&gt;web site&amp;nbsp;&lt;/a&gt;.)&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1062" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1043"&gt;Using the getPixels, setPixels, and setPixel32 methods&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1063" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will explain how to use the&amp;nbsp;&lt;b class="emphasis" id="strong1044"&gt;getPixels&amp;nbsp;&lt;/b&gt;,&amp;nbsp;&lt;b class="emphasis" id="strong1045"&gt;setPixels&amp;nbsp;&lt;/b&gt;, and&amp;nbsp;&lt;b class="emphasis" id="strong1046"&gt;setPixel32&amp;nbsp;&lt;/b&gt;methods for modifying the pixels in a bitmap as shown by the middle image in Figure 1. If you compare the middle image with the top image, you will see that two colored bars were added near the upper-left corner. In addition, colored borders were added to the middle image.&lt;/div&gt;&lt;div class="para" id="p1064" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1047"&gt;Color inversion&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1065" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Finally, I will explain how to implement a color inversion algorithm as shown by the bottom image in Figure 1. If you compare the bottom image with the middle image, you will see that the colors of all of the pixels in the top half of the bottom image have been changed. The colors of the pixels were changed using a particular algorithm known widely as a color inversion algorithm.&lt;/div&gt;&lt;div class="para" id="p1066" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The color inversion algorithm produces an output that is very similar to an old fashioned color film negative. The algorithm is economical to implement and totally reversible. Therefore, it is used by several major software products to highlight an image and show that the image has been selected for processing.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h11004" style="font-family: tahoma, verdana, arial, helvetica, sans-serif; font-size: 10px; line-height: 18px; margin-bottom: 2em; margin-left: 0px; margin-right: 0px; margin-top: 2em;"&gt;&lt;h2 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 0px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.5em; font-weight: bold; letter-spacing: -1px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="DiscussionandSamplePrograms"&gt;&lt;/b&gt;Discussion and sample code&lt;/strong&gt;&lt;/h2&gt;&lt;div class="para" id="p1067" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;As mentioned earlier, I will explain two different programs in this lesson. One is named&amp;nbsp;&lt;b class="emphasis" id="strong1048"&gt;Bitmap05&amp;nbsp;&lt;/b&gt;and the other is named&amp;nbsp;&lt;b class="emphasis" id="strong1049"&gt;Bitmap06&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="section" id="h21003" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h3 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="program"&gt;The program named Bitmap05&lt;/b&gt;&lt;/strong&gt;&lt;/h3&gt;&lt;div class="para" id="p1068" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1050"&gt;Will explain in fragments&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1069" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will explain the code for both programs in fragments. Both programs use the same MXML code but use different ActionScript code. Complete listings of the MXML file and the ActionScript files are provided in Listing 19 through Listing 21 near the end of the lesson.&lt;/div&gt;&lt;div class="section" id="h31002" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="MXML_code_for_the_program_named_Bitmap05"&gt;MXML code for the program named Bitmap05&lt;/b&gt;&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="p1070" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The MXML code for this program&amp;nbsp;&lt;i class="emphasis" id="em1016"&gt;(and the program named&amp;nbsp;&lt;/i&gt;&lt;b class="emphasis" id="strong1051"&gt;&lt;i class="emphasis" id="em1017"&gt;Bitmap06&amp;nbsp;&lt;/i&gt;&lt;/b&gt;&lt;i class="emphasis" id="em1018"&gt;as well)&amp;nbsp;&lt;/i&gt;is shown in Listing 1 and also in Listing 19 for your convenience.&lt;/div&gt;&lt;div class="example" id="listing1000" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 1:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_1"&gt;&lt;/b&gt;MXML code for the program named Bitmap05.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1000" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&lt;br /&gt;&amp;lt;!--&lt;br /&gt;This program illustrates loading an image and&lt;br /&gt;modifying the pixels in the image.&lt;br /&gt;--&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;mx:Application &lt;br /&gt;  xmlns:mx="http://www.adobe.com/2006/mxml" &lt;br /&gt;  xmlns:cc="CustomClasses.*"&amp;gt;&lt;br /&gt;  &lt;br /&gt;  &amp;lt;cc:Driver/&amp;gt;&lt;br /&gt;&lt;br /&gt;&amp;lt;/mx:Application&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1071" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Both programs are written almost entirely in ActionScript. As you can see, the MXML code instantiates a single object of the&amp;nbsp;&lt;b class="emphasis" id="strong1052"&gt;Driver&amp;nbsp;&lt;/b&gt;class. Beyond that point, the behavior of both programs is controlled entirely by ActionScript code in the&amp;nbsp;&lt;b class="emphasis" id="strong1053"&gt;Driver&amp;nbsp;&lt;/b&gt;class.&lt;/div&gt;&lt;/div&gt;&lt;div class="section" id="h31003" style="margin-bottom: 1.75em; margin-left: 3em; margin-right: 0px; margin-top: 1.75em;"&gt;&lt;h4 class="section-header" style="border-bottom-color: rgb(51, 102, 153); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(51, 102, 153); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 102, 153); border-right-style: solid; border-right-width: 0px; border-top-color: rgb(51, 102, 153); border-top-style: solid; border-top-width: 0px; color: #336699; font-size: 1.05em; font-weight: bold; letter-spacing: 0px; line-height: 1.5em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0.1em; padding-left: 0.4em; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="ActionScript_code_for_the_program_named_Birtmap05"&gt;ActionScript code for the program named Birtmap05&lt;/b&gt;&lt;/strong&gt;&lt;/h4&gt;&lt;div class="para" id="p1072" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1054"&gt;&lt;b class="emphasis" id="security"&gt;A security issue&lt;/b&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1073" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Let me begin by saying that I make no claims of expertise regarding security issues and the Flash Player.&lt;/div&gt;&lt;div class="para" id="p1074" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1055"&gt;No embedded image&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1075" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I did not embed the image file shown in Figure 1 in the SWF file for the program named&amp;nbsp;&lt;b class="emphasis" id="strong1056"&gt;Bitmap05&amp;nbsp;&lt;/b&gt;. Instead, I included it as a separate file in the&amp;nbsp;&lt;i class="emphasis" id="em1019"&gt;Release Build&amp;nbsp;&lt;/i&gt;of the program. As a result, it was necessary for me to change one of the XML elements in the following configuration file to make it possible for you to download and&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#Click" id="a1047" style="color: #336699; font-weight: bold;"&gt;run&amp;nbsp;&lt;/a&gt;the online version of the program.&lt;/div&gt;&lt;div class="para" id="p1076" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1057"&gt;C:\Program Files\Adobe\Flex Builder 3\sdks\3.2.0\frameworks\flex-config.xml&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1077" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1020"&gt;(Note that the configuration file may be in a different location on your computer.)&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1078" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1058"&gt;The required change&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1079" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The required change was to set the value in the following element to false instead of true:&lt;/div&gt;&lt;div class="table" id="table1000" style="margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 1.5em; text-align: center; width: 986px;"&gt;&lt;table align="center" cellpadding="0" cellspacing="0" style="border-bottom-color: rgb(102, 102, 102) !important; border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-color: initial; border-left-color: rgb(102, 102, 102) !important; border-left-style: solid; border-left-width: 1px; border-right-color: rgb(102, 102, 102) !important; border-right-style: solid; border-right-width: 1px; border-top-color: rgb(102, 102, 102) !important; border-top-style: solid; border-top-width: 1px; width: 985px;" summary="This is a table."&gt;&lt;caption align="bottom" class="table-text" style="line-height: normal; padding-top: 0.3em; text-align: left;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;TABLE 1&lt;/span&gt;&lt;/caption&gt;&lt;tbody id="tbody1000" valign="top"&gt;&lt;tr id="tr1000"&gt;&lt;td id="td1000" style="border-bottom-color: initial !important; border-bottom-style: initial !important; border-bottom-width: 0px !important; border-collapse: collapse; border-left-color: initial !important; border-left-style: initial !important; border-left-width: 0px !important; border-right-color: initial !important; border-right-style: initial !important; border-right-width: 0px !important; border-top-color: initial !important; border-top-style: initial !important; border-top-width: 0px !important; padding-bottom: 0.3em !important; padding-left: 0.3em !important; padding-right: 0.3em !important; padding-top: 0.3em !important; text-align: left !important;"&gt;&lt;div class="code" id="pre1001" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;&amp;lt;use-network&amp;gt;false&amp;lt;/use-network&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="para" id="p1080" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1059"&gt;Why am I telling you this?&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1081" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The ActionScript documentation seems to take for granted that you must modify the configuration file to handle the security issue. However, it took a very long time and a lot of searching for me to discover that in order to select certain compiler options, it is necessary to physically modify the configuration file shown above.&lt;/div&gt;&lt;div class="para" id="p1082" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I knew generally the kind of change that was required, but I was expecting to find an option in the Flex Builder 3 IDE to allow me to change the compiler options on a project by project basis. If that capability exists in the IDE, I was unable to find it.&amp;nbsp;&lt;i class="emphasis" id="em1021"&gt;(Of course, once you know about the requirement, you can Google "flex-config.xml" and find hundreds of references to the topic.)&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1083" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I am telling you this in the hope that this information will save you countless hours of searching through the documentation to discover why you get a runtime error when you replicate this project and then try to download and run it in the Flash Player plugin.&lt;/div&gt;&lt;div class="para" id="p1084" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1060"&gt;Beginning of the ActionScript Driver class&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1085" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The MXML code shown in Listing 1 instantiates an object of the&amp;nbsp;&lt;b class="emphasis" id="strong1061"&gt;Driver&amp;nbsp;&lt;/b&gt;class. The ActionScript&amp;nbsp;&lt;b class="emphasis" id="strong1062"&gt;Driver&amp;nbsp;&lt;/b&gt;class begins in Listing 2.&lt;/div&gt;&lt;div class="example" id="listing1001" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 2:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_2"&gt;&lt;/b&gt;Beginning of the ActionScript Driver class.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1002" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;package CustomClasses{&lt;br /&gt;  import flash.display.Bitmap;&lt;br /&gt;  import flash.display.BitmapData;&lt;br /&gt;  import flash.display.Loader;&lt;br /&gt;  import flash.events.*;&lt;br /&gt;  import flash.geom.Rectangle;&lt;br /&gt;  import flash.net.URLRequest;&lt;br /&gt;  import flash.utils.ByteArray;&lt;br /&gt;  &lt;br /&gt;  import mx.containers.VBox;&lt;br /&gt;  import mx.controls.Image;&lt;br /&gt;  import flash.system.Security;&lt;br /&gt;  //====================================================//&lt;br /&gt;  &lt;br /&gt;  public class Driver extends VBox {&lt;br /&gt;    private var url:String = "snowscene.jpg";//image file&lt;br /&gt;    &lt;br /&gt;    public function Driver(){//constructor&lt;br /&gt;      //Make the VBox visible.&lt;br /&gt;      setStyle("backgroundColor",0xFFFF00);&lt;br /&gt;      setStyle("backgroundAlpha",1.0);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1086" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1063"&gt;Establish the name and path of the image file&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1087" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The class definition in Listing 2 begins by declaring and populating an instance variable named&amp;nbsp;&lt;b class="emphasis" id="strong1064"&gt;url&amp;nbsp;&lt;/b&gt;with the name of the image file shown in Figure 2. As you can see in Figure 2, this file was located in the same folder as the MXML file. Therefore, no path information was required to specify the location of the image file.&lt;/div&gt;&lt;div class="para" id="p1088" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1065"&gt;The constructor&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1089" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The constructor for the class also begins in Listing 2. This class extends the&amp;nbsp;&lt;b class="emphasis" id="strong1066"&gt;VBox&amp;nbsp;&lt;/b&gt;class. The code in Listing 2 causes the background color of the&amp;nbsp;&lt;b class="emphasis" id="strong1067"&gt;VBox&amp;nbsp;&lt;/b&gt;object to be yellow and also causes the yellow background to be completely opaque. You can see the opaque yellow background of the&amp;nbsp;&lt;b class="emphasis" id="strong1068"&gt;VBox&amp;nbsp;&lt;/b&gt;object in Figure 1.&lt;/div&gt;&lt;div class="para" id="p1090" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1069"&gt;Opacity is often represented as either 1.0 or 255&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1091" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Remember that I told you&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#L2629" id="a1048" style="color: #336699; font-weight: bold;"&gt;earlier&amp;nbsp;&lt;/a&gt;that the opacity value is&amp;nbsp;&lt;i class="emphasis" id="em1022"&gt;"often represented as either 1.0 or 255."&amp;nbsp;&lt;/i&gt;Usually when you set the alpha value as a property of a Flex component, you must specify a value ranging from 0.0 to 1.0 with a value of 1.0 being completely opaque. On the other hand, when you are dealing with the actual alpha value in bitmap data, you must specify a value ranging from 0 to 255 with a value of 255 being completely opaque.&lt;/div&gt;&lt;div class="para" id="p1092" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1070"&gt;Start the process of loading the image file&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1093" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 3 starts the process of loading the image file. As I mentioned earlier, this program does not embed the image file in the SWF file.&amp;nbsp;&lt;i class="emphasis" id="em1023"&gt;(The program named&amp;nbsp;&lt;b class="emphasis" id="strong1071"&gt;Bitmap06&amp;nbsp;&lt;/b&gt;, which I will explain later, does embed the image file in the SWF file.)&amp;nbsp;&lt;/i&gt;Instead, the image file for this program ends up as a separate file on the server that must be downloaded in addition to the SWF file.&amp;nbsp;&lt;i class="emphasis" id="em1024"&gt;(The ActionScript literature contains numerous discussions regarding the pros and cons of embedding versus not embedding resource files.)&lt;/i&gt;&lt;/div&gt;&lt;div class="example" id="listing1002" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 3:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_3"&gt;&lt;/b&gt;Start the process of loading the image file.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1003" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      var loader:Loader = new Loader();&lt;br /&gt;&lt;br /&gt;      //Register event listeners on the load process&lt;br /&gt;      loader.contentLoaderInfo.addEventListener(&lt;br /&gt;                          Event.COMPLETE,completeHandler);&lt;br /&gt;      loader.contentLoaderInfo.addEventListener(&lt;br /&gt;                    IOErrorEvent.IO_ERROR,ioErrorHandler);&lt;br /&gt;    &lt;br /&gt;      var request:URLRequest = new URLRequest(url);&lt;br /&gt;      loader.load(request);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1094" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1072"&gt;Straightforward code&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1095" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The code in Listing 3 is fairly straightforward. You should be able to understand it if you analyze it using the ActionScript documentation.&lt;/div&gt;&lt;div class="para" id="p1096" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1073"&gt;The Event.COMPLETE event handler&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1097" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The main thing that I want to emphasize from Listing 3 is the registration of the&amp;nbsp;&lt;b class="emphasis" id="strong1074"&gt;Event.COMPLETE&amp;nbsp;&lt;/b&gt;event handler. Note that this event handler is registered on the&lt;b class="emphasis" id="strong1075"&gt;contentLoaderInfo&amp;nbsp;&lt;/b&gt;property of the&amp;nbsp;&lt;b class="emphasis" id="strong1076"&gt;Loader&amp;nbsp;&lt;/b&gt;object and not on the&amp;nbsp;&lt;b class="emphasis" id="strong1077"&gt;Loader&amp;nbsp;&lt;/b&gt;object itself. The documentation has this to say about this property:&lt;/div&gt;&lt;div class="para" id="p1098" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1025"&gt;"Returns a LoaderInfo object corresponding to the object being loaded. LoaderInfo objects are shared between the Loader object and the loaded content object. The LoaderInfo object supplies loading progress information and statistics about the loaded file.&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1099" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1026"&gt;Events related to the load are dispatched by the LoaderInfo object referenced by the contentLoaderInfo property of the Loader object. The contentLoaderInfo property is set to a valid LoaderInfo object, even before the content is loaded, so that you can add event listeners to the object prior to the load."&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1100" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1078"&gt;The Event.COMPLETE event&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1101" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The documentation has this to say about the&amp;nbsp;&lt;b class="emphasis" id="strong1079"&gt;Event.COMPLETE&amp;nbsp;&lt;/b&gt;event:&lt;/div&gt;&lt;div class="para" id="p1102" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1027"&gt;"Dispatched when data has loaded successfully. In other words, it is dispatched when all the content has been downloaded and the loading has finished. The complete event is always dispatched after the init event. The init event is dispatched when the object is ready to access, though the content may still be downloading."&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1103" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1080"&gt;Beginning of the complete event handler&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1104" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;b class="emphasis" id="strong1081"&gt;complete&amp;nbsp;&lt;/b&gt;event handler that is registered in Listing 3 begins in Listing 4. This handler is executed when the load process is complete and the image data is available.&lt;/div&gt;&lt;div class="example" id="listing1003" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 4:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_4"&gt;&lt;/b&gt;Beginning of the complete event handler.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1004" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;    private function completeHandler(event:Event):void{&lt;br /&gt;&lt;br /&gt;      //Get, cast, and save a reference to a Bitmap object&lt;br /&gt;      // containing the content of the image file.&lt;br /&gt;      var original:Bitmap = Bitmap(&lt;br /&gt;                             event.target.loader.content);&lt;br /&gt;      &lt;br /&gt;      //Set the width and height of the VBox object based&lt;br /&gt;      // on the size of the original bitmap.&lt;br /&gt;      this.width = original.width + 10;&lt;br /&gt;      this.height = 3*original.height + 12;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1105" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1082"&gt;Get a reference to the Bitmap object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1106" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The handler begins by using the incoming reference to the&amp;nbsp;&lt;b class="emphasis" id="strong1083"&gt;Event&amp;nbsp;&lt;/b&gt;object to execute a complex statement that ends up with a reference to the&amp;nbsp;&lt;b class="emphasis" id="strong1084"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object. However, that reference is received as type&amp;nbsp;&lt;b class="emphasis" id="strong1085"&gt;DisplayObject&amp;nbsp;&lt;/b&gt;and must be cast to type&amp;nbsp;&lt;b class="emphasis" id="strong1086"&gt;Bitmap&amp;nbsp;&lt;/b&gt;to be used for its intended purpose in this program. The reference is cast to type&amp;nbsp;&lt;b class="emphasis" id="strong1087"&gt;Bitmap&amp;nbsp;&lt;/b&gt;and saved in the variable named&amp;nbsp;&lt;b class="emphasis" id="strong1088"&gt;original&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="para" id="p1107" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When the first statement in Listing 4 finishes executing, the variable named&amp;nbsp;&lt;b class="emphasis" id="strong1089"&gt;original&amp;nbsp;&lt;/b&gt;refers to a&amp;nbsp;&lt;b class="emphasis" id="strong1090"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object containing the image from the image file specified in Listing 2.&lt;/div&gt;&lt;div class="para" id="p1108" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1091"&gt;Set the dimensions of the VBox object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1109" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;After creating the new&amp;nbsp;&lt;b class="emphasis" id="strong1092"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object, Listing 4 uses the dimensions of the&amp;nbsp;&lt;b class="emphasis" id="strong1093"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object to set the dimensions of the&amp;nbsp;&lt;b class="emphasis" id="strong1094"&gt;VBox&amp;nbsp;&lt;/b&gt;object, which is shown by the yellow background in Figure 1.&lt;/div&gt;&lt;div class="para" id="p1110" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1095"&gt;Can use almost any image&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1111" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;All of the placement information for the images shown in Figure 1 is based on the dimensions of the&amp;nbsp;&lt;b class="emphasis" id="strong1096"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object. Therefore, you should be able to substitute any JPEG, PNG, or GIF image file in place of my file so long as the name of the file matches the name and location of the file specified in Listing 2. Note however that your image file will need to be wide enough and tall enough to prevent the magenta and green color bars added to the center image in Figure 1 from extending outside the image.&lt;/div&gt;&lt;div class="para" id="p1112" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1097"&gt;Dealing with a type compatibility issue&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1113" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In the earlier lesson titled&amp;nbsp;&lt;b class="emphasis" id="strong1098"&gt;Bitmap Basics&amp;nbsp;&lt;/b&gt;, I explained that in order to add a child to a&amp;nbsp;&lt;b class="emphasis" id="strong1099"&gt;VBox&amp;nbsp;&lt;/b&gt;object, that child:&lt;/div&gt;&lt;div class="list" id="ul1010" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1050" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Must be a subclass of the&amp;nbsp;&lt;b class="emphasis" id="strong1100"&gt;DisplayObject&amp;nbsp;&lt;/b&gt;class and&lt;/li&gt;&lt;li class="item" id="li1051" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Must implement the&amp;nbsp;&lt;b class="emphasis" id="strong1101"&gt;IUIComponent&amp;nbsp;&lt;/b&gt;interface.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="para" id="p1114" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;While a&amp;nbsp;&lt;b class="emphasis" id="strong1102"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object is a subclass of&amp;nbsp;&lt;b class="emphasis" id="strong1103"&gt;DisplayObject&amp;nbsp;&lt;/b&gt;, it does not implement the&amp;nbsp;&lt;b class="emphasis" id="strong1104"&gt;IUIComponent&amp;nbsp;&lt;/b&gt;interface. Therefore, it is not compatible with being added directly to the&lt;b class="emphasis" id="strong1105"&gt;VBox&amp;nbsp;&lt;/b&gt;object. I resolved the issue in that lesson by encapsulating the&amp;nbsp;&lt;b class="emphasis" id="strong1106"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object in an object of the&amp;nbsp;&lt;b class="emphasis" id="strong1107"&gt;UIComponent&amp;nbsp;&lt;/b&gt;class, which implements the&amp;nbsp;&lt;b class="emphasis" id="strong1108"&gt;IUIComponent&amp;nbsp;&lt;/b&gt;interface.&lt;/div&gt;&lt;div class="para" id="p1115" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1109"&gt;Encapsulate the Bitmap in an Image object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1116" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In this lesson, I decided to be more specific and encapsulate the&amp;nbsp;&lt;b class="emphasis" id="strong1110"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object in an object of the&amp;nbsp;&lt;b class="emphasis" id="strong1111"&gt;Image&amp;nbsp;&lt;/b&gt;class. This is allowable because the&amp;nbsp;&lt;b class="emphasis" id="strong1112"&gt;Image&amp;nbsp;&lt;/b&gt;class is a subclass of the&lt;b class="emphasis" id="strong1113"&gt;UIComponent&amp;nbsp;&lt;/b&gt;class.&lt;/div&gt;&lt;div class="para" id="p1117" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 5 encapsulates the&amp;nbsp;&lt;b class="emphasis" id="strong1114"&gt;Bitmap&amp;nbsp;&lt;/b&gt;in an&amp;nbsp;&lt;b class="emphasis" id="strong1115"&gt;Image&amp;nbsp;&lt;/b&gt;object and adds it to the&amp;nbsp;&lt;b class="emphasis" id="strong1116"&gt;VBox&amp;nbsp;&lt;/b&gt;object to be displayed at the top of and five pixels to the right of the left edge of the&amp;nbsp;&lt;b class="emphasis" id="strong1117"&gt;VBox&amp;nbsp;&lt;/b&gt;as shown by the top image in Figure 1.&lt;/div&gt;&lt;div class="example" id="listing1004" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 5:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_5"&gt;&lt;/b&gt;Encapsulate the Bitmap in an Image object.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1005" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      //Encapsulate the bitmap in an Image object and add&lt;br /&gt;      // the Image object to the VBox. Display it at&lt;br /&gt;      // x=5 and y=0&lt;br /&gt;      original.x = 5;&lt;br /&gt;      original.y = 0;&lt;br /&gt;      var imageA:Image = new Image();&lt;br /&gt;      imageA.addChild(original);&lt;br /&gt;      this.addChild(imageA);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1118" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1118"&gt;A curious situation&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1119" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;This brings up a curious situation regarding the placement of the&amp;nbsp;&lt;b class="emphasis" id="strong1119"&gt;Image&amp;nbsp;&lt;/b&gt;objects in the&amp;nbsp;&lt;b class="emphasis" id="strong1120"&gt;VBox&amp;nbsp;&lt;/b&gt;object. Normally, if you instantiate&amp;nbsp;&lt;b class="emphasis" id="strong1121"&gt;Image&amp;nbsp;&lt;/b&gt;objects and populate them directly from the contents of image files&amp;nbsp;&lt;i class="emphasis" id="em1028"&gt;(&amp;nbsp;&lt;/i&gt;&lt;b class="emphasis" id="calling"&gt;&lt;i class="emphasis" id="em1029"&gt;by calling the load method on the&amp;nbsp;&lt;/i&gt;&lt;b class="emphasis" id="strong1122"&gt;&lt;i class="emphasis" id="em1030"&gt;Image&amp;nbsp;&lt;/i&gt;&lt;/b&gt;&lt;i class="emphasis" id="em1031"&gt;object)&amp;nbsp;&lt;/i&gt;&lt;/b&gt;, you can add them to a&amp;nbsp;&lt;b class="emphasis" id="strong1123"&gt;VBox&amp;nbsp;&lt;/b&gt;object without the requirement to specify the locations at which the images will be displayed. The layout management rules of the&amp;nbsp;&lt;b class="emphasis" id="strong1124"&gt;VBox&amp;nbsp;&lt;/b&gt;object determine how they are displayed.&lt;/div&gt;&lt;div class="para" id="p1120" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1125"&gt;This case is different&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1121" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In this case, however, if you instantiate&amp;nbsp;&lt;b class="emphasis" id="strong1126"&gt;Image&amp;nbsp;&lt;/b&gt;objects and populate them with&amp;nbsp;&lt;b class="emphasis" id="strong1127"&gt;Bitmap&amp;nbsp;&lt;/b&gt;objects by calling the&amp;nbsp;&lt;b class="emphasis" id="strong1128"&gt;addChild&amp;nbsp;&lt;/b&gt;method as shown in Listing 5, you must specify the display locations of the&amp;nbsp;&lt;b class="emphasis" id="strong1129"&gt;Bitmap&amp;nbsp;&lt;/b&gt;objects within the&amp;nbsp;&lt;b class="emphasis" id="strong1130"&gt;VBox&amp;nbsp;&lt;/b&gt;object. If you don't, they all end up in the upper-left corner of the&amp;nbsp;&lt;b class="emphasis" id="strong1131"&gt;VBox&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="para" id="p1122" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1132"&gt;Honoring the boundaries of the VBox object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1123" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Also, if you specify the dimensions of the&amp;nbsp;&lt;b class="emphasis" id="strong1133"&gt;VBox&amp;nbsp;&lt;/b&gt;object and add more images of the&amp;nbsp;&lt;a class="cnxn" href="http://cnx.org/content/m34461/latest/#calling" id="a1049" style="color: #336699; font-weight: bold;"&gt;first type&amp;nbsp;&lt;/a&gt;than the size of the&amp;nbsp;&lt;b class="emphasis" id="strong1134"&gt;VBox&amp;nbsp;&lt;/b&gt;object can accommodate, scroll bars automatically appear on the&amp;nbsp;&lt;b class="emphasis" id="strong1135"&gt;VBox&amp;nbsp;&lt;/b&gt;object.&lt;/div&gt;&lt;div class="para" id="p1124" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In this case, however, if you specify the locations such that the&amp;nbsp;&lt;b class="emphasis" id="strong1136"&gt;Image&amp;nbsp;&lt;/b&gt;objects won't all fit within the boundaries of the&amp;nbsp;&lt;b class="emphasis" id="strong1137"&gt;VBox&amp;nbsp;&lt;/b&gt;object, the images extend outside the bounds of the&amp;nbsp;&lt;b class="emphasis" id="strong1138"&gt;VBox&amp;nbsp;&lt;/b&gt;object.&lt;/div&gt;&lt;div class="para" id="p1125" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;I will leave it as an exercise for the student to sort through all of that.&lt;/div&gt;&lt;div class="para" id="p1126" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1139"&gt;Clone the original&amp;nbsp;&lt;b class="emphasis" id="strong1140"&gt;Bitmap&amp;nbsp;&lt;/b&gt;to create a duplicate Bitmap&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1127" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;We have now reached the point where we could access the&amp;nbsp;&lt;b class="emphasis" id="strong1141"&gt;BitmapData&amp;nbsp;&lt;/b&gt;object encapsulated in the&amp;nbsp;&lt;b class="emphasis" id="strong1142"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object and modify the pixel data that comprises the image. However, instead of modifying the pixels in the original&amp;nbsp;&lt;b class="emphasis" id="strong1143"&gt;Bitmap&amp;nbsp;&lt;/b&gt;, I elected to create a duplicate bitmap and modify the pixels in the duplicate. That makes it possible to compare the unmodified image&amp;nbsp;&lt;i class="emphasis" id="em1032"&gt;(top image in Figure 1)&amp;nbsp;&lt;/i&gt;with the modified image&amp;nbsp;&lt;i class="emphasis" id="em1033"&gt;(middle image in Figure 1).&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1128" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 6 calls the&amp;nbsp;&lt;b class="emphasis" id="strong1144"&gt;clone&amp;nbsp;&lt;/b&gt;method on the original&amp;nbsp;&lt;b class="emphasis" id="strong1145"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object to create a duplicate&amp;nbsp;&lt;b class="emphasis" id="strong1146"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object, and saves the duplicate&amp;nbsp;&lt;b class="emphasis" id="strong1147"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object's reference in the variable named&lt;b class="emphasis" id="strong1148"&gt;duplicateB&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="example" id="listing1005" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 6:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_6"&gt;&lt;/b&gt;Clone the original Bitmap to create a duplicate Bitmap.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1006" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      var duplicateB:Bitmap = new Bitmap(&lt;br /&gt;                             original.bitmapData.clone());&lt;br /&gt;&lt;br /&gt;      duplicateB.x = 5;&lt;br /&gt;      duplicateB.y = original.height;&lt;br /&gt;      &lt;br /&gt;      var imageB:Image = new Image();&lt;br /&gt;      imageB.addChild(duplicateB);&lt;br /&gt;      this.addChild(imageB);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1129" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1149"&gt;Display the duplicate bitmap&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1130" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Then Listing 6 adds the duplicate bitmap to a new&amp;nbsp;&lt;b class="emphasis" id="strong1150"&gt;Image&amp;nbsp;&lt;/b&gt;object, positions the duplicate bitmap immediately below the top image in Figure 1 and adds the new image to the&lt;b class="emphasis" id="strong1151"&gt;VBox&amp;nbsp;&lt;/b&gt;. This is the middle image in Figure 1.&lt;/div&gt;&lt;div class="para" id="p1131" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1152"&gt;Another curious circumstance&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1132" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Curiously, the middle image in Figure 1 is five or six pixels further down than I expected it to be. This produces a gap of five or six pixels between the top two images in Figure 1. I am unable to explain the reason for the gap at this time, but I suspect that it may have something to do with the layout rules of the&amp;nbsp;&lt;b class="emphasis" id="strong1153"&gt;VBox&amp;nbsp;&lt;/b&gt;container object. When I place two or more ordinary&amp;nbsp;&lt;b class="emphasis" id="strong1154"&gt;Image&amp;nbsp;&lt;/b&gt;objects in a&amp;nbsp;&lt;b class="emphasis" id="strong1155"&gt;VBox&amp;nbsp;&lt;/b&gt;container, they appear in a vertical stack separated by about five or six pixels. However, that is total speculation on my part.&lt;/div&gt;&lt;div class="para" id="p1133" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1156"&gt;Modify the duplicate Bitmap&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1134" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 7 calls the&amp;nbsp;&lt;b class="emphasis" id="strong1157"&gt;modify&amp;nbsp;&lt;/b&gt;method passing a reference to&amp;nbsp;&lt;b class="emphasis" id="strong1158"&gt;duplicateB&amp;nbsp;&lt;/b&gt;as a parameter. This causes the middle image in Figure 1 to be modified in two different ways.&lt;/div&gt;&lt;div class="list" id="ul1011" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;ul class="bullet" style="display: block; line-height: 1.25em; list-style-image: none; list-style-type: disc; margin-bottom: 0px; margin-left: 2.5em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li class="item" id="li1052" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;First, the magenta and green rows of pixels are inserted near the upper left corner.&lt;/li&gt;&lt;li class="item" id="li1053" style="line-height: 1.5em; margin-bottom: 0.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Then a colored border two pixels thick is inserted around the four edges of the bitmap.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="example" id="listing1006" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 7:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_7"&gt;&lt;/b&gt;Modify the duplicate Bitmap.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1007" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      modify(duplicateB);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1135" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1159"&gt;Explain the modify method&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1136" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;At this point, I will put the explanation of the&amp;nbsp;&lt;b class="emphasis" id="strong1160"&gt;complete&amp;nbsp;&lt;/b&gt;event handler on hold and explain the method named&amp;nbsp;&lt;b class="emphasis" id="strong1161"&gt;modify&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="para" id="p1137" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1162"&gt;Beginning of the modify method&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1138" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The&amp;nbsp;&lt;b class="emphasis" id="strong1163"&gt;modify&amp;nbsp;&lt;/b&gt;method begins in Listing 8.&lt;/div&gt;&lt;div class="example" id="listing1007" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 8:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_8"&gt;&lt;/b&gt;Beginning of the modify method.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1008" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;    private function modify(bitmap:Bitmap):void{&lt;br /&gt;&lt;br /&gt;      var bitmapData:BitmapData = bitmap.bitmapData;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1139" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The incoming&amp;nbsp;&lt;b class="emphasis" id="strong1164"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object encapsulates a&amp;nbsp;&lt;b class="emphasis" id="strong1165"&gt;BitmapData&amp;nbsp;&lt;/b&gt;object, which is referenced by a property of the&amp;nbsp;&lt;b class="emphasis" id="strong1166"&gt;Bitmap&amp;nbsp;&lt;/b&gt;object named&amp;nbsp;&lt;b class="emphasis" id="strong1167"&gt;bitmapData&amp;nbsp;&lt;/b&gt;. Listing 8 gets a copy of that reference and saves it in a local variable named&amp;nbsp;&lt;b class="emphasis" id="strong1168"&gt;bitmapData&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="para" id="p1140" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1169"&gt;Process pixels using the getPixels and setPixels methods&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1141" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 9 begins by instantiating a new empty object of type&amp;nbsp;&lt;b class="emphasis" id="strong1170"&gt;ByteArray&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="example" id="listing1008" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 9:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_9"&gt;&lt;/b&gt;Process pixels using the getPixels and setPixels methods.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1009" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      var rawBytes:ByteArray = new ByteArray();&lt;br /&gt;      rawBytes = bitmapData.getPixels(&lt;br /&gt;                               new Rectangle(10,10,50,8));&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1142" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1171"&gt;The ByteArray class&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1143" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;According to the&amp;nbsp;&lt;a class="link" href="http://livedocs.adobe.com/flex/3/langref/flash/utils/ByteArray.html" id="a1050" style="color: #336699;"&gt;documentation&amp;nbsp;&lt;/a&gt;,&lt;/div&gt;&lt;div class="para" id="p1144" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1034"&gt;"The ByteArray class provides methods and properties to optimize reading, writing, and working with binary data."&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1145" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A&amp;nbsp;&lt;b class="emphasis" id="strong1172"&gt;ByteArray&amp;nbsp;&lt;/b&gt;object is an object that can be used to store and access data using either square bracket notation [] or method calls. The main benefit of using this data structure from our viewpoint is that it will decompose the 32-bit integers into 8-bit bytes and allow us access the pixel data one byte at a time. Otherwise it would be necessary for us to perform the decomposition ourselves using bit shift operations.&lt;/div&gt;&lt;div class="para" id="p1146" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1173"&gt;The getPixels method&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1147" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 9 populates the&amp;nbsp;&lt;b class="emphasis" id="strong1174"&gt;ByteArray&amp;nbsp;&lt;/b&gt;object by calling the&amp;nbsp;&lt;b class="emphasis" id="strong1175"&gt;getPixels&amp;nbsp;&lt;/b&gt;method on the&amp;nbsp;&lt;b class="emphasis" id="strong1176"&gt;BitmapData&amp;nbsp;&lt;/b&gt;object. According to the&amp;nbsp;&lt;a class="link" href="http://livedocs.adobe.com/flex/3/langref/flash/display/BitmapData.html#getPixels%28%29" id="a1051" style="color: #336699;"&gt;documentation&amp;nbsp;&lt;/a&gt;, this method&lt;/div&gt;&lt;div class="para" id="p1148" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1035"&gt;"Generates a byte array from a&amp;nbsp;&lt;b class="emphasis" id="strong1177"&gt;rectangular region&amp;nbsp;&lt;/b&gt;of pixel data. Writes an unsigned integer (a 32-bit unmultiplied pixel value) for each pixel into the byte array."&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1149" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1178"&gt;A Rectangle object&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1150" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A new&amp;nbsp;&lt;b class="emphasis" id="strong1179"&gt;Rectangle&amp;nbsp;&lt;/b&gt;object is instantiated to define the&amp;nbsp;&lt;i class="emphasis" id="em1036"&gt;rectangular region&amp;nbsp;&lt;/i&gt;from which the pixels are extracted. According to the documentation, the constructor for this class&lt;/div&gt;&lt;div class="para" id="p1151" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;i class="emphasis" id="em1037"&gt;"Creates a new&amp;nbsp;&lt;b class="emphasis" id="strong1180"&gt;Rectangle&amp;nbsp;&lt;/b&gt;object with the top-left corner specified by the x and y parameters and with the specified width and height parameters."&lt;/i&gt;&lt;/div&gt;&lt;div class="para" id="p1152" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The rectangular region specified by the parameters in Listing 9 has its upper-left corner at (10,10)&amp;nbsp;&lt;i class="emphasis" id="em1038"&gt;,&amp;nbsp;&lt;/i&gt;is 50 pixels wide, and 8 pixels high. This is the rectangular occupied by the magenta and green horizontal bars near the upper-left corner of the middle image in Figure 1.&lt;/div&gt;&lt;div class="para" id="p1153" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1181"&gt;The ByteArray object is populated with pixel data&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1154" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;When the&amp;nbsp;&lt;b class="emphasis" id="strong1182"&gt;getPixels&amp;nbsp;&lt;/b&gt;method returns in Listing 9, the pixels from that rectangular region are stored in the&amp;nbsp;&lt;b class="emphasis" id="strong1183"&gt;ByteArray&amp;nbsp;&lt;/b&gt;object referred to by&amp;nbsp;&lt;b class="emphasis" id="strong1184"&gt;rawBytes&amp;nbsp;&lt;/b&gt;.&lt;/div&gt;&lt;div class="para" id="p1155" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1185"&gt;The organization of the pixel data&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1156" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The first four bytes in the array belong to the pixel in the upper-left corner of the rectangular region. The next four bytes belong to the pixel immediately to the right of that one. The array is populated by the data from the rectangular region on a row by row basis.&lt;/div&gt;&lt;div class="para" id="p1157" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Each set of four bytes represent one pixel in ARGB format. In other words, the first byte in the four-byte group is the alpha byte. That byte is followed by the red byte, the green byte, and the blue byte in that order. This information is critical when time comes to use the data in the array to modify the pixel data.&lt;/div&gt;&lt;div class="para" id="p1158" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1186"&gt;The general procedure&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1159" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The general procedure when using this approach is to extract a rectangular region of pixels into the array, modify the array data, and then call the&amp;nbsp;&lt;b class="emphasis" id="strong1187"&gt;setPixels&amp;nbsp;&lt;/b&gt;method to write the modified color data back into the area of memory that represents the rectangular region from the bitmap data.&lt;/div&gt;&lt;div class="para" id="p1160" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1188"&gt;A very useful format&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1161" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;The format of the data in the&amp;nbsp;&lt;b class="emphasis" id="strong1189"&gt;ByteArray&amp;nbsp;&lt;/b&gt;object is very useful when you need to modify consecutive pixels on a row by row basis. It is less useful, but can be used when you need to modify pixels whose locations are more random in nature.&lt;/div&gt;&lt;div class="para" id="p1162" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;In our case, we want to set the color of all the pixels in the top four rows of the rectangular region to magenta and we want to set the color of all the pixels in the bottom four rows of the rectangular region to green as shown by the middle image in Figure 1. This data format is ideal for that kind of operation.&lt;/div&gt;&lt;div class="para" id="p1163" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1190"&gt;Modify the pixels in the rectangular region&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1164" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 10 sets the colors of the pixels in the top four rows to magenta and sets the colors of the pixels in the bottom four rows to green without modifying the value of the alpha byte.&lt;/div&gt;&lt;div class="example" id="listing1009" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 10:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_10"&gt;&lt;/b&gt;Modify the pixels in the rectangular region.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1010" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      var cnt:uint = 1;&lt;br /&gt;      while(cnt &amp;lt; rawBytes.length){&lt;br /&gt;        if(cnt &amp;lt; rawBytes.length/2){&lt;br /&gt;          rawBytes[cnt] = 255;&lt;br /&gt;          rawBytes[cnt + 1] = 0;&lt;br /&gt;          rawBytes[cnt + 2] = 255;&lt;br /&gt;        }else{&lt;br /&gt;          rawBytes[cnt] = 0;&lt;br /&gt;          rawBytes[cnt + 1] = 255;&lt;br /&gt;          rawBytes[cnt + 2] = 0;&lt;br /&gt;        } //end if-else&lt;br /&gt;    &lt;br /&gt;        cnt += 4;//Increment the counter by 4.&lt;br /&gt;      }//end while loop&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1165" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1191"&gt;The magenta and green color values&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1166" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;A magenta pixel is produced by setting the red and blue color bytes to full strength&amp;nbsp;&lt;i class="emphasis" id="em1039"&gt;(255)&amp;nbsp;&lt;/i&gt;and setting the green color byte to 0. A green pixel is produced by setting the red and blue color bytes to 0 and setting the green color byte to 255.&lt;/div&gt;&lt;div class="para" id="p1167" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1192"&gt;You should be OK by now&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1168" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Knowing what you now know, you should have no difficulty understanding how the data in the&amp;nbsp;&lt;b class="emphasis" id="strong1193"&gt;ByteArray&amp;nbsp;&lt;/b&gt;object is modified to produce the magenta and green colored areas near the upper-left corner of the middle image of Figure 1.&lt;/div&gt;&lt;div class="para" id="p1169" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1194"&gt;Not quite finished yet&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1170" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Note, however that we haven't modified the actual pixel data in the bitmap yet. So far we have made a copy of all the pixel data in the rectangular region and have modified the color values in the copy of the pixel data. We still need to write the modified pixel data back into the&amp;nbsp;&lt;b class="emphasis" id="strong1195"&gt;BitmapData&amp;nbsp;&lt;/b&gt;object to actually modify the image.&lt;/div&gt;&lt;div class="para" id="p1171" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1196"&gt;Put the modified pixel data back into the same rectangular region&lt;/b&gt;&lt;/div&gt;&lt;div class="para" id="p1172" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;Listing 11 calls the&amp;nbsp;&lt;b class="emphasis" id="strong1197"&gt;setPixels&amp;nbsp;&lt;/b&gt;method to store the pixel data that is contained in the&amp;nbsp;&lt;b class="emphasis" id="strong1198"&gt;rawBytes&amp;nbsp;&lt;/b&gt;array back into the same rectangular region of the bitmap image.&lt;/div&gt;&lt;div class="example" id="listing1010" style="border-bottom-color: rgb(51, 51, 51); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(51, 51, 51); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(204, 204, 204); border-top-style: solid; border-top-width: 1px; margin-bottom: 1.2em; margin-left: 3em; margin-right: 3em; margin-top: 1.2em; padding-bottom: 1em; padding-left: 1em; padding-right: 1em; padding-top: 1em;"&gt;&lt;h5 class="example-header" style="font-size: 1em; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="cnx_label" style="color: #336699; font-family: arial, helvetica, sans-serif; font-size: 0.9em; font-weight: bold; text-transform: uppercase;"&gt;LISTING 11:&amp;nbsp;&lt;/span&gt;&lt;strong class="title"&gt;&lt;b class="emphasis" id="Listing_11"&gt;&lt;/b&gt;Put the modified pixel data back into the same rectangular region.&lt;/strong&gt;&lt;/h5&gt;&lt;div class="code" id="pre1011" style="margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;pre class="codeblock" style="font-family: courier, 'courier new', monospace; font-size: 1em; line-height: normal; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-align: left;"&gt;&lt;code style="color: #006600; font-family: courier, 'courier new', monospace; font-size: 1.18em; font-style: normal;"&gt;      rawBytes.position = 0;//this is critical&lt;br /&gt;      bitmapData.setPixels(&lt;br /&gt;                      new Rectangle(10,10,50,8),rawBytes);&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="para" id="p1173" style="display: block; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 1em;"&gt;&lt;b class="emphasis" id="strong1199"&gt;The position pr
