<?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-5277669399194798662</id><updated>2012-01-08T23:58:55.903-08:00</updated><category term='PM'/><category term='Introduction'/><category term='XML'/><category term='Grid'/><category term='Network Game'/><category term='Book'/><category term='Android'/><category term='AI'/><category term='J2EE'/><category term='Paper'/><category term='Consistency'/><title type='text'>Research Reviews</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default?start-index=101&amp;max-results=100'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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>162</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-5277669399194798662.post-367157532607649688</id><published>2012-01-08T23:58:00.000-08:00</published><updated>2012-01-08T23:58:55.938-08:00</updated><title type='text'>Android Activity and task</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;A &lt;span style="color: blue;"&gt;task &lt;/span&gt;is a collection of activities that users interact with when performing a certain job. The activities are arranged in a stack (the "back stack"), in the order in which each activity is opened.&lt;br /&gt;A task is a cohesive unit that can move to the "background" when users begin a new task or go to the Home screen, via the HOME key.&lt;br /&gt;&lt;br /&gt;When the system stops one of your activities (such as when a new activity starts or the task moves to the background), the system might destroy that activity completely if it needs to recover system memory. The system's default behavior preserves the state of an activity when it is stopped. This way, when users navigate back to a previous activity, its user interface appears the way they left it. However, you can—and should—proactively retain the state of your activities using callback methods(onSaveInstanceState()), in case the activity is destroyed and must be recreated.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-367157532607649688?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/367157532607649688/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=367157532607649688' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/367157532607649688'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/367157532607649688'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2012/01/android-activity-and-task.html' title='Android Activity and task'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4931087046741792446</id><published>2011-12-31T20:07:00.001-08:00</published><updated>2011-12-31T20:07:01.361-08:00</updated><title type='text'>Mablab</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;a href="http://blog.163.com/zjg0202@126/blog/static/57519237200961798917/"&gt;http://blog.163.com/zjg0202@126/blog/static/57519237200961798917/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4931087046741792446?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4931087046741792446/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4931087046741792446' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4931087046741792446'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4931087046741792446'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/12/mablab.html' title='Mablab'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7829371855371620891</id><published>2011-12-29T01:00:00.000-08:00</published><updated>2011-12-29T01:00:39.596-08:00</updated><title type='text'>svn commands</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;1. Check updated uncommit local files&lt;br /&gt;svn status -u&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7829371855371620891?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7829371855371620891/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7829371855371620891' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7829371855371620891'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7829371855371620891'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/12/svn-commands.html' title='svn commands'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-800735683251438975</id><published>2011-12-19T06:54:00.000-08:00</published><updated>2011-12-19T06:54:15.900-08:00</updated><title type='text'>SVG</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;How to change text in SVG via external javascript&lt;br /&gt;&lt;br /&gt;&lt;pre class="brush: js;"&gt;var elem = document.getElemetById("textElem"); // Assuming textElem is the id of text object in SVG.&lt;br /&gt;textElem.firstChild.nodeValue = "Nex Text Here";&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;How the SVG was loading the javascript. Assuming WebKit-based browsers, I had to link the external javascript file from inside the SVG, not the HTML document (which wouldn't work). In HTML, I used:&lt;br /&gt;&lt;pre class="brush: html;"&gt;&lt;object data="mydata.svg" height="100px" id="mydata" name="mydata" type="image/svg+xml" width="320px"&gt;&lt;/object&gt;&lt;br /&gt;//Then inside the SVG file, I linked the js file, and added an onload event, which happens after parsing, before rendering:&lt;br /&gt;&lt;svg version="1.1" id="mainLayer" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="100%" height="100%" viewBox="0 0 320 100" enable-background="new 0 0 320 100" xml:space="preserve" onload="init(evt)"&gt;&lt;br /&gt;&lt;_script xlink:href="test.js" type="text/ecmascript" encoding="utf-8"/&gt;&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;Then inside the javascript file:&lt;/p&gt;&lt;pre class="brush: js;"&gt;&lt;br /&gt;function init(evt) {&lt;br /&gt;// sample call&lt;br /&gt;     changeText("change my text");&lt;/p&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;function changeText(value) {&lt;br /&gt;    var svgText;&lt;br /&gt;    svgText = document.getElementById("varMyData").firstChild;&lt;br /&gt;    svgText.nodeValue = value;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-800735683251438975?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/800735683251438975/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=800735683251438975' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/800735683251438975'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/800735683251438975'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/12/svg.html' title='SVG'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7840428381467652373</id><published>2011-11-26T21:44:00.001-08:00</published><updated>2011-11-27T02:09:34.545-08:00</updated><title type='text'>Session management</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif;"&gt;&lt;span class="Apple-style-span" style="font-size: x-small;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;There are three widely used methods for maintaining sessions in web environment: URL arguments, hidden form fields and cookies. While each of them has its benefits and shortcomings, cookies have proven to be the most convenient and also the least insecure of the three.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="font-size: 13px; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif; font-size: 13px; line-height: 19px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif; font-size: 13px; line-height: 19px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif; font-size: 13px; line-height: 19px;"&gt;The "storage" of session IDs and the associated session data (user name, account number,&amp;nbsp;&lt;/span&gt;&lt;i style="background-color: white; font-family: sans-serif; font-size: 13px; line-height: 19px; text-align: -webkit-auto;"&gt;etc.&lt;/i&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif; font-size: 13px; line-height: 19px; text-align: -webkit-auto;"&gt;) on the web server is accomplished using a variety of techniques including, but not limited to: local memory, flat files, and databases.&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif; font-size: 13px; line-height: 19px; text-align: -webkit-auto;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif; text-align: -webkit-auto;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif; text-align: -webkit-auto;"&gt;&lt;span class="Apple-style-span" style="font-size: x-small;"&gt;&lt;span class="Apple-style-span" style="line-height: 19px;"&gt;To mitigate this particular threat (though not the XSS problem in general), &lt;span class="Apple-style-span" style="color: blue;"&gt;many web applications tie session cookies to the IP address&lt;/span&gt; of the user who originally logged in, and only permit that IP to use that cookie. This is effective in most situations (if an attacker is only after the cookie), but obviously breaks down in situations where an attacker spoofs their IP address, is behind the same NATed IP address or web proxy—or simply opts to tamper with the site or steal data through the injected script, instead of attempting to hijack the cookie for future use.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="font-size: 13px; line-height: 19px;"&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: sans-serif; text-align: -webkit-auto;"&gt;&lt;br /&gt;&lt;/span&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/5277669399194798662-7840428381467652373?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7840428381467652373/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7840428381467652373' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7840428381467652373'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7840428381467652373'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/11/session-management.html' title='Session management'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4752495457276705698</id><published>2011-11-26T21:30:00.001-08:00</published><updated>2011-11-27T02:08:48.899-08:00</updated><title type='text'>Foundations of Security</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;a href="http://www.amazon.com/Foundations-Security-Every-Programmer-Experts/dp/B002YX0GIC/ref=sr_1_1?ie=UTF8&amp;amp;qid=1322371771&amp;amp;sr=8-1"&gt;Foundations of Security: What Every Programmer Needs to Know&lt;/a&gt; &lt;br /&gt;&lt;br /&gt;Chapter 7 Client-State Manipulation&lt;br /&gt;To be secure, web applications should not trust clients, and should validate all input received from clients.&lt;br /&gt;&lt;br /&gt;Cross-site scripting&lt;br /&gt;Cross-site scripting (XSS) is a type of computer security vulnerability typically found in Web applications that enables attackers to inject client-side script into Web pages viewed by other users.&lt;br /&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;The non-persistent (or reflected) cross-site scripting&lt;/span&gt; vulnerability is by far the most common type. These holes show up when the data provided by a web client, most commonly in HTTP query parameters or in HTML form submissions, is used immediately by server-side scripts to generate a page of results for that user, without properly sanitizing the request.&lt;br /&gt;A classic example of a potential vector is a site search engine: if one searches for a string, the search string will typically be redisplayed verbatim on the result page to indicate what was searched for. A reflected attack is typically delivered via email or a neutral web site.&lt;br /&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;The persistent (or stored) XSS vulnerability &lt;/span&gt;is a more devastating variant of a cross-site scripting flaw: it occurs when the data provided by the attacker is saved by the server, and then permanently displayed on "normal" pages returned to other users in the course of regular browsing, without proper HTML escaping. A classic example of this is with online message boards where users are allowed to post HTML formatted messages for other users to read.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4752495457276705698?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4752495457276705698/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4752495457276705698' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4752495457276705698'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4752495457276705698'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/11/foundations-of-security.html' title='Foundations of Security'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4551878323090707668</id><published>2011-11-09T00:37:00.000-08:00</published><updated>2011-11-09T00:43:33.513-08:00</updated><title type='text'>Open new thread in Tomcat</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;To open new thread to handle the time&amp;nbsp;consuming task in Tomcat may have several method:&lt;br /&gt;&lt;br /&gt;1. JMS&lt;br /&gt;Maybe JMS is what you really looking for however it requires extra effort to use that on Tomcat because it is only Servlet Container(Tomcat is not a JEE container, but just a Servlet Container). You may eigher switch to real AppServer like Glassfish or JBoss or add JMS functionality to Tomcat by your own.&lt;br /&gt;http://blogs.captechconsulting.com/blog/jairo-vazquez/tomcat-and-jms&lt;br /&gt;&lt;br /&gt;2. Create a&amp;nbsp;ServletContextListener to maintain the background thread by&amp;nbsp;yourself&amp;nbsp;or use ExecutorService&lt;br /&gt;ServletContextListener is registered in web.xml and will be called when your app is started or stopped. You can then created (and later stop) your Thread, using the normal Java ways to create a Thread (or ExecutionService).&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://stackoverflow.com/questions/1194315/tomcat-background-threads"&gt;http://stackoverflow.com/questions/1194315/tomcat-background-threads&lt;/a&gt;&lt;br /&gt;&lt;a href="http://stackoverflow.com/questions/791986/background-thread-for-a-tomcat-servlet-app"&gt;http://stackoverflow.com/questions/791986/background-thread-for-a-tomcat-servlet-app&lt;/a&gt;&lt;br /&gt;&lt;a href="http://stackoverflow.com/questions/4907502/running-a-background-java-program-in-tomcat"&gt;http://stackoverflow.com/questions/4907502/running-a-background-java-program-in-tomcat&lt;/a&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4551878323090707668?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4551878323090707668/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4551878323090707668' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4551878323090707668'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4551878323090707668'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/11/open-new-thread-in-tomcat.html' title='Open new thread in Tomcat'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-9210517099692233228</id><published>2011-11-06T01:25:00.000-07:00</published><updated>2011-11-06T01:25:49.485-07:00</updated><title type='text'>Node.js</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 12px;"&gt;Node's stated number one goal is "to provide an easy way to build scalable network programs".&amp;nbsp;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 12px;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 12px; text-align: -webkit-auto;"&gt;What's the issue with current server programs? Let's do the math. In languages like Java™ and PHP, each connection spawns a new thread that potentially has an accompanying 2 MB of memory with it. On a system that has 8 GB of RAM, that puts the theoretical maximum number of concurrent connections at about 4,000 users. As your client-base grew, if you wanted your web application to support more users, you had to add more and more servers. Of course, this adds to a business's server costs, traffic costs, labor costs, and more. Adding to those costs are the potential technical issues — a user can be using different servers for each request, so any shared resources have to be shared across all the servers. For all these reasons, the bottleneck in the entire web application architecture (including traffic throughput, processor speed, and memory speed) was the maximum number of concurrent connections a server could handle.&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 12px; text-align: -webkit-auto;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="font-family: arial, sans-serif; font-size: 0.76em; text-align: -webkit-auto;"&gt;Node solves this issue by changing how a connection is made to the server. Instead of spawning a new OS thread for each connection (and allocating the accompanying memory with it), each connection fires an event run within the Node engine's process. Node also claims that it will never deadlock, since there are no locks allowed, and it doesn't directly block for I/O calls. Node claims that a server running it can support &lt;span class="Apple-style-span" style="color: blue;"&gt;tens of thousands of concurrent connections&lt;/span&gt;.&lt;/div&gt;&lt;div style="font-family: arial, sans-serif; font-size: 0.76em; text-align: -webkit-auto;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="font-family: arial, sans-serif; font-size: 0.76em; text-align: -webkit-auto;"&gt;Node itself runs V8 JavaScript.&amp;nbsp;The V8 JavaScript engine is the underlying JavaScript engine that Google uses with their Chrome browser.&amp;nbsp;JavaScript is a great language for event-driven programming, because it allows anonymous functions and closures, and more importantly, the syntax is familiar to nearly everyone who has ever coded. The callback functions that are called when an event occurs can be written in the same spot where you capture the event.&lt;/div&gt;&lt;div style="font-family: arial, sans-serif; font-size: 0.76em; text-align: -webkit-auto;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="font-family: arial, sans-serif; font-size: 0.76em; text-align: -webkit-auto;"&gt;&lt;/div&gt;&lt;div style="font-size: 0.76em;"&gt;Node is extremely well-designed for situations where you are expecting a high amount of traffic and the server-side logic and processing required isn't necessarily large before responding to the client. Here are some good examples of where Node would excel:&lt;/div&gt;&lt;ul style="font-family: 'Times New Roman'; font-size: medium;"&gt;&lt;li style="font-family: arial, sans-serif;"&gt;&lt;strong&gt;A RESTful API&lt;/strong&gt;&lt;div style="font-size: 0.76em;"&gt;A web service that provides a RESTful API takes in a few parameters, interprets them, pieces together a response, and flushes a response (usually a relatively small amount of text) back to the user . This is an ideal situation for Node, because it can be built to handle tens of thousands of connections. It also doesn't require a large amount of logic, and basically just looks up values from a database and pieces together a response. Since the response is a small amount of text, and the incoming request is a small amount of text, the traffic volume isn't high, and one machine can likely handle the API demands of even the busiest company's API.&lt;/div&gt;&lt;/li&gt;&lt;li style="font-family: arial, sans-serif;"&gt;&lt;strong&gt;Twitter queue&lt;/strong&gt;&lt;div style="font-size: 0.76em;"&gt;Think about a company like Twitter that has to receive tweets and write them to a database. There are literally thousands of tweets arriving every second, and the database can't possibly keep up with the number of writes required during peak usage times. Node becomes an important cog in the solution to this problem. As we've seen, Node can handle tens of thousands of incoming tweets. It can then quickly/easily write them to an in-memory Queuing mechanism (memcached for example), from which another separate process can write them to the database. Node's role in this is to quickly gather the tweet and pass this information off to another process responsible for writing it. Imagine another design — a normal PHP server that tries to handle writes to the DB itself — every tweet would cause a small delay as its written to the DB since the DB call would be blocking. A machine with this design may only be able to handle 2000 incoming tweets a second, due to the database latency. A million tweets a second, and you're talking 500 servers. Node, instead, handles every connection and doesn't block, enabling it to capture as many tweets as can be thrown at it. A node machine able to handle 50,000 tweets a second, and you're talking only 20 servers.&lt;/div&gt;&lt;/li&gt;&lt;li style="font-family: arial, sans-serif;"&gt;&lt;strong&gt;Video game statistics&lt;/strong&gt;&lt;div style="font-size: 0.76em;"&gt;If you've ever played a game like Call of Duty online, some things stick out at you immediately when you look at the game statistics, mainly that they must be tracking a TON of info about the game in order to produce that level of statistics. Then, factor in the millions of people playing the game at any point, and you realize there is a TON of information getting generated very quickly. Node is a good solution for this scenario, because it can capture the data getting generated from the games, do a minimal amount of consolidation on them, and then queue them up for writing to a database. It would seem silly to devote an entire server to tracking how many bullets people are firing in games, which might be the useful limit if you used a server like Apache, but it would seem less silly if instead you could devote a single server to tracking almost all the statistics from a game, like you might be able to do with a server running Node.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-9210517099692233228?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/9210517099692233228/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=9210517099692233228' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/9210517099692233228'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/9210517099692233228'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/11/nodejs.html' title='Node.js'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7902790099154744364</id><published>2011-10-31T06:49:00.000-07:00</published><updated>2011-10-31T06:49:02.958-07:00</updated><title type='text'>REST in Practice</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;Access to a resource is always mediated by way of its &lt;span class="Apple-style-span" style="color: blue;"&gt;representations&lt;/span&gt;. That is, web components&amp;nbsp;exchange representations; they never access the underlying resource directly—&lt;span class="Apple-style-span" style="color: blue;"&gt;the Web does not support pointers!&lt;/span&gt; URIs relate, connect, and associate representations&amp;nbsp;with their resources on the Web. This separation between a resource and its representations&amp;nbsp;&lt;span class="Apple-style-span" style="color: blue;"&gt;promotes loose coupling&lt;/span&gt; between&amp;nbsp;back-end&amp;nbsp;systems and consuming applications. It&amp;nbsp;also helps with scalability, since a representation can be cached and replicated.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Using &lt;span class="Apple-style-span" style="color: blue;"&gt;content negotiation,&lt;/span&gt; consumers can negotiate for specific representation formats&amp;nbsp;from a service. They do so by populating the &lt;span class="Apple-style-span" style="color: blue;"&gt;HTTP Accept&lt;/span&gt; request header with a list of&amp;nbsp;media types they’re prepared to process.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Taken together, &lt;span class="Apple-style-span" style="color: blue;"&gt;verbs &lt;/span&gt;and &lt;span class="Apple-style-span" style="color: blue;"&gt;status codes&lt;/span&gt; provide a general framework for&amp;nbsp;operating on resources over the network.&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;REST describes the Web as a distributed hypermedia application whose linked&amp;nbsp;resources communicate by exchanging representations of resource state.&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;The Web is no longer just a successful&amp;nbsp;large-scale information system, but a platform for an ecosystem of services.&lt;/div&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7902790099154744364?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7902790099154744364/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7902790099154744364' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7902790099154744364'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7902790099154744364'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/10/rest-in-practice.html' title='REST in Practice'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-25108831952230974</id><published>2011-10-26T08:46:00.000-07:00</published><updated>2011-10-26T08:46:26.050-07:00</updated><title type='text'>The Web Application Hacker’s Handbook</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Dafydd Stuttard, Marcus Pinto, Wiley Publishing, Inc.&lt;br /&gt;&lt;br /&gt;The Core Security Problem: Users Can Submit Arbitrary Input to the server-side application.&lt;br /&gt;&lt;br /&gt;The majority of attacks against web applications involve sending input to the server which is crafted to cause some event that was not expected or desired by the application’s designer.&lt;br /&gt;&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;Changing the price of a product transmitted in a &lt;span class="Apple-style-span" style="color: blue;"&gt;hidden HTML form field&lt;/span&gt;, to fraudulently purchase the product for a cheaper amount.&lt;/li&gt;&lt;li&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;Modifying a session token &lt;/span&gt;transmitted in an HTTP cookie, to hijack the session of another authenticated user.&lt;/li&gt;&lt;li&gt;Removing certain parameters that are normally submitted, to &lt;span class="Apple-style-span" style="color: blue;"&gt;exploit a logic flaw&lt;/span&gt; in the application’s processing.&lt;/li&gt;&lt;li&gt;Altering some input that will be processed by a back-end database, to &lt;span class="Apple-style-span" style="color: blue;"&gt;inject a malicious database query &lt;/span&gt;and so access sensitive data.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-25108831952230974?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/25108831952230974/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=25108831952230974' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/25108831952230974'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/25108831952230974'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/10/web-application-hackers-handbook.html' title='The Web Application Hacker’s Handbook'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7520877558667055847</id><published>2011-09-22T09:10:00.000-07:00</published><updated>2011-09-22T09:12:23.884-07:00</updated><title type='text'>Bitnami Image installation on EC2</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;a href="http://bitnami.org/files/stacks/tomcatstack/6.0.33-0/README.txt"&gt;http://bitnami.org/files/stacks/tomcatstack/6.0.33-0/README.txt&lt;/a&gt;&lt;br /&gt;&lt;a href="http://bitnami.org/stack/tomcatstack"&gt;http://bitnami.org/stack/tomcatstack&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7520877558667055847?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7520877558667055847/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7520877558667055847' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7520877558667055847'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7520877558667055847'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/09/bitnami-image-installation-on-ec2.html' title='Bitnami Image installation on EC2'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-3595924210123731246</id><published>2011-09-22T08:31:00.000-07:00</published><updated>2011-10-03T05:37:48.238-07:00</updated><title type='text'>Ubuntu Installation</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;1. How to install and config SVN&lt;br /&gt;&lt;a href="http://www.subversionary.org/howto/setting-up-a-subversion-server-on-ubuntu-gutsy-gibbon-server"&gt;http://www.subversionary.org/howto/setting-up-a-subversion-server-on-ubuntu-gutsy-gibbon-server&lt;/a&gt;&lt;br /&gt;&lt;a href="http://systhread.net/texts/200607subver.php"&gt;http://systhread.net/texts/200607subver.php&lt;/a&gt;&lt;br /&gt;&lt;a href="https://help.ubuntu.com/8.04/serverguide/C/subversion.html"&gt;https://help.ubuntu.com/8.04/serverguide/C/subversion.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;2. How to install and config trac&lt;br /&gt;&lt;br /&gt;3. How to install FTP Server&lt;br /&gt;&lt;a href="https://help.ubuntu.com/10.04/serverguide/C/ftp-server.html"&gt;https://help.ubuntu.com/10.04/serverguide/C/ftp-server.html&lt;/a&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-3595924210123731246?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/3595924210123731246/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=3595924210123731246' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3595924210123731246'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3595924210123731246'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/09/ubuntu-installation.html' title='Ubuntu Installation'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5465834933745947286</id><published>2011-09-11T00:15:00.000-07:00</published><updated>2011-09-11T03:49:17.822-07:00</updated><title type='text'>Even Faster Web Sites</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Steve Souders &amp;nbsp;-- O'Reilly&lt;br /&gt;&lt;br /&gt;The Project Triangle: Fast, Good, Cheap. Pick two. predicts that under ideal circumstances, it is not possible to obtain fast, good and cheap. There must be a trade-off.&lt;br /&gt;&lt;br /&gt;When looking at execution time, the place where programs spend most of their time is in loops. The return on optimization of code that is executed only once is negligible. The benefits of optimizing inner loops can be&amp;nbsp;significant.&lt;br /&gt;&lt;br /&gt;Adopting the &lt;a href="http://developer.yahoo.com/yslow/"&gt;YSlow&lt;/a&gt; rules can have a huge impact on the delivery time of web page. &lt;br /&gt;&lt;br /&gt;Typically, however, the bottleneck is not JavaScript, but the DOM, so fiddling(摆弄) the scripts will have little effectiveness.&lt;br /&gt;&lt;br /&gt;All browsers execute all JavaScript code in a page on a single thread(excepting the use of Web Sorkers).&lt;br /&gt;If your JavaScript code takes longer than 0.1 seconds to execute, your page won't have that slick, snappy feel, if it take longer than 1 second, the application fees sluggish; longer than 10 second, and the user will be extremely frustrated.&lt;br /&gt;&lt;br /&gt;Profilers Tool: Firebug for Firefox&lt;br /&gt;&lt;br /&gt;Memory problem. You can do this in two ways:&lt;br /&gt;User delete keyword to remove JavaScript objects that are no longer needed from&amp;nbsp;memory.&lt;br /&gt;Remove nodes that are no longer necessary from the web page DOM&lt;br /&gt;&lt;br /&gt;Normally, most browsers download components in parallel, but that's not the case for external scripts. When the browser starts downloading an external script, it won't start any&amp;nbsp;additional&amp;nbsp;downloads until the script has been completely downloaded, parsed, and executed. IE 8 is the first browser that supports&amp;nbsp;downloading scripts in parallel.&lt;br /&gt;&lt;br /&gt;Typically, the page's onload event doesn't fire until all resources have been downloaded.&lt;br /&gt;&lt;br /&gt;In many cases, a web page contains multiples scripts that have a particular dependency order. Using the normal SCRIPT SRC approach guarantees that the scripts are downloaded and executed in the order in which they are listed in th page.&lt;br /&gt;&lt;br /&gt;Script Onload is the preferred technique for coupling asynchronously loaded external scripts with inline scripts.&lt;br /&gt;&lt;br /&gt;Move Inline scripts to the bottom&lt;br /&gt;&lt;br /&gt;To provide consistent behavior, browsers ensure that CSS is applied in the order specified(appear in the HTML document).&lt;br /&gt;&lt;br /&gt;Write Efficient JavaScript&lt;br /&gt;1. User Local Variables. In a function&lt;br /&gt;&amp;nbsp; &amp;nbsp; var doc = document, ..... will be more efficient&lt;br /&gt;&amp;nbsp; &amp;nbsp; use var keyword when assigning a variable value for the first. if not, it will treat as a global variable.&lt;br /&gt;&lt;br /&gt;Comet is a term&amp;nbsp;describing&amp;nbsp;the&amp;nbsp;collection of techniques, protocols, and&amp;nbsp;implementations&amp;nbsp;that address making low-latency&amp;nbsp;data transit to&amp;nbsp;the&amp;nbsp;browser both viable and&amp;nbsp;scalable. On the client side,&amp;nbsp;the&amp;nbsp;common techniques include polling, long polling, forever frame(iframe), XHR streaming and soon, WebSocket.&lt;br /&gt;&lt;br /&gt;The server holds on to the request's connection by returning a Transfer-Encodeing: chunked or Connection: close response. When data is ready for a particular client or set of clients, those connections are identified and a response containing&amp;nbsp;the&amp;nbsp;payload is sent back to the browser. A toolkit such as &lt;a href="http://dojotoolkit.org/"&gt;Dojo Toolkit&lt;/a&gt; or a library such as js.io, can handle many of these complexities for your automatically.&lt;br /&gt;&lt;br /&gt;However, both polling and long polling introduce a new problem for traditional web servers that are not optimized to handle large numbers of long held or long-lived connections, but rather5 are optimized to open and close&amp;nbsp;connections&amp;nbsp;as quickly as possible. Apache, for example, is designed to handle approximately 10, 000 simultaneous connections per server, whereas a s good Comet server should be able to handle more than 50,000 long-held connections to be cost-effective in a delivering real-time applications. Please refer &lt;a href="http://cometdaily.com/maturity.html"&gt;Comet Maturity Guide&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Long polling does not support cross-domain requests if teh browser does not support cross-domain XHR, but the forever-frame technique does at lease support cross-subdomain. XHR traditionally has a more restrictive security model than iframes or script tags that are included or inserted into a documents. JSONP polling allows cross-domain polling through the insertion of script tags for each new request rather than relaying on the XHR.&lt;br /&gt;&lt;br /&gt;GIF is a&amp;nbsp;palette&amp;nbsp;image format (256 color). It is suitable for graphic rather than photo. It support binary type of transparency. it support animation.&lt;br /&gt;JPEG is a lossy format.&amp;nbsp;It is suitable for&amp;nbsp;photo&amp;nbsp;rather than&amp;nbsp;graphic. it does not support&amp;nbsp;transparency&amp;nbsp;and&amp;nbsp;animation.&lt;br /&gt;PNG is both&amp;nbsp;palette and true color format. it support full alpha transparency. it does not support cross browser animation.&lt;br /&gt;&lt;br /&gt;Image&amp;nbsp;optimization&amp;nbsp;tools: PNGOUT, IptiPNG, PngOptimizer Jpegtran, ImageMagick&lt;br /&gt;&lt;br /&gt;Some browser (IE6, 7) limit the number of parallel downloads to two per server. IE 8 and Firefox 3 increase this to six per server.&lt;br /&gt;&lt;br /&gt;When downloading resources from a single domain is the bottleneck, splitting resources across multiple domain s speeds up the page by increasing the number of parallel downloads.&lt;br /&gt;Browsers enforce the maximum&amp;nbsp;connections&amp;nbsp;per server constraint based on&amp;nbsp;the&amp;nbsp;hostname in&amp;nbsp;the&amp;nbsp;url, not&amp;nbsp;the&amp;nbsp;ip address to which it resolves.&lt;br /&gt;&lt;br /&gt;HTTP/1.0 responses are returned as one block of data, the size of which is communicated in&amp;nbsp;the&amp;nbsp;Content-Length header. The browser needs to know&amp;nbsp;the&amp;nbsp;size of the data in order to know when the&amp;nbsp;response&amp;nbsp;ends.&lt;br /&gt;HTTP/1.1 introuced&amp;nbsp;the&amp;nbsp;Transfer-Encoding: chunked response header. With chunked encoding, the HTML document can be returned in multiple blocks of data. Each chunk of the&amp;nbsp;response&amp;nbsp;starts with its own size indicator. This allows&amp;nbsp;the&amp;nbsp;browser to parse each chunk as soon as it arrives, resulting in a page that loads faster.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5465834933745947286?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5465834933745947286/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5465834933745947286' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5465834933745947286'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5465834933745947286'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/09/even-faster-web-sites.html' title='Even Faster Web Sites'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2601043274282827689</id><published>2011-09-09T01:54:00.001-07:00</published><updated>2011-09-09T01:54:55.123-07:00</updated><title type='text'></title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;1.&amp;nbsp;&lt;span class="Apple-style-span" style="background-color: white; font-family: Arial, 'Liberation Sans', 'DejaVu Sans', sans-serif; font-size: 14px; line-height: 18px;"&gt;How do we change emulator screen orientation to landscape or portrait?&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: Arial, 'Liberation Sans', 'DejaVu Sans', sans-serif; font-size: 14px; line-height: 18px;"&gt;Ctrl-F12 is the keyboard shortcut.&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-2601043274282827689?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2601043274282827689/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2601043274282827689' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2601043274282827689'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2601043274282827689'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/09/1.html' title=''/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-1136155981020250206</id><published>2011-08-24T08:08:00.000-07:00</published><updated>2011-08-26T08:33:49.596-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Android'/><title type='text'>Android UI线程</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;当一个程序第一次启动时，Android会同时启动一个对应的主线程（Main Thread），主线程主要负责处理与UI相关的事件。主线程通常又被叫做UI线程。在开发Android应用时必须遵守单线程模型的原则：Android UI操作并不是线程安全的并且这些操作必须在UI线程中执行。Android设置了一个5秒的超时时间，一旦用户的事件由于主线程阻塞而超过5秒钟没有响应，Android会弹出一个应用程序没有响应的对话框。&lt;br /&gt;&lt;br /&gt;Android禁止其他子线程来更新由UI thread创建的试图。&lt;br /&gt;&lt;br /&gt;Handler和Looper&lt;br /&gt;AsyncTask&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;br /&gt;Regardless of whether or not you use AsyncTask, always remember these two rules about the single thread model:&lt;br /&gt;&lt;br /&gt;Do not block the UI thread, and&lt;br /&gt;Make sure that you access the Android UI toolkit only on the UI thread.&lt;br /&gt;AsyncTask just makes it easier to do both of these things.&lt;br /&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/5277669399194798662-1136155981020250206?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/1136155981020250206/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=1136155981020250206' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1136155981020250206'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1136155981020250206'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/08/android-ui.html' title='Android UI线程'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-3771962115779203878</id><published>2011-08-11T06:42:00.000-07:00</published><updated>2011-08-11T06:59:24.402-07:00</updated><title type='text'>网摘-编程感悟</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;&lt;strong&gt;对所做的事情的理解越深，你就会做的越好。&lt;/strong&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;超级程序员跟那些平庸的、一般的程序员比起来，对自己要做的事情的理解要深的多的多。&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;对你的领域里的基础知识理解的越好，你就越容易提升到更高的层次。你对这一层次的知识理解的越好，你就更容易掌握下一层次，以此类推。&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;&lt;b&gt;DevOps&lt;/b&gt;是一种一起讨论和一起工作的文化。开始DevOps，意味着开始了一场你的程序员和系统管理者的心态的转变。只有当人们愿意相互交谈，关心相互的工作时，你才能更多更快的创造商业价值。&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-3771962115779203878?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/3771962115779203878/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=3771962115779203878' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3771962115779203878'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3771962115779203878'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/08/blog-post_11.html' title='网摘-编程感悟'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-6952537110273999753</id><published>2011-08-11T06:35:00.000-07:00</published><updated>2011-08-11T06:35:10.666-07:00</updated><title type='text'>代码审查</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;在Google，&lt;strong&gt;没有程序&lt;/strong&gt;，任何产品、任何项目的程序代码，可以在没有经过有效的代码审查前提交到代码库里的。&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;很显然：在代码提交前，用第二群眼睛检查一遍，防止bug混入。这是对其最常见的理解，是对代码审查的好处的最广泛的认识。但是，依我的经验来看，这反倒是它&lt;strong&gt;最不重要&lt;/strong&gt;的一点。人们确实在代码审查中找到了bug。可是，这些在代码审查中能发现的绝大部分bug，很显然，都是微不足道的bug，程序的作者花几分钟的时间就能发现它们。真正需要花时间去发现的bug不是在代码审查里能找到的。&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;代码审查的最大的功用是&lt;b&gt;纯社会性的&lt;/b&gt;。如果你在编程，而且&lt;strong&gt;知道&lt;/strong&gt;将会有同事检查你的代码，你编程态度就完全不一样了。你写出的代码将更加整洁，有更好的注释，更好的程序结构——因为你&lt;strong&gt;知道&lt;/strong&gt;，那个你很在意的人将会查看你的程序。没有代码审查，你知道人们最终还是会看你的程序。但这种事情不是立即发生的事，它不会给你带来同等的紧迫感，它不会给你相同的个人评判的那种感受。&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: arial, sans-serif; font-size: 13px;"&gt;还有一个非常重要的好处。代码审查能&lt;strong&gt;传播知识&lt;/strong&gt;。在很多的开发团队里，经常每一个人负责一个核心模块，每个人都只关注他自己的那个模块。除非是同事的模块影响了自己的程序，他们从不相互交流。这种情况的后果是，每个模块只有一个人熟悉里面的代码。如果这个人休假或——但愿不是——辞职了，其他人则束手无策。通过代码审查，至少会有两个人熟悉这些程序——作者，以及审查者。审查者并不能像程序的作者一样对程序十分了解——但他会熟悉程序的设计和架构，这是极其重要的。&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-6952537110273999753?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/6952537110273999753/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=6952537110273999753' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6952537110273999753'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6952537110273999753'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/08/blog-post.html' title='代码审查'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-224719985398761950</id><published>2011-07-27T02:34:00.000-07:00</published><updated>2011-07-27T02:34:27.633-07:00</updated><title type='text'>Java USB Programming</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;a href="http://libusbjava.sourceforge.net/wp/?page_id=8"&gt;http://libusbjava.sourceforge.net/wp/?page_id=8&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://javausbapi.blogspot.com/2010/05/java-usb-api.html"&gt;http://javausbapi.blogspot.com/2010/05/java-usb-api.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-224719985398761950?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/224719985398761950/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=224719985398761950' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/224719985398761950'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/224719985398761950'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/07/java-usb-programming.html' title='Java USB Programming'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-9141650694812909007</id><published>2011-07-26T23:01:00.000-07:00</published><updated>2011-07-26T23:04:11.142-07:00</updated><title type='text'>USB Programming on Mobile Platform</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Android&lt;br /&gt;Until android 3.1, the USB API is provided.&lt;br /&gt;&lt;br /&gt;Windows&amp;nbsp;Mobile&amp;nbsp;7&lt;br /&gt;Not support USB function.&lt;br /&gt;&lt;br /&gt;Blackberry&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #353f48; font-family: Arial, Helvetica, sans-serif; font-size: 12px; line-height: 17px;"&gt;The Blackberry provides the ability for programs to send and receive data over the USB port via named channels. On device there are two APIs which provide access. On the desktop PC side, Blackberry Desktop Manager&amp;nbsp;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: #353f48; font-family: Arial, Helvetica, sans-serif; font-size: 12px; line-height: 17px;"&gt;&amp;nbsp;APIs(COM) enable access of these USB channels.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #353f48; font-family: Arial, Helvetica, sans-serif; font-size: 12px; line-height: 17px;"&gt;&lt;a href="http://www.netdirect.ca/software/packages/barry/rawchannel.php"&gt;http://www.netdirect.ca/software/packages/barry/rawchannel.php&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-9141650694812909007?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/9141650694812909007/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=9141650694812909007' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/9141650694812909007'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/9141650694812909007'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/07/usb-programming-on-mobile-platform.html' title='USB Programming on Mobile Platform'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2558570494248360832</id><published>2011-07-26T05:28:00.000-07:00</published><updated>2011-07-28T01:47:09.475-07:00</updated><title type='text'>Service-Oriented Architecture: Concepts, Technology, and Design</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Web services-driven SOA is succeeding traditional distributed architecture on a  global scale.&lt;br /&gt;&lt;br /&gt;"Service-oriented architecture" is a term that represents a model in which automation logic is decomposed into smaller, distinct units of logic. Collectively, these units comprise a larger piece of business automation logic. Individually, these units can be distributed.&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/-zXslMITOdek/TjEc3gxlibI/AAAAAAAAAME/_jXNl4KVWa0/s1600/soa1.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="309" src="http://2.bp.blogspot.com/-zXslMITOdek/TjEc3gxlibI/AAAAAAAAAME/_jXNl4KVWa0/s320/soa1.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;div class="docList"&gt;Enterprise logic can be divided into two domains: business  logic and application logic. Service-oriented principles can be applied to  both.&lt;/div&gt;&lt;br /&gt;Modularity of Web services&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;messages = units of communication&lt;/li&gt;&lt;li&gt;operations = units of work&lt;/li&gt;&lt;li&gt;services = units of processing logic (collections of units of work)&lt;/li&gt;&lt;li&gt;processes = units of automation logic (coordinated aggregation of units of work)&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://1.bp.blogspot.com/-O9GgvYMRAjM/TjEiA0vdhdI/AAAAAAAAAMI/od0os_8Bij4/s1600/soa2.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="141" src="http://1.bp.blogspot.com/-O9GgvYMRAjM/TjEiA0vdhdI/AAAAAAAAAMI/od0os_8Bij4/s320/soa2.JPG" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&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/5277669399194798662-2558570494248360832?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2558570494248360832/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2558570494248360832' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2558570494248360832'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2558570494248360832'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/07/service-oriented-architecture-concepts.html' title='Service-Oriented Architecture: Concepts, Technology, and Design'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/-zXslMITOdek/TjEc3gxlibI/AAAAAAAAAME/_jXNl4KVWa0/s72-c/soa1.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5277669399194798662.post-5358276010966033268</id><published>2011-07-22T00:07:00.001-07:00</published><updated>2011-07-22T00:07:58.811-07:00</updated><title type='text'>Reverse proxy</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;In computer networks, a reverse proxy is a type of proxy server that retrieves resources on behalf of a client from one or more servers. These resources are then returned to the client as though it originated from the reverse proxy itself. While a forward proxy is usually situated between the client application (such as a web browser) and the server(s) hosting the desired resources, a reverse proxy is usually situated closer to the server(s) and will only return a configured set of resources.&lt;br /&gt;&lt;br /&gt;Squid is a proxy server and web cache daemon. It has a wide variety of uses, from speeding up a web server by caching repeated requests; to caching web, DNS and other computer network lookups for a group of people sharing network resources; to aiding security by filtering traffic. Although primarily used for HTTP and FTP, Squid includes limited support for several other protocols including TLS, SSL, Internet Gopher and HTTPS.&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5358276010966033268?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5358276010966033268/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5358276010966033268' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5358276010966033268'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5358276010966033268'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/07/reverse-proxy.html' title='Reverse proxy'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5803995729160419158</id><published>2011-07-12T07:13:00.001-07:00</published><updated>2011-07-12T07:13:12.275-07:00</updated><title type='text'>Linux command</title><content type='html'>&lt;a href="http://www.ha97.com/book/unixtoolbox_zh_CN.html"&gt;http://www.ha97.com/book/unixtoolbox_zh_CN.html&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5803995729160419158?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5803995729160419158/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5803995729160419158' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5803995729160419158'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5803995729160419158'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/07/linux-command.html' title='Linux command'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-271873167210354353</id><published>2011-07-07T22:54:00.000-07:00</published><updated>2011-07-07T22:54:15.030-07:00</updated><title type='text'>High Performance Web Sites</title><content type='html'>http://stevesouders.com/hpws/rules.php&lt;br /&gt;http://developer.yahoo.com/performance/rules.html&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-271873167210354353?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/271873167210354353/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=271873167210354353' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/271873167210354353'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/271873167210354353'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/07/high-performance-web-sites.html' title='High Performance Web Sites'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-3036883689760729251</id><published>2011-06-30T19:43:00.001-07:00</published><updated>2011-06-30T19:43:21.003-07:00</updated><title type='text'>Internet Security Best Practice</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;a href="http://developer.yahoo.com/security/"&gt;http://developer.yahoo.com/security/&lt;/a&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-3036883689760729251?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/3036883689760729251/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=3036883689760729251' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3036883689760729251'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3036883689760729251'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/06/internet-security-best-practice.html' title='Internet Security Best Practice'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7769314321808190546</id><published>2011-06-19T19:09:00.000-07:00</published><updated>2011-06-19T19:09:31.842-07:00</updated><title type='text'>JQuery</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="border-collapse: collapse; font-family: Arial, 'Liberation Sans', 'DejaVu Sans', sans-serif; font-size: 14px; line-height: 18px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-size: 14px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; word-wrap: break-word;"&gt;JSON vs JSONP&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-size: 14px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; word-wrap: break-word;"&gt;It's actually not too complicated...&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-size: 14px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; word-wrap: break-word;"&gt;Say you're on domain abc.com, and you want to make a request to domain xyz.com. To do so, you need to cross domain boundaries, a no-no in most of browserland.&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-size: 14px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; word-wrap: break-word;"&gt;The one item that bypasses this limitation is &lt;script&gt; tags. When you use a script tag, the domain limitation is ignored, but under normal circumstances, you can't really DO anything with the results, the script just gets evaluated.&lt;/p&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; clear: both; word-wrap: break-word; background-position: initial initial; background-repeat: initial initial; "&gt;Enter JSONP. When you make your request to a server that is JSONP enabled, you pass a special parameter that tells the server a little bit about your page. That way, the server is able to nicely wrap up its response in a way that your page can handle.&lt;/p&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; clear: both; word-wrap: break-word; background-position: initial initial; background-repeat: initial initial; "&gt;For example, say the server expects a parameter called "callback" to enable its JSONP capabilities. Then your request would look like:&lt;/p&gt;&lt;pre class="default prettyprint" style="margin-top: 0px; margin-right: 0px; margin-bottom: 10px; margin-left: 0px; padding-top: 5px; padding-right: 5px; padding-bottom: 5px; padding-left: 5px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; overflow-x: auto; overflow-y: auto; width: auto; max-height: 600px; background-position: initial initial; background-repeat: initial initial; "&gt;&lt;code style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; background-position: initial initial; background-repeat: initial initial; "&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;http&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;:&lt;/span&gt;&lt;span class="com" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: gray; background-position: initial initial; background-repeat: initial initial; "&gt;//www.xyz.com/sample.aspx?callback=mycallback&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;&lt;br /&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; clear: both; word-wrap: break-word; background-position: initial initial; background-repeat: initial initial; "&gt;Without JSONP, this might return some basic javascript object, like so:&lt;/p&gt;&lt;pre class="default prettyprint" style="margin-top: 0px; margin-right: 0px; margin-bottom: 10px; margin-left: 0px; padding-top: 5px; padding-right: 5px; padding-bottom: 5px; padding-left: 5px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; overflow-x: auto; overflow-y: auto; width: auto; max-height: 600px; background-position: initial initial; background-repeat: initial initial; "&gt;&lt;code style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; background-position: initial initial; background-repeat: initial initial; "&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;{&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt; foo&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;:&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt; &lt;/span&gt;&lt;span class="str" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(128, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;'bar'&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt; &lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;}&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;&lt;br /&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; clear: both; word-wrap: break-word; background-position: initial initial; background-repeat: initial initial; "&gt;However, with JSONP, when the server receives the "callback" parameter, it wraps up the result a little differently, returning something like this:&lt;/p&gt;&lt;pre class="default prettyprint" style="margin-top: 0px; margin-right: 0px; margin-bottom: 10px; margin-left: 0px; padding-top: 5px; padding-right: 5px; padding-bottom: 5px; padding-left: 5px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; overflow-x: auto; overflow-y: auto; width: auto; max-height: 600px; background-position: initial initial; background-repeat: initial initial; "&gt;&lt;code style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; background-position: initial initial; background-repeat: initial initial; "&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;mycallback&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;({&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt; foo&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;:&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt; &lt;/span&gt;&lt;span class="str" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(128, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;'bar'&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt; &lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;});&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;&lt;br /&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; clear: both; word-wrap: break-word; background-position: initial initial; background-repeat: initial initial; "&gt;As you can see, it will now invoke the method you specified. So, in your page, you define the callback function:&lt;/p&gt;&lt;pre class="default prettyprint" style="margin-top: 0px; margin-right: 0px; margin-bottom: 10px; margin-left: 0px; padding-top: 5px; padding-right: 5px; padding-bottom: 5px; padding-left: 5px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; overflow-x: auto; overflow-y: auto; width: auto; max-height: 600px; background-position: initial initial; background-repeat: initial initial; "&gt;&lt;code style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: rgb(238, 238, 238); font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; background-position: initial initial; background-repeat: initial initial; "&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;mycallback &lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;=&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt; &lt;/span&gt;&lt;span class="kwd" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 139); background-position: initial initial; background-repeat: initial initial; "&gt;function&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;(&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;data&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;){&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;&lt;br /&gt;&amp;nbsp; alert&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;(&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;data&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;.&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;foo&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;);&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;&lt;br /&gt;&lt;/span&gt;&lt;span class="pun" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;};&lt;/span&gt;&lt;span class="pln" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 0, 0); background-position: initial initial; background-repeat: initial initial; "&gt;&lt;br /&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; clear: both; word-wrap: break-word; background-position: initial initial; background-repeat: initial initial; "&gt;And now, when the script is loaded, it'll be evaluated, and your function will be executed. Voila, cross-domain requests!&lt;/p&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-bottom: 1em; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; clear: both; word-wrap: break-word; background-position: initial initial; background-repeat: initial initial; "&gt;It's also worth noting the one major issue with JSONP: you lose a lot of control of the request. For example, there is no "nice" way to get proper failure codes back. As a result, you end up using timers to monitor the request, etc, which is always a bit suspect. The proposition for&amp;nbsp;&lt;a href="http://www.json.org/JSONRequest.html" rel="nofollow" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-style: initial; border-color: initial; font-size: 14px; vertical-align: baseline; background-image: initial; background-attachment: initial; background-origin: initial; background-clip: initial; background-color: transparent; color: rgb(0, 119, 204); text-decoration: none; cursor: pointer; background-position: initial initial; background-repeat: initial initial; "&gt;JSONRequest&lt;/a&gt;&amp;nbsp;is a great solution to allowing cross domain scripting, maintaining security, and allowing proper control of the request.&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;/DIV&gt;&lt;/script&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/5277669399194798662-7769314321808190546?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7769314321808190546/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7769314321808190546' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7769314321808190546'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7769314321808190546'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/06/jquery.html' title='JQuery'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7311601323487907400</id><published>2011-06-14T23:11:00.001-07:00</published><updated>2011-06-14T23:11:36.493-07:00</updated><title type='text'>Embeded System</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;QNX is a commercial Unix-like real-time operating system, aimed primarily at the embedded systems market. The product was originally developed by Canadian company, QNX Software Systems, which was later acquired by BlackBerry-producer Research In Motion.&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7311601323487907400?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7311601323487907400/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7311601323487907400' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7311601323487907400'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7311601323487907400'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/06/embeded-system.html' title='Embeded System'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5627200304185885830</id><published>2011-06-14T20:47:00.000-07:00</published><updated>2011-06-14T20:47:20.315-07:00</updated><title type='text'>FOSS</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Free and open-source software (F/OSS, &lt;span style="color: blue;"&gt;FOSS&lt;/span&gt;) or free/libre/open-source software (&lt;span style="color: blue;"&gt;FLOSS&lt;/span&gt;) is liberally licensed to grant the right of users to use, study, change, and improve its design through the availability of its source code. This approach has gained both momentum and acceptance as the potential benefits have been increasingly recognized by both individuals and corporations.&lt;br /&gt;&lt;br /&gt;Rapid application development (&lt;span style="color: blue;"&gt;RAD&lt;/span&gt;) is a software development methodology that uses minimal planning in favor of rapid prototyping. The "planning" of software developed using RAD is interleaved with writing the software itself. The lack of extensive pre-planning generally allows software to be written much faster, and makes it easier to change requirements.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5627200304185885830?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5627200304185885830/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5627200304185885830' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5627200304185885830'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5627200304185885830'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/06/foss.html' title='FOSS'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7598123974930221011</id><published>2011-06-06T23:32:00.000-07:00</published><updated>2011-06-06T23:32:26.107-07:00</updated><title type='text'>Vertical market</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="font-family: sans-serif; font-size: 13px; line-height: 19px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="line-height: 1.5em; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0.4em;"&gt;A &lt;span class="Apple-style-span" style="color: blue;"&gt;vertical market&lt;/span&gt; is a market which meets the needs of a particular industry: for example, a piece of equipment used only by&amp;nbsp;semiconductor&amp;nbsp;manufacturers. It is also known as a&amp;nbsp;niche market.&lt;/div&gt;&lt;div style="line-height: 1.5em; margin-bottom: 0.5em; margin-left: 0px; margin-right: 0px; margin-top: 0.4em;"&gt;A &lt;span class="Apple-style-span" style="color: blue;"&gt;horizontal market&lt;/span&gt; is a market which meets a given need of a wide variety of industries, rather than a specific one: for example,&amp;nbsp;word processing&amp;nbsp;software&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/5277669399194798662-7598123974930221011?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7598123974930221011/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7598123974930221011' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7598123974930221011'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7598123974930221011'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/06/vertical-market.html' title='Vertical market'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5623812761668269762</id><published>2011-05-31T01:19:00.001-07:00</published><updated>2011-05-31T01:19:50.967-07:00</updated><title type='text'>内嵌Web浏览器</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;现在有很多程序在界面上都采用内嵌IE浏览器控件的方式，这样有几个好处：&lt;br /&gt;&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;界面设计与程序设计的解耦－说白了，美工精通的事，程序员很少有能精通的&lt;/li&gt;&lt;li&gt;界面的描述更方便和标准化－HTML，IT业者都知道的“秘密”，呵呵&lt;/li&gt;&lt;li&gt;更细粒度的模块划分－这对很多功能来说都可以做到更细粒度的控制，比如自动升级&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;当然，“天下没有免费的午餐”，这么做也要付出一些代价：&lt;br /&gt;&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;内存资源占用大－对于做共享软件的开发者，谁提这个他跟谁急&lt;/li&gt;&lt;li&gt;引入新的不稳定和不安全因素－IE稳定和安全？我看到盖茨先生笑了&lt;/li&gt;&lt;li&gt;当然，内嵌IE浏览器控件的方式还牵涉到界面的控制逻辑与底层操作之间的互动，前面我写过一篇《MFC或WTL嵌入webbrowser控件后的 Javascript、C++互操作》，介绍了大概的互操作方法。&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5623812761668269762?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5623812761668269762/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5623812761668269762' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5623812761668269762'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5623812761668269762'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/05/web.html' title='内嵌Web浏览器'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-6048315832326803868</id><published>2011-05-22T19:58:00.000-07:00</published><updated>2011-05-23T19:48:25.052-07:00</updated><title type='text'>32 and 64 Linux</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;&lt;br /&gt;FAQ:&lt;br /&gt;1. How can I tell if I'm running in 64-bit JVM or 32-bit JVM?&lt;br /&gt;&lt;pre class="brush: java;"&gt;System.getProperty("sun.arch.data.model") &lt;br /&gt;System.getProperty("os.arch");&lt;br /&gt;#&lt;br /&gt;# on a 64-bit Linux box:&lt;br /&gt;# "x86" when using 32-bit JVM&lt;br /&gt;# "xmd64" when using 64-bit JVM&lt;br /&gt;&lt;/pre&gt;You can try on the command line:&lt;br /&gt;&lt;pre class="brush:java;"&gt;java -d64 -version&lt;br /&gt;If it's not a 64-bit version, you'll get a message that looks like:&lt;br /&gt;&lt;br /&gt;This Java instance does not support a 64-bit JVM. Please install the desired version.&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;2. In LINUX determine if a .a library/archive 32-bit or 64-bit?&lt;br /&gt;objdump seems like the best way:&lt;br /&gt;&lt;pre class="brush: java;"&gt;objdump -f libfoo.a | grep ^architecture&lt;br /&gt;&lt;/pre&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-6048315832326803868?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/6048315832326803868/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=6048315832326803868' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6048315832326803868'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6048315832326803868'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/05/32-and-64-linux.html' title='32 and 64 Linux'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-1588094063130194123</id><published>2011-05-18T02:03:00.000-07:00</published><updated>2011-05-18T02:16:40.380-07:00</updated><title type='text'>VNC</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;In computing, Virtual Network Computing (VNC) is a graphical desktop sharing system that uses the RFB(Remote FrameBuffer) protocol to remotely control another computer. It transmits the keyboard and mouse events from one computer to another, relaying the graphical screen updates back in the other direction, over a network.&lt;br /&gt;&lt;br /&gt;The VNC protocol is pixel based. Although this leads to great flexibility (i.e. any type of desktop can be displayed), it is often less efficient than solutions that have a better understanding of the underlying graphic layout like X11 or desktop such as RDP. Those protocols send graphic primitives or high level commands in a simpler form (e.g. open window), whereas RFB just sends the raw pixel data.&lt;br /&gt;&lt;br /&gt;Remote Desktop Protocol (&lt;span class="Apple-style-span" style="color: blue;"&gt;&lt;b&gt;RDP&lt;/b&gt;&lt;/span&gt;) is a proprietary protocol developed by Microsoft, which concerns providing a user with a graphical interface to another computer. The protocol is an extension of the ITU-T T.128 application sharing protocol. Clients exist for most versions of Microsoft Windows (including Windows Mobile), Linux, Unix, Mac OS X, Android, and other modern operating systems. By default the server listens on TCP port 3389.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-1588094063130194123?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/1588094063130194123/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=1588094063130194123' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1588094063130194123'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1588094063130194123'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/05/vnc.html' title='VNC'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4668371802073155385</id><published>2011-05-03T23:39:00.000-07:00</published><updated>2011-05-03T23:39:06.071-07:00</updated><title type='text'>Device driver</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;Device drivers can be abstracted into logical and physical layers. Logical layers process data for a class of devices such as&amp;nbsp;Ethernet ports or disk drives. Physical layers communicate with specific device instances.&lt;br /&gt;&lt;br /&gt;In Linux environments, programmers can build device drivers either as parts of the kernel or separately as loadable modules.The Microsoft Windows .sys files and Linux .ko modules contain loadable device drivers. The advantage of loadable device&amp;nbsp;drivers is that they can be loaded only when necessary and then unloaded, thus saving kernel memory.&lt;br /&gt;&lt;br /&gt;Typically, the logical device driver (LDD) is written by the operating system vendor, while the physical device driver (PDD) is&amp;nbsp;implemented by the device vendor.&lt;br /&gt;&lt;br /&gt;Device drivers, particularly on modern Windows platforms, can run in kernel-mode (Ring 0) or in user-mode (Ring 3).The&amp;nbsp;primary benefit of running a driver in user mode is improved stability, since a poorly written user mode device driver cannot&amp;nbsp;crash the system by overwriting kernel memory. On the other hand, user/kernel-mode transitions usually impose a considerable&amp;nbsp;performance overhead, thereby prohibiting user mode-drivers for low latency and high throughput requirements.&lt;br /&gt;&lt;br /&gt;Kernel space can be accessed by user module only through the use of system calls. End user programs like the UNIX shell or&amp;nbsp;other GUI based applications are part of the user space. These applications interact with hardware through kernel supported&amp;nbsp;functions.&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4668371802073155385?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4668371802073155385/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4668371802073155385' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4668371802073155385'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4668371802073155385'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/05/device-driver.html' title='Device driver'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7101734423035382727</id><published>2011-04-28T22:56:00.000-07:00</published><updated>2011-04-29T01:29:48.872-07:00</updated><title type='text'>Linux Flavor</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;a href="http://www.testfreaks.com/blog/information/linux-bakers-dozen/"&gt;http://www.testfreaks.com/blog/information/linux-bakers-dozen/&lt;/a&gt;&lt;br /&gt;&lt;img src="http://i.testfreaks.com/blog/wp-content/uploads/2010/05/LinuxShare.jpg" /&gt;&lt;br /&gt;&lt;br /&gt;Flavors of UNIX:&lt;br /&gt;&lt;a href="http://middlewareforum.com/weblogic/?cat=15"&gt;http://middlewareforum.com/weblogic/?cat=15&lt;/a&gt;&lt;br /&gt;&lt;img src="http://middlewareforum.com/weblogic/wp-content/uploads/2011/04/Unix_Flavours-300x191.jpg" /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #444444; font-family: Georgia, 'Times New Roman', serif; font-size: 11px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;div style="font-size: 1.4em; line-height: 1.65; margin-bottom: 1.4em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Version 2 of Ravi’s Mind Map of Linux distributions。&lt;/div&gt;&lt;div style="font-size: 1.4em; line-height: 1.65; margin-bottom: 1.4em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;a href="http://www.thinknext.net/content/GNULinuxupdatedw4.png" style="border-bottom-color: rgb(204, 204, 204); border-bottom-style: dotted; border-bottom-width: 1px; color: #21759b; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none;"&gt;下载高解析度1300 x 1078版本&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;img src="http://www.thinknext.net/content/GNULinuxupdatedw4small.png" /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7101734423035382727?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7101734423035382727/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7101734423035382727' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7101734423035382727'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7101734423035382727'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/04/linux-flavor.html' title='Linux Flavor'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2395315532498961597</id><published>2011-04-26T19:57:00.001-07:00</published><updated>2011-04-29T01:19:00.330-07:00</updated><title type='text'>Python</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;Python is an interpreted, general-purpose high-level programming language[5] whose design philosophy emphasizes code&amp;nbsp;readability.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Installation:&lt;br /&gt;&lt;a href="http://trac.edgewall.org/wiki/0.12/TracInstall"&gt;http://trac.edgewall.org/wiki/0.12/TracInstall&lt;/a&gt;&lt;br /&gt;Install setuptools 0.6&lt;br /&gt;&lt;a href="http://pypi.python.org/pypi/setuptools"&gt;http://pypi.python.org/pypi/setuptools&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-2395315532498961597?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2395315532498961597/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2395315532498961597' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2395315532498961597'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2395315532498961597'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/04/python.html' title='Python'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8764941859799005918</id><published>2011-04-25T01:19:00.001-07:00</published><updated>2011-04-25T01:19:49.517-07:00</updated><title type='text'>SVG</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;br /&gt;SVG stands for Scalable Vector Graphics. SVG defines graphics in XML format. It is a language for describing 2D-graphics and&amp;nbsp;graphical applications in XML.&lt;br /&gt;&lt;br /&gt;The main competitor to SVG is Flash. The biggest advantage SVG has over Flash is the compliance with other standards (e.g. XSL&amp;nbsp;and the DOM). Flash relies on proprietary technology that is not open source.&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8764941859799005918?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8764941859799005918/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8764941859799005918' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8764941859799005918'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8764941859799005918'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/04/svg.html' title='SVG'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4543535259720883723</id><published>2011-04-19T00:37:00.000-07:00</published><updated>2011-04-19T00:44:22.649-07:00</updated><title type='text'>C++ Unicode</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: blue;"&gt;_T("Text")&lt;/span&gt; is a narrow-character (ASCII) literal in an ANSI build but a wide character (UNICODE) literal in a Unicode build.&lt;br /&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;L"Text"&lt;/span&gt; is always a wide-character literal, regardless of preprocessor definitions.&lt;br /&gt;_T() is a macro, the L prefix is part of the core C and C++ language lexical structure.&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;ref&lt;/div&gt;&lt;div&gt;&lt;a href="http://stackoverflow.com/questions/402283/stdwstring-vs-stdstring"&gt;http://stackoverflow.com/questions/402283/stdwstring-vs-stdstring&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;a href="http://www.codeproject.com/KB/cpp/unicode.aspx"&gt;http://www.codeproject.com/KB/cpp/unicode.aspx&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.codeproject.com/KB/stl/upgradingstlappstounicode.aspx"&gt;http://www.codeproject.com/KB/stl/upgradingstlappstounicode.aspx&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.vckbase.com/document/viewdoc/?id=1734"&gt;http://www.vckbase.com/document/viewdoc/?id=1734&lt;/a&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/5277669399194798662-4543535259720883723?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4543535259720883723/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4543535259720883723' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4543535259720883723'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4543535259720883723'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/04/c-unicode.html' title='C++ Unicode'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7730774213610981463</id><published>2011-02-08T01:39:00.001-08:00</published><updated>2011-02-08T01:39:37.640-08:00</updated><title type='text'>Java Code Obfuscator</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;The Java programming language is particularly open to reverse-engineering attacks because of its well-defined, open, and portable binary format. One area of better-securing the intellectual property of a Java program is obfuscation.&lt;br /&gt;&lt;br /&gt;Obfuscation of a program involves transforming the code of the program into a more complex, but semantically equivalent representation. This can include the addition of confusing control flow, the removal of certain information embedded in the program which is not explicitly required for execution, or the cloaking of data.&lt;br /&gt;&lt;br /&gt;Open Source Obfuscators in Java(http://java-source.net/open-source/obfuscators)&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;ProGuard&lt;/li&gt;&lt;li&gt;yGuard&lt;/li&gt;&lt;li&gt;JODE&lt;/li&gt;&lt;li&gt;JavaGuard&lt;/li&gt;&lt;li&gt;RetroGuard&lt;/li&gt;&lt;li&gt;jarg&lt;/li&gt;&lt;/ul&gt;&lt;div style="text-align: left;"&gt;&lt;br /&gt;commercial Obfuscators in Java&lt;/div&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;Zelix Klassmaster&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7730774213610981463?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7730774213610981463/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7730774213610981463' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7730774213610981463'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7730774213610981463'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/02/java-code-obfuscator.html' title='Java Code Obfuscator'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5330790110258141404</id><published>2011-02-07T17:32:00.000-08:00</published><updated>2011-02-07T17:32:59.055-08:00</updated><title type='text'>Advantages of Exceptions</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span style="color: blue;"&gt;Advantage 1: Separating Error-Handling Code from "Regular" Code&lt;/span&gt;&lt;br /&gt;Exceptions provide the means to separate the details of what to do when something out of the ordinary happens from the main logic of a program. In traditional programming, error detection, reporting, and handling often lead to confusing spaghetti code.&lt;br /&gt;&lt;br /&gt;&lt;span style="color: blue;"&gt;Advantage 2: Propagating Errors Up the Call Stack&lt;/span&gt;&lt;br /&gt;A second advantage of exceptions is the ability to propagate error reporting up the call stack of methods.&lt;br /&gt;&lt;br /&gt;&lt;span style="color: blue;"&gt;Advantage 3: Grouping and Differentiating Error Types&lt;/span&gt;&lt;br /&gt;Because all exceptions thrown within a program are objects, the grouping or categorizing of exceptions is a natural outcome of the class hierarchy. &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5330790110258141404?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5330790110258141404/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5330790110258141404' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5330790110258141404'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5330790110258141404'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/02/advantages-of-exceptions.html' title='Advantages of Exceptions'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7271319297560305423</id><published>2011-02-06T16:42:00.000-08:00</published><updated>2011-03-09T01:06:19.893-08:00</updated><title type='text'>Comparison of wireless communication</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Wireless Technology: Bluetooth, WiFi, WiMAX&lt;br /&gt;http://www.awirelesslife.com/wireless.html&lt;br /&gt;Bluetooth-WiFi-WiMAX &lt;br /&gt;http://wenku.baidu.com/view/2609f68ecc22bcd126ff0ce1.html&lt;br /&gt;Compare with other Technologies(bluetooth) &lt;br /&gt;http://www.bluetooth.com/English/Technology/Works/Pages/Compare.aspx&lt;br /&gt;How does ZigBee compare with other wireless standards?&lt;br /&gt;http://www.stg.com/wireless/ZigBee_comp.html&lt;br /&gt;http://gigaom.com/cleantech/the-race-is-still-on-zigbee-vs-wifi-for-smart-energy-homes/&lt;br /&gt;http://panometric.net/zigbee-vs-wifi-smackdown/&lt;br /&gt;http://www.emeter.com/2010/smart-appliances-wifi-vs-zigbee-communications-the-great-debate/&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;If Wifi can be in the same order of magnitude as Zigbee in battery life and cost, and mesh is an unneeded or easily added capability, Zigbee may not fly for being just another protocol. &lt;br /&gt;&lt;br /&gt;Wireless sensors are most useful when their data ubiquitous, and all the other devices you want to use to display, notify, and interact are on IP networks. So WiFi has a huge advantage there in that it is IP friendly. In fact, I foresee a time when wireless sensor devices can use web services directly, rather than need application servers. Data analysis and messaging could be done in the cloud where it is reliable and manageable.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;ZigBee&lt;/b&gt;&lt;br /&gt;ZigBee-style networks began to be conceived around 1998, when many installers realized that both Wi-Fi and Bluetooth were going to be unsuitable for many applications. In particular, many engineers[by whom?] saw a need for self-organizing ad-hoc digital radio networks.&lt;br /&gt;&lt;br /&gt;ZigBee protocols are intended for use in embedded applications requiring low data rates and low power consumption. ZigBee's current focus is to define a general-purpose, inexpensive, self-organizing mesh network that can be used for industrial control, embedded sensing, medical data collection, smoke and intruder warning, building automation, home automation, etc.&lt;br /&gt;&lt;br /&gt;PLC&lt;br /&gt;The PLC technology, which uses the electrical wiring of the house to transmit data, &lt;span style="color: black;"&gt;can be a complement to Wi-Fi then Exit barriers wall&lt;/span&gt;. In addition, &lt;span style="color: blue;"&gt;it allows either to extend the reach of its Wi-Fi or secure data. &lt;/span&gt;Indeed, with LPG, the problems of network security are easier to manage &lt;span style="color: blue;"&gt;because the electric meter acts as a filter&lt;/span&gt;. Moreover adapters often provide the encryption of data. The CPL boasts a range of &lt;span style="color: blue;"&gt;250 meter &lt;/span&gt;range and its implementation is very simple. Simply just plug the adapter into the outlet and connect it to the desired computer or your ISP's box by Ethernet cable.&lt;br /&gt;&lt;br /&gt;After you have nothing to do, after a few minutes, the computer receives the signal and you can easily connect to the Internet.In general, CPL Kits deliver a theoretical throughput of &lt;span style="color: blue;"&gt;200 Mbit / s.&lt;/span&gt; In reality, it takes on a rate of &lt;span style="color: blue;"&gt;40 Mbit /s&lt;/span&gt;. It is quite enough to surf broadband and receive images in High Definition. Moreover, these kits allow CPL set priorities for use.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7271319297560305423?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7271319297560305423/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7271319297560305423' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7271319297560305423'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7271319297560305423'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/02/comparison-of-wireless-communication.html' title='Comparison of wireless communication'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-1059457983862808044</id><published>2011-01-31T17:50:00.001-08:00</published><updated>2011-11-26T19:24:34.576-08:00</updated><title type='text'>JSON</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;JSON (JavaScript Object Notation) is a lightweight data-interchange format. It is easy for humans to read and write. It is easy for machines to parse and generate.&lt;br /&gt;&lt;br /&gt;JSON is built on two structures:&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; * A collection of name/value pairs. In various languages, this is realized as an object, record, struct, dictionary, hash table, keyed list, or associative array.&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; * An ordered list of values. In most languages, this is realized as an array, vector, list, or sequence.&lt;/div&gt;&lt;pre class='brush: js'&gt;&lt;br /&gt;{&lt;br /&gt;     "firstName": "John",&lt;br /&gt;     "lastName" : "Smith",&lt;br /&gt;     "age"      : 25,&lt;br /&gt;     "address"  :&lt;br /&gt;     {&lt;br /&gt;         "streetAddress": "21 2nd Street",&lt;br /&gt;         "city"         : "New York",&lt;br /&gt;         "state"        : "NY",&lt;br /&gt;         "postalCode"   : "10021"&lt;br /&gt;     },&lt;br /&gt;     "phoneNumber":&lt;br /&gt;     [&lt;br /&gt;         {&lt;br /&gt;           "type"  : "home",&lt;br /&gt;           "number": "212 555-1234"&lt;br /&gt;         },&lt;br /&gt;         {&lt;br /&gt;           "type"  : "fax",&lt;br /&gt;           "number": "646 555-4567"&lt;br /&gt;         }&lt;br /&gt;     ]&lt;br /&gt; }&lt;br /&gt;&lt;/pre&gt;Since JSON is a subset of JavaScript, it is possible (but not recommended) to parse JSON text into an object by invoking JavaScript's eval() function. For example, if the above JSON data is contained within a JavaScript string variable contact, one could use it to create the JavaScript object p like so:&lt;pre class='brush: js'&gt;&lt;br /&gt;var p = eval("(" + contact + ")");&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-1059457983862808044?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/1059457983862808044/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=1059457983862808044' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1059457983862808044'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1059457983862808044'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/01/json.html' title='JSON'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-536700239768809886</id><published>2011-01-27T00:23:00.000-08:00</published><updated>2011-12-19T05:48:08.438-08:00</updated><title type='text'>HTTPS</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Are https URLs encrypted?&lt;br /&gt;&lt;br /&gt;HTTPS Establishes an underlying SSL conenction before any HTTP data is transferred. This ensures that all URL data (with the exception of hostname, which is used to establish the connection) is carried solely within this encrypted connection and is protected from man-in-the-middle attacks in the same way that any HTTPS data is.&lt;br /&gt;&lt;br /&gt;From the outside the only data that is visible to the world it the hostname and port you are connecting to. Everything else is simply a stream of binary data which is enctypted using a private key shared only between you and the server.&lt;br /&gt;&lt;br /&gt;So yes. The data contained in the URL query on an HTTPS connection is encrypted. However it is very poor practice to include such sensitive data as a password in the a 'GET' request. While it cannot be intercepted, the data would be &lt;span style="color: blue;"&gt;logged in plaintext serverlogs on the receiving HTTPS server&lt;/span&gt;, and quite possibly also &lt;span style="color: blue;"&gt;in browser history.&lt;/span&gt; It is probably also available to &lt;span style="color: blue;"&gt;browser plugins&lt;/span&gt; and possibly even other applications on the client computer. At most an HTTPS URL could be reasonably allowed to include a session ID or similar non-reusable variable. &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-536700239768809886?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/536700239768809886/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=536700239768809886' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/536700239768809886'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/536700239768809886'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/01/https.html' title='HTTPS'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-22522130534775771</id><published>2011-01-17T23:20:00.000-08:00</published><updated>2011-07-28T05:52:49.432-07:00</updated><title type='text'>REST</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Representational state transfer (REST) is a style of software architecture for distributed hypermedia systems such as the World Wide Web.&lt;br /&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;It is possible to claim an enormous number of RESTful applications on the Web (just about everything accessible through an HTTP GET request or updateable through HTTP POST)&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Various websites and web applications offer REST-like developer interfaces to data (e.g. Flickr or Amazon S3).&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;REST uses HTTP for all four&lt;span class="Apple-style-span" style="color: blue;"&gt; CRUD (Create/Read/Update/Delete) &lt;/span&gt;operations.&lt;br /&gt;&lt;br /&gt;As a rule, GET requests should be for read-only queries; they should not change the state of the server and its data. For creation, updating, and deleting data, use POST requests. (POST can also be used for read-only queries, as noted above, when complex parameters are required.)&lt;br /&gt;&lt;br /&gt;While REST services might use XML in their responses (as one way of organizing structured data), &lt;span class="Apple-style-span" style="color: blue;"&gt;REST requests rarely use XML. &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;As shown above, in most cases, request parameters are simple, and there is no need for the overhead of XML.&lt;br /&gt;&lt;br /&gt;More precisely, a Web service is a Web page that’s meant to be consumed by an autonomous program as opposed to a Web browser or similar UI tool&lt;br /&gt;&lt;br /&gt;Resources are identified by uniform resource identifiers (URIs)&lt;br /&gt;Messages are self-descriptive and stateless&lt;br /&gt;&lt;br /&gt;A Web-based application is a dynamically changing graph of&lt;br /&gt;– state representations (pages)&lt;br /&gt;– potential transitions (links) between states&lt;br /&gt;&lt;br /&gt;There are no applications you can think of which cannot be made to fit into the GET / PUT / POST /DELETE resources / representations model of the world!&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;Multiple POSTs&lt;/span&gt; of the same data must be made harmless&lt;br /&gt;Put some kind of message ID in a header or in the message body&lt;br /&gt;&lt;br /&gt;“POST lets you pass a whole lot of parameters and get something back, bypassing caches.”&lt;br /&gt;&lt;br /&gt;It is a common convention in REST design to use &lt;span class="Apple-style-span" style="color: blue;"&gt;nouns rather than verbs&lt;/span&gt; to denote simple resources.&lt;br /&gt;As a rule, GET requests should be for &lt;span class="Apple-style-span" style="color: blue;"&gt;read-only queries&lt;/span&gt;; they should not change the state of the server and its data. For creation, updating, and deleting data, use POST requests. (POST can also be used for read-only queries, as noted above, when complex parameters are required.)&lt;br /&gt;&lt;br /&gt;One advantage of using XML is type safety. However, in a stateless system like REST, you should always verify the validity of your input, XML or otherwise!&lt;br /&gt;&lt;br /&gt;A server response in REST is often an XML file. However, other formats can also be used; unlike SOAP services, REST is not bound to XML in any way. Possible formats include CSV (comma-separated values) and JSON (JavaScript Object Notation).&lt;br /&gt;Each format has its own advantages and disadvantages. XML is easy to expand (clients should ignore unfamiliar fields) and is type-safe; CSV is more compact; and JSON is trivial to parse in JavaScript clients (and easy to parse in other languages, too).&lt;br /&gt;&lt;br /&gt;One option is not acceptable as a REST response format, except in very specific cases: HTML, or any other format which is meant for human consumption and is not easily processed by clients.&amp;nbsp; &lt;br /&gt;&lt;a href="http://rest.elkstein.org/"&gt;http://rest.elkstein.org/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;REST 5&amp;nbsp;principles:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;ul style="text-align: left;"&gt;&lt;li&gt;Give every “thing” an ID&lt;/li&gt;&lt;li&gt;Link things together&lt;/li&gt;&lt;li&gt;Use standard methods&lt;/li&gt;&lt;li&gt;Resources with multiple representations&lt;/li&gt;&lt;li&gt;Communicate statelessly&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&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/5277669399194798662-22522130534775771?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/22522130534775771/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=22522130534775771' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/22522130534775771'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/22522130534775771'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2011/01/rest.html' title='REST'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7667520382338008458</id><published>2010-12-08T00:26:00.001-08:00</published><updated>2011-01-17T23:11:35.611-08:00</updated><title type='text'>Architecture review</title><content type='html'>&lt;b&gt;A Swing Architecture Overview &lt;/b&gt;&lt;br /&gt;http://java.sun.com/products/jfc/tsc/articles/architecture/&lt;br /&gt;It is generally considered good practice to center the architecture of an application around its data rather than around its user interface.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7667520382338008458?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7667520382338008458/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7667520382338008458' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7667520382338008458'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7667520382338008458'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/12/architecture-review.html' title='Architecture review'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2678634702136989041</id><published>2010-10-19T23:11:00.001-07:00</published><updated>2010-10-19T23:11:36.470-07:00</updated><title type='text'>QT</title><content type='html'>http://blog.csdn.net/huihui1988/archive/2010/09/12/5879211.aspx&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-2678634702136989041?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2678634702136989041/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2678634702136989041' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2678634702136989041'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2678634702136989041'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/10/qt.html' title='QT'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4066716613191069757</id><published>2010-10-19T19:07:00.000-07:00</published><updated>2011-05-23T19:50:30.025-07:00</updated><title type='text'>Linux Programming</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;b&gt;CMake&lt;/b&gt; is used to control the software compilation process using simple  platform and compiler independent configuration files. CMake generates  native makefiles and workspaces that can be used in the compiler  environment of your choice.&lt;br /&gt;&lt;br /&gt;A &lt;b&gt;cross compiler&lt;/b&gt; is a compiler capable of creating executable code for a platform other than the one on which the compiler is run. Cross compiler tools are used to generate executables for embedded system or multiple platforms. It is used to compile for a platform upon which it is not feasible to do the compiling, like microcontrollers that don't support an operating system.&lt;br /&gt;&lt;br /&gt;Compiling&lt;br /&gt;-fPIC:&amp;nbsp;Position Independent Code&lt;br /&gt;&lt;br /&gt;How to create a shared library.&lt;br /&gt;&lt;a href="http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html"&gt;http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;Error:&lt;br /&gt;1. linker error - linker input file unused&lt;br /&gt;When you use -c flag, i.e. no linking is done, the input is C++ code, and the output is object code. The .o files thus don't mix with -c, and compiler warns you about that.&lt;br /&gt;&lt;pre class="brush: java;"&gt;PROG ?= myprog&lt;br /&gt;OBJS = worker.o main.o&lt;br /&gt;&lt;br /&gt;all: $(PROG)&lt;br /&gt;&lt;br /&gt;.cpp.o:&lt;br /&gt;        g++ -Wall -pedantic -ggdb -O2 -c -o $@ $&lt;&lt;br /&gt;&lt;br /&gt;$(PROG): $(OBJS)&lt;br /&gt;        g++ -Wall -pedantic -ggdb -O2 -o $@ $(OBJS)&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4066716613191069757?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4066716613191069757/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4066716613191069757' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4066716613191069757'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4066716613191069757'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/10/linux-programming.html' title='Linux Programming'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5805776034096225613</id><published>2010-10-17T20:19:00.000-07:00</published><updated>2010-11-18T19:27:16.016-08:00</updated><title type='text'>USB Programming</title><content type='html'>USB connects several devices to a host controller through a chain of hubs. In USB terminology, devices are referred to as functions, because each individual physical device may actually host several functions.These devices/functions (and hubs) have associated pipes (logical channels). The pipes are synonymous to byte streams such as in the pipelines of Unix. Pipes are connections from the host controller to a logical entity on the device named an endpoint.These endpoints (and their respective pipes) are numbered 0-15 in each direction, so a device/function can have up to 32 active pipes, 16 into the host controller and 16 out of the controller.Each endpoint can transfer data in one direction only, either into or out of the device/function, so each pipe is uni-directional. &lt;br /&gt;&lt;br /&gt;The pipes are also divided into four different categories by way of their transfer type:&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; * control transfers - typically used for short, simple commands to the device, and a status response, used e.g. by the bus control pipe number 0&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; * isochronous transfers - at some guaranteed speed (often but not necessarily as fast as possible) but with possible data loss, e.g. realtime audio or video&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; * interrupt transfers - devices that need guaranteed quick responses (bounded latency), e.g. pointing devices and keyboards&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; * bulk transfers - large sporadic transfers using all remaining available bandwidth (but with no guarantees on throughput or latency), e.g. file transfers&lt;br /&gt;&lt;br /&gt;The device descriptor of a USB device has a signature that tells what kind of device has been attached to the bus. This signature consists of class code, subclass code and protocol fields. Together, these identify what operating system driver should be used to communicate with the device.&lt;br /&gt;&lt;br /&gt;Devices that attach to the bus can be full-custom devices requiring a full-custom device driver to be used, or may belong to a device class. These classes define an expected behavior in terms of device and interface descriptors so that the same device driver may be used for any device that claims to be a member of a certain class.&lt;br /&gt;&lt;br /&gt;Reference:&lt;br /&gt;http://blog.163.com/lyzaily@126/blog/static/4243883720096101044126/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5805776034096225613?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5805776034096225613/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5805776034096225613' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5805776034096225613'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5805776034096225613'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/10/usb-programming.html' title='USB Programming'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8747670899865879026</id><published>2010-07-26T01:49:00.000-07:00</published><updated>2010-07-26T02:52:41.197-07:00</updated><title type='text'>Mobile widget</title><content type='html'>&lt;h3 id="deploy"&gt;&lt;a href="http://dev.opera.com/articles/view/creating-your-first-opera-widget/"&gt;Opera Widget&lt;/a&gt;&lt;/h3&gt;&lt;h3 id="what"&gt;What are widgets?&lt;/h3&gt;Widgets are Web applications running on your desktop. They are  implemented using client-side Web technologies, and creating one is very  much like creating a Web page, except that it is run in a slightly  different context.&lt;br /&gt;Opera browsers can install and open these widgets, showing them  directly on the user’s desktop (or equivalent in other devices). Widgets  are native applications created with web standards, which can integrate  nicely with your computer or device.&lt;br /&gt;&lt;h3 id="packaging"&gt;Packaging widgets&lt;/h3&gt;Opera Widgets are packaged as regular zip files, renamed to use the extension &lt;code&gt;.wgt&lt;/code&gt;.  All the files related to your widget should be stored inside the widget  file. A typical widget contains the following elements:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;A widget configuration file — &lt;code&gt;config.xml&lt;/code&gt;. This is an  XML file in the root of the widget structure that holds information  about your widget including its size, name, author, and security  information.&lt;/li&gt;&lt;li&gt;An index document — &lt;code&gt;index.html&lt;/code&gt;. Like on a Web page,  this document contains the basic skeleton/content of the widget. Widgets  content can be created using any markup that Opera handles natively,  for example HTML, SVG, or XML files. This file also lives in the root of  the widget structure.&lt;/li&gt;&lt;li&gt;Images. These are contained in a single images folder.&lt;/li&gt;&lt;li&gt;JavaScript files. These are contained in a single script folder.&lt;/li&gt;&lt;li&gt;Style sheets. These are contained in a single style folder.&lt;/li&gt;&lt;/ul&gt;&lt;span style="font-size: large;"&gt;&lt;b&gt;BlackBerry Widget&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;BlackBerry Widgets are small, discrete, standalone web applications that use HTML, CSS and JavaScript®. They look, behave and have the same security mechanisms as a native BlackBerry smartphone application. BlackBerry Widgets can be installed on a BlackBerry smartphone like any native BlackBerry smartphone application and extended to use device-specific information and data with BlackBerry Widget APIs.&lt;br /&gt;&lt;span style="font-size: large;"&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-size: large;"&gt;&lt;b&gt;Android Widget&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;App Widgets are miniature application views that can be embedded in other applications (such as the Home screen) and receive periodic updates. These views are referred to as Widgets in the user interface, and you can publish one with an App Widget provider. An application component that is able to hold other App Widgets is called an App Widget host. The screenshot below shows the Music App Widget.&lt;br /&gt;&lt;ul&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8747670899865879026?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8747670899865879026/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8747670899865879026' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8747670899865879026'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8747670899865879026'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/07/mobile-widget.html' title='Mobile widget'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-26342222558567572</id><published>2010-07-22T17:45:00.001-07:00</published><updated>2011-04-26T19:45:49.407-07:00</updated><title type='text'>Qt</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Qt is a cross-platform application development framework widely used for the development of GUI programs (in which case it is known as a widget toolkit), and also used for developing non-GUI programs such as console tools and servers. It is produced by Nokia's Qt Development Frameworks division. Non-GUI features include SQL database access, XML parsing, thread management, network support, and a unified cross-platform API for file handling.&lt;br /&gt;Qt can also be used in several other programming languages via language bindings, such as java.&lt;br /&gt;&lt;br /&gt;This connect() call establishes a one-way connection between two Qt objects. Every Qt object can have both signals (to send messages) and slots (to receive messages).&lt;br /&gt;&lt;br /&gt;Older toolkits achieve this kind of communication using callbacks. A callback is a pointer to a function, so if you want a processing function to notify you about some event you pass a pointer to another function (the callback) to the processing function. The processing function then calls the callback when appropriate. Callbacks have two fundamental flaws: Firstly, they are not type-safe. We can never be certain that the processing function will call the callback with the correct arguments. Secondly, the callback is strongly coupled to the processing function since the processing function must know which callback to call.&lt;br /&gt;&lt;br /&gt;The signals and slots mechanism is type safe: The signature of a signal must match the signature of the receiving slot. (In fact a slot may have a shorter signature than the signal it receives because it can ignore extra arguments.) Since the signatures are compatible, the compiler can help us detect type mismatches. Signals and slots are loosely coupled: A class which emits a signal neither knows nor cares which slots receive the signal. Qt's signals and slots mechanism ensures that if you connect a signal to a slot, the slot will be called with the signal's parameters at the right time. Signals and slots can take any number of arguments of any type. They are completely type safe.&lt;br /&gt;&lt;br /&gt;All classes that contain signals or slots must mention Q_OBJECT at the top of their declaration. They must also derive (directly or indirectly) from QObject.&lt;br /&gt;&lt;br /&gt;Qt Quick has been released with Qt 4.7. Companies use it to build user interfaces (UIs) for set-top boxes, tablet devices, in-vehicle infotainment systems, e-readers or mobile phones. It provides a declarative language QML (Qt Meta-object Language) for designing and implementing UIs. QML is based on CSS and JavaScript.&lt;br /&gt;&lt;div&gt;&lt;br /&gt;QBENCHMARK: Test the overhead of a function.&amp;nbsp;&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/5277669399194798662-26342222558567572?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/26342222558567572/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=26342222558567572' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/26342222558567572'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/26342222558567572'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/07/qt.html' title='Qt'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-6810033307499886146</id><published>2010-06-27T19:31:00.001-07:00</published><updated>2010-12-09T17:08:18.731-08:00</updated><title type='text'>Java Advanced Topic</title><content type='html'>Java Reflection API&lt;br /&gt;&lt;br /&gt;Inner class&lt;br /&gt;Inner class has access to any and all methods and members, even the parent's this reference. The advantages of inner classes can be divided into three categories: an object-oriented advantage, an organizational advantage, and a call-back advantage.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-6810033307499886146?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/6810033307499886146/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=6810033307499886146' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6810033307499886146'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6810033307499886146'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/06/java-reflection-api.html' title='Java Advanced Topic'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7840168764400614525</id><published>2010-05-18T18:55:00.001-07:00</published><updated>2010-05-20T18:14:27.410-07:00</updated><title type='text'>JavaFX</title><content type='html'>JavaFX is a Java platform for creating and delivering rich Internet applications that can run across a wide variety of connected devices. The current release (JavaFX 1.3, April 2010) enables building applications for desktop, browser and mobile phones. TV set-top boxes, gaming consoles, Blu-ray players and other platforms are planned.&lt;br /&gt;&lt;br /&gt;JavaFX builds on Java technology. To build JavaFX apps developers use a statically typed, declarative language called JavaFX Script; Java code can be integrated into JavaFX programs. JavaFX is compiled to Java bytecode, so JavaFX applications run on any desktop and browser that runs the Java Runtime Environment (JRE) and on top of mobile phones running Java ME.&lt;br /&gt;&lt;br /&gt;JBed CDC&lt;br /&gt;&lt;br /&gt;IBM J9&lt;br /&gt;&lt;br /&gt;Midlet Manager&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7840168764400614525?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7840168764400614525/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7840168764400614525' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7840168764400614525'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7840168764400614525'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/05/javafx.html' title='JavaFX'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8904112117911040135</id><published>2010-05-03T19:29:00.000-07:00</published><updated>2010-05-03T19:29:58.359-07:00</updated><title type='text'>Digital Identity</title><content type='html'>Information Card&lt;br /&gt;&lt;br /&gt;SAML&lt;br /&gt;&lt;br /&gt;OpenID&lt;br /&gt;&lt;br /&gt;OAuth&lt;br /&gt;&lt;br /&gt;XDI&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8904112117911040135?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8904112117911040135/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8904112117911040135' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8904112117911040135'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8904112117911040135'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/05/digital-identity.html' title='Digital Identity'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7347623145416851424</id><published>2010-04-27T23:23:00.000-07:00</published><updated>2011-01-25T21:44:30.891-08:00</updated><title type='text'>Bluetooth</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Every Bluetooth device is assigned a unique Bluetooth address, being a 48-bit hardware address equivalent to hardware addresses assigned to regular Network Interface Cards (NICs).&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://2.bp.blogspot.com/_f78nkN5Nz_M/S9jag23kcQI/AAAAAAAAAKM/LUYF-AUjFCg/s1600/Bluetooth.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="302" src="http://2.bp.blogspot.com/_f78nkN5Nz_M/S9jag23kcQI/AAAAAAAAAKM/LUYF-AUjFCg/s400/Bluetooth.JPG" tt="true" width="400" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;Two types of physical links are defined in version 1.1 of the Bluetooth specification, Synchronous Connection Oriented (SCO) links and Asynchronous ConnectionLess (ACL) links. &lt;br /&gt;&lt;br /&gt;SCO links are intended for audio transmission. When setting up a SCO link time slots are reserved for transmission of data, thus providing a Quality of Service (QoS) guarantee. Lost or erroneous packages are not re-transmitted which makes sense for voice transmissions.&lt;br /&gt;&lt;br /&gt;ACL links are intended for data communication. An ACL link provides &lt;span style="color: blue;"&gt;error-free&lt;/span&gt; transmission of data which means that lost or erronous packets are&lt;span style="color: blue;"&gt; re-transmitted&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;L2CAP provides multiplexing between different higher layer protocols over a single physical ACL link, enabling several logical data links to be set up between two Bluetooth devices. An ACL packet can have a maximum of 339 bytes of payload data, while an L2CAP packet can have a maximum of 65,535 bytes of payload data.&lt;br /&gt;&lt;br /&gt;The RFCOMM layer emulates RS-232 serial ports and serial data streams. RFCOMM relies on L2CAP for multiplexing multiple concurrent data streams and handling connections to multiple devices. The majority of Bluetooth profiles make use of the RFCOMM protocol because of its ease of use compared to direct interaction with the L2CAP layer.&lt;br /&gt;&lt;br /&gt;The Bluetooth Specification refers to the device discovery operation as inquiry. During the inquiry process the inquiring Bluetooth device will receive the Bluetooth address and clock from nearby discoverable devices.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Different Bluetooth devices offer different sets of services. Hence, a Bluetooth device needs to do a service discovery on a remote device in order to obtain information about available services. Service searches can be of a general nature by polling a device for all available services, but can also be narrowed down to find just a single service.&lt;br /&gt;&lt;br /&gt;The Universally Unique IDentifier (UUID), is the data type used for identifying services, protocols and profiles etc. A UUID is a 128-bit identifier that is guaranteed to be unique across all time and space.&lt;br /&gt;&lt;br /&gt;Bonding is the procedure of a Bluetooth device authenticating another Bluetooth device, and is dependent on a shared authentication key. If the devices do not share an authentication key, a new key must be created before the bonding process can complete. Generation of the authentication key is called pairing. The pairing process involves generation of an initialization key and an authentication key, followed by mutual authentication.&lt;br /&gt;&lt;br /&gt;The authentication key is based on random numbers and Bluetooth addresses from both devices.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Storing the authentication key is useful for devices frequently connecting to each other, such as a laptop computer frequently connecting to the dial-up networking service on a cellphone. The bonding procedure can then complete without user input and the user is relieved of figuring out a new passkey every time he or she wants to connect to the Internet.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7347623145416851424?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7347623145416851424/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7347623145416851424' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7347623145416851424'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7347623145416851424'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/04/bluetooth.html' title='Bluetooth'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_f78nkN5Nz_M/S9jag23kcQI/AAAAAAAAAKM/LUYF-AUjFCg/s72-c/Bluetooth.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5277669399194798662.post-8156630216643249666</id><published>2010-04-27T00:50:00.000-07:00</published><updated>2010-04-27T00:50:02.850-07:00</updated><title type='text'>Paypal</title><content type='html'>在支付完在之后，支付台平都会去调用你的IPN，其实大部分的开发者就是不了解IPN的意义，IPN是一个实时通知程序，支付平台在支付完成以后会通知你的网站，支付已经完成，如果完全利用一般IE的重定向来通知，用户可能在支付完成以后，立即关闭IE，这样就可能导致数据没有更新，而使用IPN就不会，就算服务器中断，支付平台也会不断的发请求，直到你的服务器回送处理完成为止。&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8156630216643249666?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8156630216643249666/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8156630216643249666' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8156630216643249666'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8156630216643249666'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/04/paypal.html' title='Paypal'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-6944935133929264374</id><published>2010-04-12T19:32:00.000-07:00</published><updated>2010-04-24T19:48:55.145-07:00</updated><title type='text'>Install Perl</title><content type='html'>Bugzilla Installation steps:&lt;br /&gt;http://www.bugzilla.org/docs/tip/en/html/installation.html&lt;br /&gt;&lt;a href="https://wiki.mozilla.org/Bugzilla:Win32Install#Install_2"&gt;https://wiki.mozilla.org/Bugzilla:Win32Install#Install_2&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Install Perl module:&lt;br /&gt;build:&lt;br /&gt;perl Makefile.PL&lt;br /&gt;make&lt;br /&gt;make test&lt;br /&gt;install&lt;br /&gt;make install&lt;br /&gt;&lt;br /&gt;Config WebServer&lt;br /&gt;/etc/httpd/conf/httpd.conf&lt;br /&gt;&lt;br /&gt;/usr/sbin/apachectl start&lt;br /&gt;/usr/sbin/apachectl stop&lt;br /&gt;/usr/sbin/apachectl restart&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;FAQ&lt;br /&gt;&lt;em&gt;"Error installing package 'DBI': Could not &amp;gt; locate a PPD file for package DBI" &lt;/em&gt;&lt;br /&gt;You may be behind a proxy/firewall. If so, &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;at the command prompt&lt;br /&gt;SET HTTP_proxy=http://myproxy&lt;br /&gt;&lt;em&gt;&lt;br /&gt;&lt;/em&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-6944935133929264374?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/6944935133929264374/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=6944935133929264374' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6944935133929264374'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6944935133929264374'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/04/install-perl.html' title='Install Perl'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-391290157572360638</id><published>2010-04-06T23:29:00.000-07:00</published><updated>2010-04-06T23:29:06.659-07:00</updated><title type='text'>LDAP</title><content type='html'>The Lightweight Directory Access Protocol, or LDAP, is an application protocol for querying and modifying data using directory services running over TCP/IP. A directory is a set of objects with attributes organized in a logical and hierarchical manner. A simple example is the telephone directory, which consists of a list of names (of either persons or organizations) organized alphabetically, with each name having an address and phone number associated with it.&lt;br /&gt;&lt;br /&gt;A client starts an LDAP session by connecting to an LDAP server, called a Directory System Agent (DSA), by default on TCP port 389. The client then sends an operation request to the server, and the server sends responses in return.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-391290157572360638?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/391290157572360638/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=391290157572360638' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/391290157572360638'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/391290157572360638'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/04/ldap.html' title='LDAP'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-3447527695380125167</id><published>2010-04-06T02:57:00.000-07:00</published><updated>2010-12-29T23:51:16.823-08:00</updated><title type='text'>J2ME</title><content type='html'>Basically there are two types of configurations involved in Java ME application development, which are: &lt;br /&gt;&lt;br /&gt;CLDC (Connected Limited Device Configuration) &lt;br /&gt;CDC (Connected Device Configuration) &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://4.bp.blogspot.com/_f78nkN5Nz_M/S9fWja3TQNI/AAAAAAAAAKI/dlwr-sRwgeY/s1600/J2ME.JPG" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="268" src="http://4.bp.blogspot.com/_f78nkN5Nz_M/S9fWja3TQNI/AAAAAAAAAKI/dlwr-sRwgeY/s320/J2ME.JPG" tt="true" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;Architecture The Java ME Architecture comprises of three software layers: &lt;br /&gt;The first layer is the configuration layer that includes the JVM, which directly interacts with the native OS. The Configuration layer also handles the interaction between the profile and the JVM.&lt;br /&gt;&lt;br /&gt;The second layer is the profile layer, which consists of the minimum set of application programming interface (API) for the small devices.&lt;br /&gt;&lt;br /&gt;The main goal of the CLDC Specification is to standardize a highly portable minimum-footprint Java application development platform for resource-constrained, connected devices. CLDC defines a minimal subset of functionality from the J2SE platform. Hence, the CLDC does not define device-specific functionality.&lt;br /&gt;&lt;br /&gt;In CLDC, GUI-libraries and the java.net library are unavailable. All packages are subsets of the corresponding packages from J2SE, except the javax.microedition.io package which is introduced in the CDLC. Java.io provides basic input and output streams, but not file streams or other libraries for persistent storage. Note that user interface, networking support and persistent storage are addressed by the MIDP.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The third layer is the Mobile Information Device profile (MIDP) layer. The MIDP layer contains java APIs for user network connections, persistence storage, and the user interface. It also has access to CLDC libraries and MIDP libraries. &lt;br /&gt;&lt;br /&gt;MIDP 2.0 adds support for HTTPS, datagram, sockets, server sockets and serial port communication.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Push architecture is introduced in MIDP 2.0. This makes it possible to activate a MIDlet when the device receives information from a server. Hence, developers may develop event driven applications utilizing carrier networks. An example of this could be a SMS MIDlet, which would be activated when a new incoming SMS arrived at the device.&lt;br /&gt;&lt;br /&gt;End-to-end security is provided by HTTPS and SSL/TLS protocol access over the IP (Internet Protocol) network. The ability to set up secure connections is a leap forward for MIDP programming. A wide range of application models require encryption of data and may now utilize the security model of MIDP 2.0 based on open standards.&lt;br /&gt;&lt;br /&gt;MIDlets are usually available through MIDlet suites. A MIDlet suite consists of two files, a .jar and a .jad file. The Java ARchive (JAR) file contains compiled classes in a compressed and preverified format. The Java Application Descriptor (JAD) file is a plain text file containing information about a MIDlet suite. The MID will always download the JAD file first and inspect its contents. If the MIDlet suite is already installed, it will know if a newer version is available.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;A MIDlet lifecycle have following steps...&lt;br /&gt;startApp() &lt;br /&gt;pauseApp() &lt;br /&gt;destroyApp() &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style="margin: 0px;"&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;CLDC（Connected limited device configuration，有限连接设备配置）：这个配置定义了 Java应用程序接口以及支持手持设备的技术&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;MIDP（Mobile information devices profile，移动信息设备简表）：第一个实现的简表，补充了CLDC并且提供应用程序语义和控件、用户界面、持久存储器、网络和用于移动电话的计时器、双通道呼叫器和其他无线电设备。类似于J2SE中的Applet框架，它提供了基于javax、microedition、midlet包的MIDLet应用程序框架。&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;MIDLet：MIDP应用程序称为 MIDlet，为了创建一个MIDlet，就必须写一个扩展基本 MIDlet类的类。这有点类似常见的Applet或Servlet。MIDlets独有的东西是把多个MIDlet组成一个MIDlet套件的能力。这就允许MIDlet在一个单独的JVM环境中共享资源，比如一个数据库等等。&lt;/div&gt;&lt;br /&gt;&lt;div style="margin: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;JADs and JARs&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;The basic components of any MIDlet suite you will deliver are the Java Application Descriptor (JAD) file and the Java Archive (JAR) file. Together, these two items are the MIDlet suite. &lt;br /&gt;&lt;br /&gt;The JAD file, as the name implies, describes a MIDlet suite. The description includes the name of the MIDlet suite, the location and size of the JAR file, and the configuration and profile requirements. The file may also contain other attributes, defined by the Mobile Information Device Profile (MIDP), by the developer, or both. Attributes beginning with MIDlet- or MicroEdition- are reserved for use by the AMS. The JAD file syntax is similar to that of the java.util.Properties class found in the J2SE environment. &lt;br /&gt;&lt;br /&gt;A MIDlet suite on a device is identified by the attribute tuple (MIDlet-Name, MIDlet-Version, MIDlet-Vendor). The JAR file will be installed from the location MIDlet-Jar-URL. The size of the download must agree with the MIDlet-Jar-Size value. &lt;br /&gt;&lt;br /&gt;The JAR contains one or more MIDlets, specified in the JAD using the MIDlet-&lt;n&gt; attribute.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;jad是jar的描述文件。jad描述了jar的文件大小和位置。打开jad后，根据jad找到jar。 &lt;br /&gt;jad作用有很多。 例如，我可以不下载jar,先下载jad(jad很小),了解一些jar的基本信息后，在决定是否下载jar. &lt;br /&gt;jad里还可以存储一些key和value,在midlet运行的时候可能会用到。如果直接用jar运行，就得不到这些key和value.对于某些程序，就不能正常运行了。 &lt;br /&gt;JAVA游戏以及JAVA电子书都是由.JAD和.JAR两个文件组成的,其中.JAD属于说明文件,用来识别该JAVA程序是否匹配该型号手机以及手机读取时确定游戏容量(这就是为什么有时候有的游戏不能下载我们可以通过更改.JAD文件来使其可以下载的原因)而.JAR文件属于程序体文件,就是游戏本身了,所以呢,无论是下载JAVA电子书还是JAVA游戏,.JAD文件和.JAR文件都是必不可少的.&lt;br /&gt;&lt;br /&gt;从JAR安装的时候，默认的配置文件是jar中的.mf文件。&lt;br /&gt;如果从JAD安装，会优先使用JAD文件中的配置信息&lt;br /&gt;另外，签名的信息的话，默认都是写在JAD文件中的。&lt;br /&gt;如果没有JAD文件的话，那么你的Java程序就只能装在“应用程序”里面了。&lt;br /&gt;&lt;br /&gt;&lt;b&gt;JSR&lt;/b&gt;&lt;br /&gt;JSR(Java 规范请求)是指向JCP(Java Community Process)提出新增一个标准化技术规范的正式请求。任何人都可以提交JSR(Java 规范请求)，以向Java平台增添新的API和服务。JSR已成为Java界的一个重要标准。&lt;br /&gt;&lt;br /&gt;The JABWT specification defines an optional J2ME package for Bluetooth wireless technology. JABWT operates on top of the CLDC and is intended to extend the capabilities of profiles like the MIDP. JABWT use the GCF, defined in the CLDC specification, for Bluetooth communication.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Permission&lt;br /&gt;The MIDP 2.0 specification defines an open-ended system of permissions. To make any type of network connection, a MIDlet must have an appropriate permission. For example, a MIDlet that uses HTTP to talk to a server must have permission to open an HTTP connection. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Each permission has a unique name;Permission names are not the same as class names, although they look similar. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The two most widely used techniques for session tracking are cookies and URL rewriting. A cookie is a piece of data that a Web server sends to the client. This piece of data is stored by the client and used the next time the client makes a request from that server. But if cookies are disabled by the browser, or more importantly, if the browser itself does not support them (as is the case with most wireless devices), then cookies are not of much use. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The other technique for session tracking is URL rewriting. This technique is ideal for clients that do not support cookies or have cookies disabled. In this technique, the session information is encoded into URLs that the server generates. &lt;br /&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;br /&gt;&lt;b&gt;J2ME Web Services&lt;/b&gt;&lt;br /&gt;JSR 172, the J2ME Web Services API (WSA) extends the Java 2 Platform, Micro Edition to support web services. The API's two optional packages standardize two areas of functionality that are crucial to clients of web services: remote service invocation and XML parsing. &lt;br /&gt;To handle XML documents, the application can employ the JAXP subset API. To consume web services, it can use the JAX-RPC subset API, employing JSR 172 stubs and the runtime.&lt;/n&gt;&lt;br /&gt;&lt;n&gt;&lt;br /&gt;Debug&lt;br /&gt;&lt;i&gt;The exact same source code used with the WTK 2.5.2 builds and runs without a problem. But in SDK 3.0, it has the error message as [WARN] [rms ] javacall_file_open: _wopen failed.&lt;/i&gt;&lt;br /&gt;Select Device "DefaultCldcPhone1"; other as Default; Click Finish&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/n&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-3447527695380125167?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/3447527695380125167/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=3447527695380125167' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3447527695380125167'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3447527695380125167'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/04/j2me.html' title='J2ME'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_f78nkN5Nz_M/S9fWja3TQNI/AAAAAAAAAKI/dlwr-sRwgeY/s72-c/J2ME.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5277669399194798662.post-2168888214682082557</id><published>2010-03-29T23:56:00.000-07:00</published><updated>2010-12-10T00:00:48.165-08:00</updated><title type='text'>Database</title><content type='html'>&lt;b&gt;What are Views ?&lt;/b&gt;&lt;br /&gt;A view allows you to assign the result of a query to a new private table. This table is given the name used in your VIEW query.&lt;br /&gt;Although MySQL does not support views yet a sample SQL VIEW construct statement would look like:&lt;br /&gt;CREATE VIEW TESTVIEW AS SELECT * FROM names;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;What are Triggers ?&lt;/b&gt;&lt;br /&gt;A trigger is a pre-programmed notification that performs a set of actions that may be commonly required. Triggers can be programmed to execute certain actions before or after an event occurs. Triggers are very useful as they they increase efficiency and accuracy in performing operations on databases and also are increase productivity by reducing the time for application development. Triggers however do carry a price in terms of processing overhead.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;What are Procedures ?&lt;/b&gt;&lt;br /&gt;Like triggers, Procedures or 'Stored' Procedures are productivity enhancers. Suppose you needed to perform an action using a programming interface to the database in say PERL and ASP. If a programmed action could be stored at the database level, it's obvious that it has to be written only once and cam be called by any programming language interacting with the database.&lt;br /&gt;Procedures are executed using triggers.&lt;br /&gt;&lt;br /&gt;Join table&lt;br /&gt;&lt;br /&gt;embed sql&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Choosing a Primary Key: Natural or Surrogate?&lt;/b&gt;&lt;br /&gt;&lt;span style="font-size: x-small;"&gt;(http://www.agiledata.org/essays/keys.html )&lt;/span&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;br /&gt;Natural key.&amp;nbsp; A key that is formed of attributes that already exist in the real world.&amp;nbsp; For example, U.S. citizens are issued a Social Security Number (SSN)&lt;br /&gt;Surrogate key.&amp;nbsp; A key with no business meaning.&lt;br /&gt;1. Avoid “smart” keys.&amp;nbsp; A&amp;nbsp; “smart” key is one that contains one or more subparts which provide meaning. &lt;br /&gt;2. Consider assigning natural keys for simple “look up” tables. A “look up” table is one that is used to relate codes to detailed information. &lt;br /&gt;3. Natural keys don’t always work for “look up” tables.&lt;br /&gt;4. Your applications must still support “natural key searches”. &lt;br /&gt;5. Don't naturalize surrogate keys.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-2168888214682082557?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2168888214682082557/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2168888214682082557' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2168888214682082557'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2168888214682082557'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/tutorial-on-database-concepts-sql-using.html' title='Database'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8109858333394088068</id><published>2010-03-29T20:45:00.000-07:00</published><updated>2010-03-29T20:45:10.097-07:00</updated><title type='text'>Are You a Software Architect?</title><content type='html'>Some of the key factors that are often used to differentiate software architecture from software design and development include an increase in scale, an increase in the level of abstraction and an increase in the significance of making the right design decisions. Software architecture is all about having a holistic view and seeing the bigger picture to understand how the software system works as a whole.&lt;br /&gt;As the following diagram shows, the architecture definition part of the role can be broken down further into a number of different elements.&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://www.infoq.com/resource/articles/brown-are-you-a-software-architect/en/resources/role-definition.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="http://www.infoq.com/resource/articles/brown-are-you-a-software-architect/en/resources/role-definition.png" /&gt;&lt;/a&gt;&lt;/div&gt;It's the same story with architecture delivery too, where the software architecture role can vary depending on the level of engagement across the elements that contribute to a successful software project.&lt;br /&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://www.infoq.com/resource/articles/brown-are-you-a-software-architect/en/resources/role-delivery.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" src="http://www.infoq.com/resource/articles/brown-are-you-a-software-architect/en/resources/role-delivery.png" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8109858333394088068?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8109858333394088068/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8109858333394088068' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8109858333394088068'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8109858333394088068'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/are-you-software-architect.html' title='Are You a Software Architect?'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8271263009008231070</id><published>2010-03-24T23:08:00.001-07:00</published><updated>2010-03-24T23:08:50.348-07:00</updated><title type='text'>P2P Systems</title><content type='html'>Skype可以看作是一个叠加在互联网之上的网络。与以往MSN等IM工具最大的不同在于其除了用户登录，其余工作基本不依赖中央服务器。 Skype在穿透防火墙通讯时完全使用了Peer to Peer，而没用到中央服务器。每一个客户端都维护一个可以到达的主机列表（host cache，HC），包括其IP地址和端口号。&lt;br /&gt;&lt;br /&gt;Skype的节点有两种：客户端（ordinary node）和超级节点（super node，SN）。&lt;br /&gt;Skype采用了32kbps的语音编码以保证语音质量，其信令通过TCP传递，而语音数据则通过TCP和UDP进行传输，信令和语音数据使用不同的端口号。Skype能够向好友列表中的用户发送呼叫请求。为了保证信令传输的可靠性，信令始终是通过TCP进行的。如果双方都是在公众网中，有独立的公用IP，那么主叫用户和被叫用户通过challenge-response机制直接进行数据交换。如果有一方位于私有网络或者是防火墙之后，那么私有网络一方需要首先同公众网中的至少一个SN建立TCP链接，然后由SN进行数据转发。如果双方都位于私有网络中，那么双方的数据都需要SN进行转发。&lt;br /&gt;&lt;br /&gt;Skype的好友列表没有保存在服务器上，而是保存在本地的注册表中，并进行了加密。这就使得用户如果更换了另外一台电脑之后需要重新构建好友列表&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8271263009008231070?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8271263009008231070/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8271263009008231070' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8271263009008231070'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8271263009008231070'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/p2p-systems.html' title='P2P Systems'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4268060674548658491</id><published>2010-03-23T20:52:00.000-07:00</published><updated>2010-03-23T20:52:51.264-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Paper'/><title type='text'>A Survey of Peer-to-Peer Content Distribution Technologies</title><content type='html'>Although in their purest form peer-to-peer overlay networks are supposed to be totally decentralized, in practice this is not always true, and systems with various degrees of centralization are encountered.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Purely Decentralized Architectures&lt;/b&gt;.&lt;br /&gt;All nodes in the network perform exactly the same tasks, acting both as servers and clients, and there is no central coordination of their activities.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Partially Centralized Architectures.&amp;nbsp;&lt;/b&gt;&lt;br /&gt;The basis is the same as with purely decentralized systems. Some of the nodes, however,assume a more important role, acting as local central indexes for files shared by local peers. The way in which these supernodes are assigned their role by the network varies between different systems. It is important, however, to note that these supernodes do not constitute single points of failure for a peer-to-peer network, since they are dynamically assigned and, if they fail, the network will automatically take action to replace them with others.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Hybrid Decentralized Architectures.&amp;nbsp;&lt;/b&gt;&lt;br /&gt;In these systems, there is a central server facilitating the interaction between peers by maintaining directories of metadata, describing the shared files stored by the peer nodes.&amp;nbsp;Obviously, in these architectures, there is a single point of failure (the central server).&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Network Structure&lt;/b&gt;&lt;br /&gt;&lt;b&gt;Unstructured&lt;/b&gt;.&lt;br /&gt;The placement of content (files) is completely unrelated to the overlay topology. In an unstructured network, content typically needs to be located. Unstructured systems are generally more appropriate for accommodating highly-transient node populations.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Structured&lt;/b&gt;&lt;br /&gt;In structured networks, the overlay topology is tightly controlled and files (or pointers to them) are placed at precisely specified locations. These systems essentially provide a mapping between content (e.g. file identifier) and location (e.g. node address), in the form of a distributed routing table, so that queries can be efficiently routed to the node with the desired content. A disadvantage of structured systems is that it is hard to maintain the structure required for efficiently routing messages in the face of a very transient node population.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4268060674548658491?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4268060674548658491/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4268060674548658491' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4268060674548658491'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4268060674548658491'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/survey-of-peer-to-peer-content.html' title='A Survey of Peer-to-Peer Content Distribution Technologies'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4684630806439570797</id><published>2010-03-23T01:13:00.000-07:00</published><updated>2010-03-23T01:18:53.889-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Book'/><title type='text'>The Art of Unix Programming</title><content type='html'>Doug McIlroy, the inventor of Unix pipes and one of the founders of the Unix tradition, had this to say at&lt;br /&gt;the time:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Make each program do one thing well. To do a new job, build afresh rather than&amp;nbsp;complicate old programs by adding new features.&lt;/li&gt;&lt;li&gt;Expect the output of every program to become the input to another, as yet unknown,&amp;nbsp;program. Don't clutter output with extraneous information. Avoid stringently columnar or&amp;nbsp;binary input formats. Don't insist on interactive input.&lt;/li&gt;&lt;li&gt;Design and build software, even operating systems, to be tried early, ideally within&amp;nbsp;weeks. Don't hesitate to throw away the clumsy parts and rebuild them.&lt;/li&gt;&lt;li&gt;Use tools in preference to unskilled help to lighten a programming task, even if you&amp;nbsp;have to detour to build the tools and expect to throw some of them out after you've finished&amp;nbsp;using them.&lt;/li&gt;&lt;/ul&gt;Rob Pike, who became one of the great masters of C, offers a slightly different angle in Notes on C&lt;br /&gt;Programming:&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Rule 1. You can't tell where a program is going to spend its time. Bottlenecks occur in&amp;nbsp;surprising places, so don't try to second guess and put in a speed hack until you've proven&amp;nbsp;that's where the bottleneck is.&lt;/li&gt;&lt;li&gt;Rule 2. Measure. Don't tune for speed until you've measured, and even then don't unless&amp;nbsp;one part of the code overwhelms the rest.&lt;/li&gt;&lt;li&gt;Rule 3. Fancy algorithms are slow when n is small, and n is usually small. Fancy&amp;nbsp;algorithms have big constants. Until you know that n is frequently going to be big, don't&amp;nbsp;get fancy. (Even if n does get big, use Rule 2 first.)&lt;/li&gt;&lt;li&gt;Rule 4. Fancy algorithms are buggier than simple ones, and they're much harder to&amp;nbsp;implement. &lt;span class="Apple-style-span" style="color: blue;"&gt;Use simple algorithms as well as simple data structures.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Rule 5. Data dominates. If you've chosen the right data structures and organized things&amp;nbsp;well, the algorithms will almost always be self-evident. &lt;span class="Apple-style-span" style="color: blue;"&gt;Data structures, not algorithms, are&amp;nbsp;central to programming&lt;/span&gt;.&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;Unix philosophy:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Rule of Modularity: Write simple parts connected by clean interfaces.&lt;/li&gt;&lt;li&gt;Rule of Clarity: &lt;span class="Apple-style-span" style="color: blue;"&gt;Clarity is better than cleverness.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;Rule of Composition: Design programs to be connected to other programs.&lt;/li&gt;&lt;li&gt;Rule of Separation: Separate policy from mechanism; separate interfaces from engines.&lt;/li&gt;&lt;li&gt;Rule of Simplicity: Design for simplicity; add complexity only where you must.&lt;/li&gt;&lt;li&gt;Rule of Parsimony: Write a big program only when it is clear by demonstration that nothing else&amp;nbsp;will do.&lt;/li&gt;&lt;li&gt;Rule of Transparency: Design for visibility to make inspection and debugging easier.&lt;/li&gt;&lt;li&gt;Rule of Robustness: Robustness is the child of transparency and simplicity.&lt;/li&gt;&lt;li&gt;Rule of Representation: Fold knowledge into data so program logic can be stupid and robust.&lt;/li&gt;&lt;li&gt;Rule of Least Surprise: In interface design, always do the least surprising thing.&lt;/li&gt;&lt;li&gt;Rule of Silence: When a program has nothing surprising to say, it should say nothing.&lt;/li&gt;&lt;li&gt;Rule of Repair: When you must fail, fail noisily and as soon as possible.&lt;/li&gt;&lt;li&gt;Rule of Economy: Programmer time is expensive; conserve it in preference to machine time.&lt;/li&gt;&lt;li&gt;Rule of Generation: Avoid hand-hacking; write programs to write programs when you can.&lt;/li&gt;&lt;li&gt;Rule of Optimization: Prototype before polishing. Get it working before you optimize it.&lt;/li&gt;&lt;li&gt;Rule of Diversity: Distrust all claims for “one true way”.&lt;/li&gt;&lt;li&gt;Rule of Extensibility: Design for the future, because it will be here sooner than you think.&lt;/li&gt;&lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4684630806439570797?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4684630806439570797/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4684630806439570797' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4684630806439570797'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4684630806439570797'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/art-of-unix-programming.html' title='The Art of Unix Programming'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2207107718628591756</id><published>2010-03-17T23:34:00.000-07:00</published><updated>2011-05-22T18:17:44.945-07:00</updated><title type='text'>Google AppEngine</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;FAQ:&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: Helvetica, Arial, sans-serif; font-size: small;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h4 id="googledata" style="font-size: 14px; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.7em; position: relative; top: 0.4em; z-index: 5;"&gt;Can I use the Google Data API library on App Engine?&lt;/h4&gt;&lt;div&gt;&lt;br /&gt;&lt;br /&gt;Yes, the Google Data Java client library can be used in App Engine, but you need to set a configuration option to avoid a runtime permissions error. Add the following to your appengine-web.xml file:&lt;br /&gt;&lt;pre class="brush: xml;"&gt;&lt;system-properties&gt;&lt;br /&gt;  &lt;/system-properties&gt;&lt;/pre&gt;&lt;pre class="brush: xml;"&gt;&lt;system-properties&gt;Limitations:&lt;/system-properties&gt;&lt;/pre&gt;&lt;pre class="brush: xml;"&gt;&lt;system-properties&gt;&lt;a href="http://stackoverflow.com/questions/565963/hidden-limitations-of-google-app-engine"&gt;http://stackoverflow.com/questions/565963/hidden-limitations-of-google-app-engine&lt;/a&gt;&lt;/system-properties&gt;&lt;/pre&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/5277669399194798662-2207107718628591756?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2207107718628591756/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2207107718628591756' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2207107718628591756'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2207107718628591756'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/google-appengine.html' title='Google AppEngine'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5678569915997535264</id><published>2010-03-16T19:42:00.000-07:00</published><updated>2010-03-18T23:01:23.383-07:00</updated><title type='text'>JUnit</title><content type='html'>JUnit tests do not require human judgment to interpret, and it is easy to run many of them at the same time. When you need to test&amp;nbsp;something, here is what you do:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Annotate a method with @org.junit.Test&lt;/li&gt;&lt;li&gt;When you want to check a value, import org.junit.Assert.* statically, call assertTrue() and pass a boolean that is true if the test&amp;nbsp;succeeds&lt;/li&gt;&lt;/ul&gt;Tests need to run against the background of a known set of objects. This set of objects is called a test fixture.&lt;br /&gt;When you have a common fixture, here is what you do:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Add a field for each part of the fixture&lt;/li&gt;&lt;li&gt;Annotate a method with @org.junit.Before and initialize the variables in that method&lt;/li&gt;&lt;li&gt;Annotate a method with @org.junit.After to release any permanent resources you allocated in setUp&lt;/li&gt;&lt;/ul&gt;Verifying that code completes normally is only part of programming. Making sure the code behaves as expected in exceptional&amp;nbsp;situations is part of the craft of programming too. For example:&lt;br /&gt;&lt;pre class="brush: java;"&gt;new ArrayList&amp;lt; object&amp;gt;().get(0); &lt;br /&gt;&lt;/pre&gt;This code should throw an IndexOutOfBoundsException. The @Test annotation has an optional parameter "expected" that takes as values&amp;nbsp;subclasses of Throwable. If we wanted to verify that ArrayList throws the correct exception, we would write: &lt;br /&gt;&lt;pre class="brush: java;"&gt;@Test(expected= IndexOutOfBoundsException.class) public void empty() { &lt;br /&gt;new ArrayList&amp;lt; object&amp;gt;().get(0); &lt;br /&gt;} &lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5678569915997535264?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5678569915997535264/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5678569915997535264' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5678569915997535264'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5678569915997535264'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/junit.html' title='JUnit'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4026223654614440014</id><published>2010-03-16T19:20:00.000-07:00</published><updated>2010-03-18T23:13:45.466-07:00</updated><title type='text'>JDK 5</title><content type='html'>&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;&lt;b&gt;Generics&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;Generics provides a way for you to communicate the type of a collection to the compiler, so that it can be checked.&lt;br /&gt;&lt;br /&gt;Here is a simple example taken from the existing Collections tutorial:&lt;br /&gt;&lt;pre class="brush: java;"&gt;// Removes 4-letter words from c. Elements must be strings&lt;br /&gt;static void expurgate(Collection c) {&lt;br /&gt;    for (Iterator i = c.iterator(); i.hasNext(); )&lt;br /&gt;      if (((String) i.next()).length() == 4)&lt;br /&gt;        i.remove();&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;Here is the same example modified to use generics:&lt;br /&gt;&lt;pre class="brush: java;"&gt;// Removes the 4-letter words from c&lt;br /&gt;static void expurgate(Collection&lt;string&gt; c) {&lt;br /&gt;    for (Iterator&lt;string&gt; i = c.iterator(); i.hasNext(); )&lt;br /&gt;      if (i.next().length() == 4)&lt;br /&gt;        i.remove();&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;The For-Each Loop&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;Iterating over a collection is uglier than it needs to be. Consider the following method, which takes a collection of timer tasks and cancels them:&lt;br /&gt;&lt;pre class="brush: java;"&gt;void cancelAll(Collection&lt;timertask&gt; c) {&lt;br /&gt;    for (Iterator&lt;timertask&gt; i = c.iterator(); i.hasNext(); )&lt;br /&gt;        i.next().cancel();&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;The iterator is just clutter. Furthermore, it is an opportunity for error. The iterator variable occurs three times in each loop: that is two chances to get it wrong. The for-each construct gets rid of the clutter and the opportunity for error. Here is how the example looks with the for-each construct:&lt;br /&gt;&lt;pre class="brush: java;"&gt;void cancelAll(Collection&lt;timertask&gt; c) {&lt;br /&gt;    for (TimerTask t : c)&lt;br /&gt;        t.cancel();&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;When you see the colon (:) read it as “in.” The loop above reads as “for each TimerTask t in c.” &lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;&lt;b&gt;Enums&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;The new enum declaration defines a full-fledged class (dubbed an enum type). It allows you to add arbitrary methods and &lt;br /&gt;&lt;br /&gt;fields to an enum type, to implement arbitrary interfaces, and more. &lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;Varargs&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;In past releases, a method that took an arbitrary number of values required you to create an array and put the values into the array prior to invoking the method.&lt;br /&gt;&lt;pre class="brush: java;"&gt;public static String format(String pattern,&lt;br /&gt;                                Object... arguments);&lt;br /&gt;&lt;/pre&gt;The three periods after the final parameter's type indicate that the final argument may be passed as an array or as a sequence of arguments. Varargs can be used only in the final argument position. Given the new varargs declaration for MessageFormat.format, the above invocation may be replaced by the following shorter and sweeter invocation:&lt;br /&gt;&lt;pre class="brush: java;"&gt;String result = MessageFormat.format(&lt;br /&gt;    "At {1,time} on {1,date}, there was {2} on planet "&lt;br /&gt;    + "{0,number,integer}.",&lt;br /&gt;    7, new Date(), "a disturbance in the Force");&lt;br /&gt;&lt;/pre&gt;There is a strong synergy between autoboxing and varargs, which is illustrated in the following program using reflection(The printf Method):&lt;br /&gt;&lt;pre class="brush: java;"&gt;// Simple test framework&lt;br /&gt;public class Test {&lt;br /&gt;    public static void main(String[] args) {&lt;br /&gt;        int passed = 0;&lt;br /&gt;        int failed = 0;&lt;br /&gt;        for (String className : args) {&lt;br /&gt;            try {&lt;br /&gt;                Class c = Class.forName(className);&lt;br /&gt;                c.getMethod("test").invoke(c.newInstance());&lt;br /&gt;                passed++;&lt;br /&gt;            } catch (Exception ex) {&lt;br /&gt;                System.out.printf("%s failed: %s%n", className, ex);&lt;br /&gt;                failed++;&lt;br /&gt;            }&lt;br /&gt;        }&lt;br /&gt;        System.out.printf("passed=%d; failed=%d%n", passed, failed);&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;&lt;b&gt;Static import&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;A static import declaration enables programmers to refer to imported static members as if they were declared in the class that uses them—the class name and a dot (.) are not required to use an imported static member.&lt;br /&gt;&lt;pre class="brush: java;"&gt;import static java.lang.Math.*;&lt;br /&gt;public function test()&lt;br /&gt;{&lt;br /&gt;    cos(1.0);&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;Annotations&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;It would be more convenient and less error-prone if the information in these side files were maintained as annotations in the program itself. Annotations do not directly affect program semantics, but they do affect the way programs are treated by tools and libraries, which can in turn affect the semantics of the running program. Annotations can be read from source files, class files, or reflectively at run time.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4026223654614440014?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4026223654614440014/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4026223654614440014' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4026223654614440014'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4026223654614440014'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/jdk-5.html' title='JDK 5'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-835222611597783382</id><published>2010-03-05T01:07:00.000-08:00</published><updated>2010-03-05T01:33:27.504-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Book'/><title type='text'>97 Things Every Software Architect Should Know</title><content type='html'>Approach these events as conversations, not as confrontations.&lt;br /&gt;If you assume the best about people and treat this situation as an opportunity to ask question, you definitely learn more, and are less likely to put people on the defensive.&lt;br /&gt;&lt;br /&gt;If you start with a shared purpose, treat people "problems" as an opportunity to learn, and manage your own emotions, you'll not only become more effective, you'll also discover that you learn something every time.&lt;br /&gt;&lt;br /&gt;The key to effective communication is&amp;nbsp;clarity&amp;nbsp;and leadership.&lt;br /&gt;Being clear and concise in the way you communicate your ideas is vital to the success of any software project.&lt;br /&gt;Having the developers on your side creates a collaborative environment whereby decisions you make as an architect are validated.&lt;br /&gt;&lt;br /&gt;People need to appreciate that application architecture is the primary determinant of application performance and scalability rather than software brands or infrastructure "tuning".&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-835222611597783382?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/835222611597783382/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=835222611597783382' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/835222611597783382'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/835222611597783382'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/03/97-things-every-software-architect.html' title='97 Things Every Software Architect Should Know'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2654431964274008791</id><published>2010-02-25T18:24:00.000-08:00</published><updated>2011-02-23T17:42:18.839-08:00</updated><title type='text'>Mobile operating system</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;Android&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;The Android community primarily uses two SDKs. The most familiar one is the high-level Android SDK, which enables you to write application code in the Java™ language and commonly uses Eclipse for writing, testing, and debugging code. Another, less commonly known SDK is the Android kernel source, which is stored in what is known as a git repository.&lt;br /&gt;&lt;br /&gt;Every Android application runs in its own process, with its own instance of the Dalvik virtual machine. Dalvik has been written so that a device can run multiple VMs efficiently. The Dalvik VM executes files in the Dalvik Executable (.dex) format which is optimized for minimal memory footprint. The VM is register-based, and runs classes compiled by a Java language compiler that have been transformed into the .dex format by the included "dx" tool.&lt;br /&gt;&lt;br /&gt;A central feature of Android is that one application can make use of elements of other applications. For example, if your application needs to display a scrolling list of images and another application has developed a suitable scroller and made it available to others, you can call upon that scroller to do the work, rather than develop your own. Your application doesn't incorporate the code of the other application or link to it. Rather, it simply starts up that piece of the other application when the need arises.&lt;br /&gt;&lt;br /&gt;For this to work, the system must be able to start an application process when any part of it is needed, and instantiate the Java objects for that part. Therefore, unlike applications on most other systems, Android applications don't have a single entry point for everything in the application (no main() function, for example). Rather, they have essential components that the system can instantiate and run as needed. There are four types of components:&lt;br /&gt;&lt;b&gt;Activities&lt;/b&gt;&lt;br /&gt;An activity presents a visual user interface for one focused endeavor the user can undertake. Each activity is given a default window to draw in. Android has a number of ready-made views that you can use — including buttons, text fields, scroll bars, menu items, check boxes, and more.&lt;br /&gt;&lt;b&gt;Services&lt;/b&gt;&lt;br /&gt;A service doesn't have a visual user interface, but rather runs in the background for an indefinite period of time.&lt;br /&gt;&lt;b&gt;Broadcast receivers&lt;/b&gt;&lt;br /&gt;A broadcast receiver is a component that does nothing but receive and react to broadcast announcements. Many broadcasts originate in system code — for example, announcements that the timezone has changed, that the battery is low, that a picture has been taken, or that the user changed a language preference.&lt;br /&gt;An application can have any number of broadcast receivers to respond to any announcements it considers important.&lt;br /&gt;&lt;b&gt;Content providers&lt;/b&gt;&lt;br /&gt;A content provider makes a specific set of the application's data available to other applications. The data can be stored in the file system, in an SQLite database, or in any other manner that makes sense.&lt;br /&gt;&lt;br /&gt;Before Android can start an application component, it must learn that the component exists. Therefore, applications declare their components in a &lt;span class="Apple-style-span" style="color: blue;"&gt;manifest file&lt;/span&gt; that's bundled into the Android package, the .apk file that also holds the application's code, files, and resources.&lt;br /&gt;&lt;br /&gt;To the user, it will seem as if the map viewer is part of the same application as your activity, even though it's defined in another application and &lt;span class="Apple-style-span" style="color: blue;"&gt;runs in that application's process&lt;/span&gt;. Android maintains this user experience by keeping both activities in the same task. Simply put, a task is what the user experiences as an "application." It's a group of related activities, arranged in a stack.&amp;nbsp;A task is a stack of activities, not a class or an element in the manifest file.&lt;br /&gt;&lt;br /&gt;Intents are asynchronous messages which allow the application to send or receive data from and to other activities or services. Application register themselves to an intent via an IntentFilter. Intents are a powerful concept as they allow the creation of &lt;span style="color: blue;"&gt;loosely coupled&lt;/span&gt; applications.&lt;br /&gt;Intent filters are typically defined via the "AndroidManifest.xml" file. A component uses intent filter to define for which intents it can be responsible. If a component does not define intent filters it can only be called by explicit intents. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Android Installation&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Download and unzip android SDK to a local folder.&lt;/li&gt;&lt;li&gt;Install ADT plug-in in&amp;nbsp;Eclipse.&lt;/li&gt;&lt;li&gt;Config&amp;nbsp;android SDK location in Eclipse.&lt;/li&gt;&lt;/ol&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;J2ME&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;Mobile Tools for Java &amp;nbsp; (MTJ)&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;span style="font-size: large;"&gt;LWUIT&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;A &lt;b&gt;Theme&lt;/b&gt; allows us to set the style attributes for an entire class  of components in a single place. This not only simplifies the task of  setting attributes for all components of a particular type but also  ensures that any newly added component will look just like all the  others of the same type in the application. A theme thereby establishes a  visual coherence through all the screens of an application. &lt;br /&gt;A theme file is conceptually similar to CSS while its implementation is  like that of a Java properties file. Essentially a theme is a list of &lt;i&gt;key-value&lt;/i&gt; pairs with an attribute being a &lt;i&gt;key&lt;/i&gt; and its value being the second part of the &lt;i&gt;key-value&lt;/i&gt; pair An entry in the list may be &lt;code&gt;Form.bgColor=&lt;/code&gt; &lt;code&gt;555555&lt;/code&gt;. This entry specifies that the background color of all forms in the application will be (hex) 555555 in the RGB format. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style="margin: 0px;"&gt;&lt;a href="http://www.infoworld.com/d/developer-world/how-choose-mobile-development-platform-077"&gt;http://www.infoworld.com/d/developer-world/how-choose-mobile-development-platform-077&lt;/a&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;a href="http://www.ibm.com/developerworks/opensource/library/os-android-devel/"&gt;http://www.ibm.com/developerworks/opensource/library/os-android-devel/&lt;/a&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;Eclipse plugin&amp;nbsp;&lt;a href="http://developer.android.com/sdk/eclipse-adt.html"&gt;http://developer.android.com/sdk/eclipse-adt.html&lt;/a&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;a href="http://www.android123.com.cn/"&gt;http://www.android123.com.cn/&lt;/a&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;a href="http://apparchguide.codeplex.com/wikipage?title=Chapter%2019%20-%20Mobile%20Applications"&gt;http://apparchguide.codeplex.com/wikipage?title=Chapter%2019%20-%20Mobile%20Applications&lt;/a&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;a href="http://www.theshulers.com/whitepapers/mobile_architecture/index.html"&gt;http://www.theshulers.com/whitepapers/mobile_architecture/index.html&lt;/a&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin: 0px;"&gt;&lt;a href="http://u.youku.com/user_show/id_UMTIyODk2MTgw.html"&gt;http://u.youku.com/user_show/id_UMTIyODk2MTgw.html&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;a href="http://www.youtube.com/watch?v=_35jeLSIeU4"&gt;http://www.youtube.com/watch?v=_35jeLSIeU4&lt;/a&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/5277669399194798662-2654431964274008791?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2654431964274008791/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2654431964274008791' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2654431964274008791'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2654431964274008791'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/mobile-operating-system.html' title='Mobile operating system'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4164644056333910430</id><published>2010-02-25T01:35:00.000-08:00</published><updated>2010-03-11T17:37:18.308-08:00</updated><title type='text'>Install common softwares on Ubumtu</title><content type='html'>1. JaveEE&lt;br /&gt;&lt;br /&gt;2. Eclipse.&lt;br /&gt;&lt;br /&gt;3. Code::Block&lt;br /&gt;C++ IDE&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-4164644056333910430?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4164644056333910430/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4164644056333910430' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4164644056333910430'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4164644056333910430'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/install-common-softwares-on-ubumtu.html' title='Install common softwares on Ubumtu'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5183984644245439226</id><published>2010-02-22T18:50:00.000-08:00</published><updated>2011-04-05T01:19:14.770-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Paper'/><title type='text'>Secure Internet Banking Authentication</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;Offline credential-stealing attacks&lt;/span&gt; aim to fraudulently gather a user’s credentials either by invading an insufficiently protected client PC via malicious software (such as a virus or Trojan horse) or by tricking a user into voluntarily revealing his or her credentials via phishing.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;Online channel-breaking attack&lt;/span&gt;s, as practiced by a malicious man in the middle, a commercially motivated market-scorer, (www.pcworld.com/news/article/0,aid,118757,00.asp), or a security-motivated content-inspector (www.microdasys.com) or Web washer (www.cyberguard.com), are even more sophisticated. Instead of trying to get the user’s credentials, the intruder unnoticeably&lt;br /&gt;intercepts messages between the client PC and the banking server by masquerading as the server to the client and vice versa.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;X.509&lt;/b&gt;&lt;br /&gt;In cryptography, X.509 is an ITU-T standard for a public key infrastructure (PKI) for single sign-on (SSO) and Privilege Management Infrastructure (PMI).&lt;br /&gt;&lt;b&gt;RSA&lt;/b&gt;&lt;br /&gt;In cryptography, RSA (which stands for Rivest, Shamir and Adleman who first publicly described it) is an algorithm for public-key cryptography[1]. It is the first algorithm known to be suitable for signing as well as encryption, and was one of the first great advances in public key cryptography.&lt;br /&gt;&lt;b&gt;SHA-1&lt;/b&gt;&lt;br /&gt;The SHA hash functions are a set of cryptographic hash functions designed by the National Security Agency (NSA) and published by the NIST as a U.S. Federal Information Processing Standard. SHA stands for Secure Hash Algorithm.&lt;br /&gt;&lt;b&gt;MD5&lt;/b&gt;&lt;br /&gt;In cryptography, MD5 (Message-Digest algorithm 5) is a widely used cryptographic hash function with a 128-bit hash value. As an Internet standard (RFC 1321), MD5 has been employed in a wide variety of security applications, and is also commonly used to check the integrity of files.&lt;br /&gt;&lt;b&gt;MAC&lt;/b&gt;&lt;br /&gt;A message authentication code (often MAC) is a short piece of information used to authenticate a message.&lt;br /&gt;A MAC algorithm, sometimes called a &lt;span class="Apple-style-span" style="color: blue;"&gt;keyed (cryptographic) hash function&lt;/span&gt;, accepts as input a &lt;span class="Apple-style-span" style="color: blue;"&gt;secret key &lt;/span&gt;and an arbitrary-length message to be authenticated, and outputs a MAC (sometimes known as a tag). The MAC value protects both a message's data &lt;span class="Apple-style-span" style="background-color: white;"&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;integrity&lt;/span&gt; &lt;/span&gt;as well as its &lt;span class="Apple-style-span" style="background-color: white;"&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;authenticity&lt;/span&gt;&lt;/span&gt;, by &lt;span class="Apple-style-span" style="color: blue;"&gt;allowing verifiers (who also possess the secret key) to detect any changes to the message content&lt;/span&gt;.&lt;br /&gt;MACs differ from digital signatures as MAC values are both generated and verified using the same secret key. This implies that the sender and receiver of a message must agree on the same key before initiating communications, as is the case with symmetric encryption.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;SSO&lt;/b&gt;&lt;br /&gt;Single sign-on (SSO) is a property of access control of multiple, related, but independent software systems. With this property a user logs in once and gains access to all systems without being prompted to log in again at each of them.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5183984644245439226?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5183984644245439226/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5183984644245439226' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5183984644245439226'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5183984644245439226'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/secure-internet-banking-authentication.html' title='Secure Internet Banking Authentication'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2667783678352561249</id><published>2010-02-22T01:54:00.000-08:00</published><updated>2010-02-22T01:54:11.716-08:00</updated><title type='text'>Data Mining: Concepts and Techniques</title><content type='html'>A data warehouse is a repository of information collected from multiple sources, stored under a unified schema, and which usually resides at a single site. Data warehouses are constructed via a process of data cleaning, data transformation, data integration, data loading, and periodic data refreshing.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-2667783678352561249?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2667783678352561249/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2667783678352561249' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2667783678352561249'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2667783678352561249'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/data-mining-concepts-and-techniques.html' title='Data Mining: Concepts and Techniques'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-1734520766651182505</id><published>2010-02-16T18:34:00.000-08:00</published><updated>2010-02-16T18:34:07.093-08:00</updated><title type='text'>Automated theorem proving</title><content type='html'>&lt;span class="Apple-style-span" style="color: red;"&gt;Automated theorem proving &lt;/span&gt;(ATP) or automated deduction, currently the most well-developed subfield of automated reasoning (AR), is the proving of mathematical theorems by a computer program.&lt;br /&gt;&lt;br /&gt;In mathematical logic, a &lt;span class="Apple-style-span" style="color: red;"&gt;propositional calculus&lt;/span&gt; or logic (also called sentential calculus) is a formal system in which formulas of a formal language may be interpreted as representing propositions. A system of inference rules and axioms allows certain formulas to be derived, called theorems; which may be interpreted as true propositions. The series of formulas which is constructed within such a system is called a derivation and the last formula of the series is a theorem, whose derivation may be interpreted as a proof of the truth of the proposition represented by the theorem.&lt;br /&gt;&lt;br /&gt;First-order logic is a &lt;span class="Apple-style-span" style="color: red;"&gt;formal logic&lt;/span&gt; used in mathematics, philosophy, linguistics, and computer science. It goes by many names, including: first-order predicate calculus, the lower predicate calculus, quantification theory, and predicate logic. First-order logic is distinguished from propositional logic by its use of quantifiers; each interpretation of first-order logic includes a domain of discourse over which the quantifiers range.&lt;br /&gt;&lt;br /&gt;While propositional logic deals with simple declarative propositions, first-order logic additionally covers predicates and quantification.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-1734520766651182505?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/1734520766651182505/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=1734520766651182505' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1734520766651182505'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1734520766651182505'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/automated-theorem-proving.html' title='Automated theorem proving'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8931378418574192571</id><published>2010-02-11T19:29:00.000-08:00</published><updated>2010-02-11T22:00:44.764-08:00</updated><title type='text'>Web Security</title><content type='html'>Hypertext Transfer Protocol Secure (HTTPS) is a combination of the Hypertext Transfer Protocol with the SSL/TLS protocol to provide encryption and &lt;span class="Apple-style-span" style="color: blue;"&gt;secure identification of the server&lt;/span&gt;. HTTPS connections are often used for payment transactions on the World Wide Web and for sensitive transactions in corporate information systems.&lt;br /&gt;&lt;br /&gt;The main idea of HTTPS is to create a secure channel over an insecure network. This ensures reasonable protection from &lt;span class="Apple-style-span" style="color: blue;"&gt;eavesdroppers and man-in-the-middle attacks&lt;/span&gt;, provided that adequate &lt;span class="Apple-style-span" style="color: blue;"&gt;cipher suites&lt;/span&gt; are used and that the server certificate is verified and trusted.&lt;br /&gt;&lt;br /&gt;The trust inherent in HTTPS is based on major certificate authorities which come pre-installed in browser software (this is equivalent to saying "I trust certificate authority (e.g. VeriSign/Microsoft/etc.) to tell me who I should trust"). Therefore an HTTPS connection to a website can be trusted.&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;Transport Layer Security&lt;/span&gt; (TLS) and its predecessor, &lt;span class="Apple-style-span" style="color: blue;"&gt;Secure Sockets Layer&lt;/span&gt; (SSL), are cryptographic protocols that provide security for communications over networks such as the Internet. TLS and SSL encrypt the segments of network connections at the Transport Layer end-to-end.&lt;br /&gt;&lt;br /&gt;The TLS protocol allows client/server applications to communicate across a network in a way designed to prevent eavesdropping and tampering. TLS provides endpoint authentication and communications confidentiality over the Internet using cryptography.&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 22px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: Arial, Helvetica, sans-serif; font-size: 14px; line-height: 22px;"&gt;SSL协议提供的服务主要有：&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: Arial; font-size: 14px; line-height: 24px;"&gt;&lt;span class="Apple-style-span" style="color: black; font-family: Arial, Helvetica, sans-serif; line-height: 22px;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: Arial; font-size: 14px; line-height: 24px;"&gt;&lt;div style="line-height: 22px; margin-bottom: 10px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-indent: 2em;"&gt;1）认证用户和服务器，确保数据发送到正确的客户机和服务器；&lt;/div&gt;&lt;div style="line-height: 22px; margin-bottom: 10px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-indent: 2em;"&gt;2）加密数据以防止数据中途被窃取；&lt;/div&gt;&lt;div style="line-height: 22px; margin-bottom: 10px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-indent: 2em;"&gt;3）维护数据的完整性，确保数据在传输过程中不被改变。&lt;/div&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: Arial; font-size: 14px; line-height: 24px;"&gt;一种常见的误解是“银行用户在线使用https:就能充分彻底保障他们的银行卡号不被偷窃。”实际上，与服务器的加密连接中能保护银行卡号的部分，只有用户到服务器之间的连接及服务器自身。并不能绝对确保服务器自己是安全的，这点甚至已被攻击者利用，常见例子是模仿银行域名的钓鱼攻击。少数罕见攻击在网站传输客户数据时发生，攻击者尝试窃听数据于传输中。&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8931378418574192571?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8931378418574192571/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8931378418574192571' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8931378418574192571'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8931378418574192571'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/web-security.html' title='Web Security'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8819081448984639710</id><published>2010-02-11T00:49:00.001-08:00</published><updated>2010-02-11T06:56:31.211-08:00</updated><title type='text'>configuration of Apache Web server</title><content type='html'>list all the files in a folder&lt;br /&gt;&lt;br /&gt;add a&amp;nbsp;&lt;span class="Apple-style-span" style="-webkit-border-horizontal-spacing: 1px; -webkit-border-vertical-spacing: 1px; font-family: verdana, arial, helvetica, sans-serif; font-size: 11px; line-height: 16px; white-space: nowrap;"&gt;&lt;a href="http://thewizardshoes.com:2222/CMD_FILE_MANAGER/domains/thewizardshoes.com/public_html/images/products/.htaccess" style="color: black; font-family: verdana, arial, helvetica, sans-serif; font-size: 8pt; line-height: 16px; text-decoration: none;"&gt;.htaccess&lt;/a&gt;&amp;nbsp;file in the folder&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;&lt;files ^.(htaccess|htpasswd)$"="" ~=""&gt;&lt;/files&gt;&lt;br /&gt;deny from all&lt;br /&gt;&lt;br /&gt;Options Indexes&lt;br /&gt;order deny,allow&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8819081448984639710?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8819081448984639710/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8819081448984639710' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8819081448984639710'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8819081448984639710'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/configuration-of-apache-web-server.html' title='configuration of Apache Web server'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2460694528646361425</id><published>2010-02-03T19:28:00.000-08:00</published><updated>2010-02-04T00:25:06.895-08:00</updated><title type='text'>Value chain</title><content type='html'>A value chain is a chain of activities for a firm operating in a specific industry. Products pass through all activities of the chain in order and at each activity the product gains some value. The chain of activities gives the products more added value than the sum of added values of all activities. It is important not to mix the concept of the value chain with the costs occurring throughout the activities. &lt;br /&gt;&lt;br /&gt;The costs and value drivers are identified for each value activity. The value chain framework quickly made its way to the forefront of management thought as a powerful analysis tool for strategic planning. Capturing the value generated along the chain is the new approach taken by many management strategists. &lt;br /&gt;&lt;br /&gt;Value chain is a high-level model of how businesses receive raw materials as input, add value to the raw materials through various processes, and sell finished products to customers.&lt;br /&gt;&lt;br /&gt;A knowledge value chain is a sequence of intellectual tasks by which knowledge workers build their employer's unique competitive advantage and/or social and environmental benefit. As an example, the components of a research and development project form a knowledge value chain.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-2460694528646361425?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2460694528646361425/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2460694528646361425' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2460694528646361425'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2460694528646361425'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/value-chain.html' title='Value chain'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5136112729997264120</id><published>2010-02-02T23:20:00.000-08:00</published><updated>2010-02-03T01:54:42.239-08:00</updated><title type='text'>GWT</title><content type='html'>Google Web Toolkit is a comprehensive suite of programs developed by Google, which it provides free to the open source community&amp;nbsp;(under the Apache 2.0 license) to implement Ajax.&lt;br /&gt;Program code is written by the programmer. The programming language is Java. When the programmer is ready to "compile" the Java&amp;nbsp;code, the google "compiler" program takes the code and converts it to a series of html and javascript files that can be displayed&amp;nbsp;on most browsers.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;JSON, short for JavaScript Object Notation, is a lightweight computer data interchange format. It is a text-based, human-readable format for representing simple data structures and associative arrays (called objects). The JSON format is often used for serialization and transmitting structured data over a network connection. Its main application is in Ajax web application programming, where it serves as an alternative to the XML format.&lt;br /&gt;XML being a general-purpose markup language, they are syntactically more complex and bigger in file size than JSON, which, in contrast, is specifically designed for data interchange.&lt;br /&gt;&lt;br /&gt;${\sum_{i=1}^nx_i}$&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5136112729997264120?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5136112729997264120/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5136112729997264120' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5136112729997264120'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5136112729997264120'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/02/gwt.html' title='GWT'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-600943609000899747</id><published>2010-01-31T22:57:00.000-08:00</published><updated>2010-01-31T22:57:12.039-08:00</updated><title type='text'>Computational trust</title><content type='html'>The multi-agent system paradigm and the huge evolution of e-commerce are factors that contributed to the increase of interest on trust and reputation. In fact, Trust and reputation systems have been recognized as the key factors for a successful electronic commerce adoption. These systems are used by intelligent software agents as an incentive in decision-making, when deciding whether or not to honor contracts, and as a mechanism to search trustworthy exchange partners. In particular, reputation is used in electronic markets as a trust-enforcing mechanism or as a method to avoid cheaters and frauds.&lt;br /&gt;&lt;br /&gt;Trust and reputation are considered subjective probabilities by which the individual A, expects the individual B to perform a given action on which its welfare depends.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-600943609000899747?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/600943609000899747/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=600943609000899747' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/600943609000899747'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/600943609000899747'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/01/computational-trust.html' title='Computational trust'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7622304911972690325</id><published>2010-01-19T00:48:00.000-08:00</published><updated>2010-02-02T20:01:13.929-08:00</updated><title type='text'>Artificial Intelligence for Game</title><content type='html'>The AI in most modern games addresses three basic needs: the ability to move characters; the ability to make decisions about where to move, and the ability to think tactically or strategically.&lt;br /&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;5 Decision Making&lt;/span&gt;&lt;br /&gt;5.2 Decision trees&lt;br /&gt;5.3 State machines&lt;br /&gt;In a state machine each character occupies one state. Normally, actions or behaviors are associated with each state. So, as long as the character remains in that state, it will continue carrying out the same action.&lt;br /&gt;States are connected together by transitions. Each transition leads from one state to another, the target state, and each has a set of associate conditions. If the game determines that the conditions of a transition are met, then the character change state to the transition's target state.&lt;br /&gt;&lt;br /&gt;At each iteration(normally each frame), the state machine's update function is called. This checks to see if any transition from the current stat is triggered. The first transition that is triggered is scheduled to fire. The method then compiles a list of actions to perform from the currently active state. If a transition has been triggered, then the transition is fired. This separation of the triggering and the firing of transitions allows the transitions to also have their own actions.&lt;br /&gt;&lt;br /&gt;Because state machines are often defined in a data file and read into the game at runtime, it is a common requirement to have a set of generic transitions.&lt;br /&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;Hierarchy state machine&lt;/span&gt; support transitions between levels of the hierarchy.&lt;br /&gt;Decision trees are an efficient way of matching a series of conditions, and this has application in state machines for matching transitions. We can combine the two approaches by replacing transitions from a state with a decision tree. The leaves of the tree, rather than being actions as before, are&amp;nbsp;transitions&amp;nbsp;to new states.&lt;br /&gt;&lt;br /&gt;5.4 Behavior trees&lt;br /&gt;Behavior trees have a lot in common with Hierarchical State Machine but, instead of a state, the main building block of a behavior tree is a task. A task can be something as simple as looking up the value of a variable in the game state, or executing an animation.&lt;br /&gt;&lt;br /&gt;Task are composed into sub-trees to represent more complex actions. In turn, these complex actions can again be composed into higher level&amp;nbsp;behaviors. &lt;span class="Apple-style-span" style="color: blue;"&gt;It is this composability that gives behavior trees their power. &lt;/span&gt;&lt;br /&gt;Behavior trees really shine when coupled with a GUI to edit the tree. That way, designers, technical artists and level designers can potentially author complex AI behavior. The key difference in behavior tree is the use of a single common interface for all tasks.&lt;br /&gt;Simple behavior tress will consist of three kinds of tasks: Conditions, Actions, Composites, and Decorators.&lt;br /&gt;Condition test some property of the game.&lt;br /&gt;Actions alter the state of the game.&lt;br /&gt;Composite tasks includes:Selector and Sequence.&lt;br /&gt;Decorator is a type of task that has one single child task and modifies its behavior in some way.&lt;br /&gt;One simple Decorators makes a decision whether to allow their child behavior to run or not(They are sometimes called filters).&lt;br /&gt;Decorator to guard the resource. (if the character's hands are moving through the reload animation, the can't be asked to wave.&lt;br /&gt;A Selector will return immediately with a success status code when one of its children runs successfully.&lt;br /&gt;A Sequence will return immediately with a failure status code when one of tis children fails. As long as its children are succeeding, it will keep going.&lt;br /&gt;Behavior trees implement a very simple form of planning, sometimes called reactive planning. Selectors allow the character to try things, and fall back to other behaviors if they fail.&lt;br /&gt;&lt;br /&gt;5.5 Fuzzy Logic&lt;br /&gt;Fuzzy logic is relatively popular in the game industry. However, it has been largely discredited within the mainstream academic AI community.&lt;br /&gt;It is always better to use probability to represent any kind of&amp;nbsp;uncertainty. Part of reason why fuzzy logic ever became poplar was the perception that using probabilistic methods can be slow.&lt;br /&gt;&lt;br /&gt;5.7 Goal-oriented behavior&lt;br /&gt;Characters need to demonstrate their emotional and physical stat by choosing appropriate actions. We could simply run a decision tree that selects available actions based on the current emotional and physical parameters of the character. But it would lead to a very big decision tree.&lt;br /&gt;A better approach would be to present the character with a&amp;nbsp;suite&amp;nbsp;of possible actions and have it choose the one that best meets its immediate needs.&lt;br /&gt;A character may have one or more goals. Each goal has a level of importance (insistence) represented by a number. A goal with a high insistence will tend to influence the character's behavior more strongly.&lt;br /&gt;The actions depend on the current state of the game. as the actions are added to the list of options they are rated against each motive the character has.&lt;br /&gt;A simple approach would be to choose the most pressing goal (the one with the largest decrease in insistence) and find an action that either fulfills it completely or provides it with the largest decrease in insistence. It has two major weaknesses, however: it fails to take account of side effects that an action may have, and it doesn't incorporate any timing information.&lt;br /&gt;The discontentment is calculated based on all the goal insistence values, where high&amp;nbsp;insistence&amp;nbsp;leaves the character more discontent. The aim of the character is to reduce its overall discontentment level. Discontentment is simply a score we are trying to minimize. It is known as an energy metric.&lt;br /&gt;&lt;br /&gt;5.8 Rule-Based Systems&lt;br /&gt;Rule based systems have a common structure consisting of two parts: a database containing knowledge available to the AI and a set of if-then rules. The rules trigger based on the contents of the database, and their effects can be more general than causing a state transition.&lt;br /&gt;The "if" condition of the rule is matched against the database; a successful match triggers the rule. The condition, normally called a pattern. The database should only contain knowledge about the state of the game.&lt;br /&gt;Many rule-based systems use a wild-card pattern matching, called unification, which can include wild cards.&lt;br /&gt;&lt;br /&gt;5.9 Blackboard architecture&lt;br /&gt;A blackboard architecture isn't a decision making tool in its own right. It is a mechanism for&amp;nbsp;coordinating&amp;nbsp;the actions of several decision makers. In games, we would like to be able to coordinate the decision making of several different techniques. Each technique may be able to make suggestions as to what to do next, but the final decision can only be make if they cooperate.&lt;br /&gt;Rule based system is a kind of blackboard architecture which also have three elements:their database like blackboard containing data, each rule is like an expert - it can read from and write to the database, and there is an arbiter that controls which rule gets to fire.&lt;br /&gt;Finite state machines are also a subset of the blackboard architecture (actually they are a subset of a rule-based system and, therefore, of a blackboard architecture).&lt;br /&gt;&lt;br /&gt;5.10 Scripting&lt;br /&gt;In the early and mid-1990s, most AI was hard-coded using custom written code to make decisions. As production became more complex, there arose a need to&amp;nbsp;separate&amp;nbsp;the content(behavior designs) from the engine.&lt;br /&gt;Scripts can be treated as data files, and if the scripting language is simple enough level designers or technical artists can create the behaviors. An unexpected side effect of scripting language support is the ability for players to create their own character behavior and to extend the game. &lt;br /&gt;&lt;br /&gt;5.11 Action execution&lt;br /&gt;We can divide the kind of actions that result from AI decision into four flavors: state change actions, animations, movement, and AI requests.&lt;br /&gt;State change actions are the simplest kind of action, simply changing some piece of the game state. it is often not directly visible to the player. For example, a character may change the firing mode of its weapon.&lt;br /&gt;Animation are the most primitive kind of visual feedback. This might be a particle effect when a character casts a spell or a quick shuffle of the hands to indicate a weapon reload.&lt;br /&gt;Movement algorithm can converts high level movement request into primitive actions.&lt;br /&gt;In AI requests for complex characters, a high-level decision maker may be tasked with deciding which low level decision maker to use. For example, the AI controlling one team in a real-time strategy game may decide that it is time to build. A different AI may actually decide which building gets to be constructed.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7622304911972690325?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7622304911972690325/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7622304911972690325' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7622304911972690325'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7622304911972690325'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/01/artificial-intelligence-for-game.html' title='Artificial Intelligence for Game'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-3214964107803923413</id><published>2010-01-17T18:00:00.000-08:00</published><updated>2010-01-17T21:38:53.352-08:00</updated><title type='text'>Fuzzy Logic</title><content type='html'>Fuzziness primarily describes &lt;span style="color: blue;"&gt;uncertainty &lt;/span&gt;(partial true) and &lt;span style="color: blue;"&gt;imprecision&lt;/span&gt;. The key idea of fuzziness comes from the &lt;span style="color: blue;"&gt;multivalued logic: everything is a matter of degree.&lt;/span&gt;&lt;br /&gt;Zadeh generalized the idea of a crisp set(bivalent set) by extending a valuation set{1,0}(definitely in/definitely out) to the interval of real values (&lt;span style="color: blue;"&gt;degree of&amp;nbsp;membership&lt;/span&gt;) between 0 and 1 denoted as [0,1].&lt;br /&gt;Fuzzy sets represent/manipulate data and&amp;nbsp;information&amp;nbsp;processing &lt;span style="color: blue;"&gt;non-statistical uncertainties&lt;/span&gt;.&lt;br /&gt;The problem of constructing membership functions is not a problem of fuzzy set theory. It is a problem of knowledge acquisition, which is a subject of knowledge engineering.&lt;br /&gt;Fuzzy sets tend to capture vagueness exclusively via membership functions that are mappings from a given universe of discourse X to a unit interval containing&amp;nbsp;membership values.&lt;br /&gt;Fuzzy logic provides an inference morphology that enables &lt;span style="color: blue;"&gt;approximate human reasoning&lt;/span&gt;. In practice, fuzzy logic means &lt;span style="color: blue;"&gt;computing with words&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;A Fuzzy system is a collection of fuzzy rules that converts inputs to outputs.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-3214964107803923413?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/3214964107803923413/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=3214964107803923413' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3214964107803923413'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3214964107803923413'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2010/01/fuzzy-logic.html' title='Fuzzy Logic'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7074388169523908159</id><published>2009-12-10T23:41:00.000-08:00</published><updated>2010-07-25T23:43:41.907-07:00</updated><title type='text'>Configure of Eclipse</title><content type='html'>After install Eclipse and JavaEE, the classpath and installed Jre need config&lt;br /&gt;1. Set window-&amp;gt;preferences-&amp;gt;Java-&amp;gt;Installed JRES 更改jre home为C:\Sun\SDK\jdk\jre&lt;br /&gt;2. Set window-&amp;gt;preferences-&amp;gt;Java-&amp;gt;Build path-&amp;gt;Classpath 添加更改jre home为C:/Sun/SDK/jdk/lib&lt;br /&gt;&lt;br /&gt;Import a existing project:&lt;br /&gt;File--&amp;gt; import --&amp;gt; Existing project&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;由于Eclipse本身是用Java语言编写的，而下载的压缩包中并不包含Java运行环境，因此需要用户自己另行安装JRE，并且要在操作系统的环境变量中指明JRE中bin的路径。如果上述设置不正确，Eclipse是无法正常运行的。&lt;br /&gt;&lt;br /&gt;FAQ:&lt;br /&gt;&lt;br /&gt;为什么我们不用把jre/bin目录到path中？&lt;br /&gt;安装jre的时候安装程序自动帮你把jre的java.exe添加Windows/system32中。&lt;br /&gt;&lt;br /&gt;"Could not find jar tool executable" When Packaging&lt;br /&gt;EclipseME must find at least one full Java Development Kit within the Installed JRE's (a subcategory of the Java category). By default, Eclipse will recognize a JRE rather than a full JDK on Windows. To solve this problem, make sure to point the location of the installed JRE instance to the root directory of the JDK directory. For instance on Windows, that might be something like c:\j2sdk1.4.2.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7074388169523908159?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7074388169523908159/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7074388169523908159' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7074388169523908159'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7074388169523908159'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/12/test.html' title='Configure of Eclipse'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-6997677833087725561</id><published>2009-12-09T18:26:00.000-08:00</published><updated>2009-12-09T18:26:12.279-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Paper'/><title type='text'>Multimodal Learning Through Media: What the Research Says</title><content type='html'>Recent technological advances confirm a dual coding system through which visuals and text/auditory input are processed in separate channels, presenting the potential for simultaneous augmentation of learning. The bottom&lt;br /&gt;line is that students using well-designed combinations of visuals and text learn more than students who only use text.&lt;br /&gt;&lt;br /&gt;The complexity of today’s global society and the accelerating rate of change require a citizenry that continuously learns, computes, thinks, creates, and innovates.&lt;br /&gt;&lt;br /&gt;Experienced teachers recognize that the design of lessons must adapt to the expertise and prior knowledge of the learner, the complexity of the content, and interests of the learner. Experienced researchers recognize that the use of technology and multimedia, resources, and lessons can vary in the level of interactivity, modality, sequencing, pacing, guidance, prompts, and alignment to student interest, all of which influence the efficiency in learning.&lt;br /&gt;&lt;br /&gt;With time a limited commodity in today’s society, people are tempted by technology to do more than one thing at a time (such as driving and talking on the phone, reading e-mails while participating in audio conferences, etc.). New scientific studies reveal the losses in efficiency in such multitasking.Researchers find that thinking processes happen serially, resulting in delays caused by switching from one task to another. The delays become more pronounced as the complexity of the task increases.&lt;br /&gt;&lt;br /&gt;The working memory is dual coded with a buffer for storage of verbal/text elements, and a second buffer for visual/spatial elements.25&lt;br /&gt;&lt;br /&gt;Within working memory, verbal/text memory and visual/spatial memory work together, without interference, to augment&lt;br /&gt;understanding.&lt;br /&gt;&lt;br /&gt;Learning is optimized when students can see where new concepts build on prior knowledge.&lt;br /&gt;&lt;br /&gt;Expertise is developed through deep understanding. Students learn more when the concepts are personally meaningful to them. In order to deeply understand a topic, learners not only need to know relevant facts, theories, and applications, they must also make sense of the topic through organization of those ideas into a framework (schema) of understanding. The development of schema requires that students learn topics in ways that are relevant and meaningful to them.&lt;br /&gt;&lt;br /&gt;Learning is optimized when students develop “metacognitive” strategies.Students who are metacognitive are students who approach problems by automatically trying to predict outcomes, explaining ideas to themselves, noting and learning from failures, and activating prior knowledge.&lt;br /&gt;&lt;br /&gt;While the field is still evolving, researchers have shown that significant increases in learning can be accomplished through the informed use of visual and verbal multimodal learning.&lt;br /&gt;&lt;br /&gt;The reality is that the most effective designs for learning adapt to include a variety of media, combinations of&lt;br /&gt;modalities, levels of interactivity, learner characteristics, and pedagogy based on a complex set of circumstances.&lt;br /&gt;&lt;br /&gt;In general, multimodal learning has been shown to be more effective than traditional, unimodal learning. Adding visuals to verbal (text and/or auditory) learning can result in significant gains in basic and higher-order learning.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-6997677833087725561?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/6997677833087725561/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=6997677833087725561' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6997677833087725561'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/6997677833087725561'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/12/multimodal-learning-through-media-what.html' title='Multimodal Learning Through Media: What the Research Says'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4176014602038826837</id><published>2009-11-22T22:24:00.000-08:00</published><updated>2009-12-11T01:10:28.206-08:00</updated><title type='text'>Mobile Learning</title><content type='html'>&lt;div id="__ss_135047" style="text-align: left; width: 425px;"&gt;&lt;a href="http://www.slideshare.net/Dannno/mobile-learning-exchange" style="display: block; font: 14px Helvetica,Arial,Sans-serif; margin: 12px 0 3px 0; text-decoration: underline;" title="Mobile Learning Exchange"&gt;Mobile Learning Exchange&lt;/a&gt;&lt;object height="355" style="margin: 0px;" width="425"&gt;&lt;param name="movie" value="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=mobile-learning-exchange-1192463736357494-1&amp;amp;stripped_title=mobile-learning-exchange" /&gt;&lt;param name="allowFullScreen" value="true"/&gt;&lt;param name="allowScriptAccess" value="always"/&gt;&lt;embed src="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=mobile-learning-exchange-1192463736357494-1&amp;amp;stripped_title=mobile-learning-exchange" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="355"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;div style="font-family: tahoma,arial; font-size: 11px; height: 26px; padding-top: 2px;"&gt;View more &lt;a href="http://www.slideshare.net/" style="text-decoration: underline;"&gt;presentations&lt;/a&gt; from &lt;a href="http://www.slideshare.net/Dannno" style="text-decoration: underline;"&gt;Dannno&lt;/a&gt;.&lt;/div&gt;&lt;/div&gt;&lt;br /&gt;&lt;div style="width:425px;text-align:left" id="__ss_1521233"&gt;&lt;a style="font:14px Helvetica,Arial,Sans-serif;display:block;margin:12px 0 3px 0;text-decoration:underline;" href="http://www.slideshare.net/jnxyz/ipod-touch-for-mobile-learning" title="iPod touch for mobile learning"&gt;iPod touch for mobile learning&lt;/a&gt;&lt;object style="margin:0px" width="425" height="355"&gt;&lt;param name="movie" value="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=itsc09itouchwshop-090602070709-phpapp01&amp;stripped_title=ipod-touch-for-mobile-learning" /&gt;&lt;param name="allowFullScreen" value="true"/&gt;&lt;param name="allowScriptAccess" value="always"/&gt;&lt;embed src="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=itsc09itouchwshop-090602070709-phpapp01&amp;stripped_title=ipod-touch-for-mobile-learning" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="355"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;div style="font-size:11px;font-family:tahoma,arial;height:26px;padding-top:2px;"&gt;View more &lt;a style="text-decoration:underline;" href="http://www.slideshare.net/"&gt;documents&lt;/a&gt; from &lt;a style="text-decoration:underline;" href="http://www.slideshare.net/jnxyz"&gt;Jonathan  Nalder&lt;/a&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/5277669399194798662-4176014602038826837?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4176014602038826837/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4176014602038826837' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4176014602038826837'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4176014602038826837'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/11/mobile-learning.html' title='Mobile Learning'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2888029133921390888</id><published>2009-11-18T20:02:00.000-08:00</published><updated>2009-11-19T22:25:02.427-08:00</updated><title type='text'>Semantic Web</title><content type='html'>&lt;span style="color: #444444; font-family: Arial; font-size: 12px; white-space: pre;"&gt;&lt;div id="__ss_1718687" style="text-align: left; width: 425px;"&gt;&lt;a href="http://www.slideshare.net/HatemMahmoud/web-30-the-semantic-web" style="display: block; font: 14px Helvetica,Arial,Sans-serif; margin: 12px 0 3px 0; text-decoration: underline;" title="Web 3.0 The Semantic Web"&gt;Web 3.0 The Semantic Web&lt;/a&gt;&lt;object height="355" style="margin: 0px;" width="425"&gt;&lt;param name="movie" value="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=web-3-0-the-semantic-web-090714041600-phpapp02&amp;amp;stripped_title=web-30-the-semantic-web" /&gt;&lt;param name="allowFullScreen" value="true"/&gt;&lt;param name="allowScriptAccess" value="always"/&gt;&lt;embed src="http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=web-3-0-the-semantic-web-090714041600-phpapp02&amp;amp;stripped_title=web-30-the-semantic-web" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="355"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;br /&gt;The difference between Semantic Web and Web Services:&lt;br /&gt;The mainstream XML standards for interoperation of web services specify only syntactic interoperability, not the semantic meaning of messages.&lt;br /&gt;&lt;br /&gt;&lt;i&gt;"If HTML and the Web made all the online documents look like one huge book, RDF, schema, and inference languages will make all the data in the world look like one huge database"&lt;/i&gt;&lt;br /&gt;Tim Berners-Lee, Weaving the Web, 1999&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;RDF&lt;br /&gt;&lt;br /&gt;RDF is a framework for describing Web resources.&lt;br /&gt;RDF is data about data - or metadata. Often RDF files describe other RDF files.&lt;br /&gt;An RDF pointer is a pointer (actually an URL) to information about things (like a knowledge database).&lt;br /&gt;RDF identifies things using Web identifiers (URIs), and describes resources with properties and property values.The&amp;nbsp;combination of a Resource, a Property, and a Property value forms a Statement (known as the subject, predicate and&amp;nbsp;object of a Statement).&lt;br /&gt;A container is a resource that contains things. The contained things are called members (not list of values)&lt;br /&gt;RDF collections are used to describe groups that can contains ONLY the specified members.&lt;br /&gt;The Dublin Core is a set of predefined properties for describing documents.&lt;br /&gt;&lt;br /&gt;OWL&lt;br /&gt;&lt;br /&gt;Ontology is about the exact description of things and their relationships.&lt;br /&gt;OWL stands for Web Ontology Language. OWL is built on top of RDF. OWL is for processing information on the web.&lt;br /&gt;OWL comes with a larger vocabulary and stronger syntax than RDF.&lt;br /&gt;OWL has three sublanguages:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;OWL Lite&lt;/li&gt;&lt;li&gt;OWL DL (includes OWL Lite)&lt;/li&gt;&lt;li&gt;OWL Full (includes OWL DL)&lt;/li&gt;&lt;/ul&gt;&lt;div&gt;&lt;br /&gt;An OWL ontology consists of a set of axioms which place constraints on sets of individuals (called "classes") and the types of relationships permitted between them.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;Semantic Web provides a common protocol for data and service to inter-operate.&lt;br /&gt;&lt;br /&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Semantic Web provide a common manual way to define the logic rules and break the natural sentence to machine understandable concepts and relationships. It makes human to fit for machine.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-2888029133921390888?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2888029133921390888/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2888029133921390888' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2888029133921390888'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2888029133921390888'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/11/semantic-web.html' title='Semantic Web'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7706703312488191555</id><published>2009-11-12T01:15:00.000-08:00</published><updated>2009-11-12T01:25:05.218-08:00</updated><title type='text'>Math</title><content type='html'>Hash function&lt;div&gt;&lt;div&gt;A hash function is any well-defined procedure or mathematical function which converts a large, possibly variable-sized amount of data into a small datum, usually a single integer that may serve as an index to an array.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In general, a hashing function may map several different keys to the same index. Therefore, each slot of a hash table is associated with (implicitly or explicitly) a set of records, rather than a single record. For this reason, each slot of a hash table is often called a bucket, and hash values are also called bucket indices.&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/5277669399194798662-7706703312488191555?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7706703312488191555/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7706703312488191555' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7706703312488191555'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7706703312488191555'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/11/math.html' title='Math'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7116466791999520445</id><published>2009-11-05T23:32:00.000-08:00</published><updated>2009-11-20T02:02:51.960-08:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Book'/><title type='text'>An Introduction to MultiAgent Systems</title><content type='html'>&lt;div&gt;&lt;span style="font-size: large;"&gt;1. Introduction&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;In a classic distributed/concurrent system, all the computing elements are implicitly assumed to share a common goal(of making the overall system function correctly). In multiagent systems, it is assumed instead that agents are primarily concerned with their own welfare.&lt;br /&gt;&lt;span style="font-size: large;"&gt;2. Intelligent Agents&lt;/span&gt;&lt;br /&gt;&lt;div&gt;An agent is a computer system that is situated in some environment, and that is capable of autonomous action in this environment in order to meet its design objectives.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In most domains of reasonable complexity, an agent will not have complete control over its environment. It will have a best partial control, in that it can influence it.&lt;br /&gt;In practice, almost all realistic environments must be regarded as non-deterministic from an agent's perspective.&lt;br /&gt;From agent's point of view, dynamic environments have at least two important properties. The first is that if an agent performs no external action between times t0 and t1, then it cannot assume that the environment at t1 will be the same as it was at time t0. The second property is that other processes in the environment can interfere with the actions it attempts to perform.&lt;br /&gt;Functional systems &lt;span style="font-style: italic;"&gt;f&lt;/span&gt; : I-&amp;gt;O.&lt;br /&gt;A functional system is one that simply takes some input, performs some computation over this input, and eventually produces some output.&lt;br /&gt;Reactive systems&lt;br /&gt;Reactive systems are harder to engineer than functional ones, because an agent engaging in a (conceptually) non-terminating relationship with its environment must continually make local decisions that have long-term consequences.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In an episodic environment, the performance of an agent is dependent on a number of discrete episodes, with no link between the performance of the agent in different episodes.&lt;br /&gt;Intelligent agent has:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Reactivity&lt;/span&gt;. Intelligent agents are able to perceive their environment, and respond in a timely fashion to changes that occur in it in order to satisfy their design objectives.&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Proactiveness&lt;/span&gt;. Intelligent agents are able to exhibit goal-directed behavious by taking the initiative in order to satisfy their design objectives.&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Social ability&lt;/span&gt;. Intelligent agents are capable of interacting with other agents (and possibly humans) in order to satisfy their design objectives.&lt;/li&gt;&lt;/ul&gt;Achieving a good balance between goal-directed and reactive behavior is hard.&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Environments are assumed to be history dependent. In other words, the next state of an environment is not solely determined by the action performed by the agent and the current state of the environment. The actions make earlier by the agent also play a part in determining the current state.&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;Certain types of agents decide what to do without reference to their history. They base their decision-making entirely on the present, with no reference at all to the past. We call such agents purely reactive, since they simply respond directly to their environment. Sometimes they are called tropistic agents)&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;More usually, we want to tell our agent what to do without telling it how to do it.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;A utility is a numeric value representing how 'good' the state is: the higher the utility, the better. The task of the agent is then to bring about states that maximize utility.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;It is difficult to specify a long-term view when assigning utilities to individual states. To get around this problem, we can specify a task as a function which assigns a utility not to individual states, but to runs themselves.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;One of the disadvantages of utility-based approach is that it is very often difficult to derive an appropriate utility function. The second is that usually we find it more convenient to talk about tasks in terms of 'goals to be achieved' rather than utilities. &lt;br /&gt;&lt;/div&gt;&lt;div&gt;An achievement task is specified by a number of goal states; the agent is required to bring about one of these goal states. The environment and agent both begin in some state; the agent takes a turn by executing an action, and the environment responds with some state; the agent then takes another turn, and son on. The agent 'wins' if it can force the environment into one of the goal states. &lt;br /&gt;&lt;/div&gt;&lt;div&gt;Maintenance task environments: the agent is required to avoid some state of affairs.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: large;"&gt;3. Deductive Reasoning Agents&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: medium;"&gt;Traditional AI systems, known as symbolic AI, suggests that intelligent behavious can be generated in a system by giving that system a symbolic representation of its environment and its desired behaviour, and syntactically manipulating this representation. &lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: medium;"&gt;In logic-based approaches to building agents, decision-making is viewed as deduction. The process of selecting an action reduces to a problem of proof.  But logic-based approaches have many disadvantages. In particular, the inherent computational complexity of theorem proving makes it questionable whether agents as theorem provers can operate effectively in time-constrained environments.  &lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: medium;"&gt;&lt;b&gt;4. Practical Reasoning Agents&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: medium;"&gt;Practice reasoning is a matter of weighing conflicting considerations for and against competing options, where the relevant considerations are provided by what the agent desires/values/cares about and what the agent believes.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: medium;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: medium;"&gt;Deciding what state of affairs to achieve is known as deliberation. &lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: medium;"&gt;Deciding how to achieve these states of affairs is known as means-ends reasoning. It is better known in the AI community as planning.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: medium;"&gt;A planner is a system that takes as input representations of the following.&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;ol&gt;&lt;li&gt;&lt;span style="font-size: medium;"&gt;A goal, intention or a task. This is something that the agent wants to achieve, or a state of affairs that the agent wants to maintain or avoid.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size: medium;"&gt;The current state of the environment - agent's beliefs.&lt;/span&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-size: medium;"&gt;The actions available to the agent.&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div&gt;As output, a planning algorithm generates a plan. This is a course of action - a 'recipe'.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The mechanism an agent uses to determine when and how to drop intentions is known as a commitment strategy.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;The Belief-Desire-Intention (BDI) software model (usually referred to simply, but ambiguously, as BDI) is a software model developed for programming intelligent agents.A third activity, creating the plans in the first place (planning), is not within the scope of the model, and is left to the system designer and programmer.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt;Beliefs: Beliefs represent the informational state of the agent, in other words its beliefs about the world (including itself and other agents). Beliefs can also include inference rules, allowing forward chaining to lead to new beliefs.&lt;/li&gt;&lt;li&gt;Desires: Desires represent the motivational state of the agent. They represent objectives or situations that the agent would like to accomplish or bring about. Goals: A goal is a desire that has been adopted for active pursuit by the agent. Usage of the term goals adds the further restriction that the set of active desires must be consistent. For example, one should not have concurrent goals to go to a party and to stay at home - even though they could both be desirable.&lt;/li&gt;&lt;li&gt;Intentions: Intentions represent the deliberative state of the agent - what the agent has chosen to do. Intentions are desires to which the agent has to some extent committed. In implemented systems, this means the agent has begun executing a plan.&lt;/li&gt;&lt;li&gt;Events: These are triggers for reactive activity by the agent. An event may update beliefs, trigger plans or modify goals. Events may be generated externally and received by sensors or integrated systems. Additionally, events may be generated internally to trigger decoupled updates or plans of activity.&lt;/li&gt;&lt;/ul&gt;&lt;div&gt;&lt;span style="font-size: large;"&gt;5 Reactive and Hybrid Agents&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Subsumption architecture: no complex symbolic reasoning and many behavious can 'fire' simultaneously.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: large;"&gt;6 Multiagent Interactions&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Utility function are just a way of representing an agent's preferences.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Dominant strategies.&lt;br /&gt;We will say that a strategy si is dominant for player i if, no matter what strategy sj agent j choose, i will do at least as well playing si as it would doing anything else.&lt;br /&gt;A strategy si for agent i is dominant if it is the best response to all of agent j's strategies.&lt;br /&gt;Nash equilibria&lt;br /&gt;The mutual form of an equilibrium is important because it locks the agents in to a pair of strategies. Neither agent has any incentive to deviate from a Nash equilibrium.&lt;br /&gt;Mixed strategies and Nash's theorem&lt;br /&gt;Sometimes, it can be useful to introduce randomness or uncertainty into our actions.&lt;br /&gt;Every game in which every player has a finite set of possible strategies has a Nash equilibrium in mixed strategies.&lt;br /&gt;Pareto efficiency&lt;br /&gt;Pareto efficiency/optimality is not really a solution concept so much as a property of solution. It is &amp;nbsp;a criterion that desirable solutions should satisfy.&lt;br /&gt;We will say that an outcome is Pareto efficient if there is no other outcome that improves one player's utility without making somebody else worse off. Conversely, an outcome is said to be Pareto inefficient if there is another outcome that makes at least one player better off without making anybody else worse off.&lt;br /&gt;While Pareto efficiency is an important property of outcomes, it is perhaps not very useful as a way of selecting outcomes.&lt;br /&gt;Maximizing social welfare&lt;br /&gt;Social welfare is an important property of outcomes, but is not generally a way of directly selecting outcomes.&lt;br /&gt;Maximizing social welfare becomes relevant &amp;nbsp;if all the agents within a system have the same owner.&lt;br /&gt;Competitive and Zero-Sum Interactions&lt;br /&gt;The preferences of the players are diametrically opposed to one another: one agent can only improve its lot at the expense of the other.(strictly competitive)&lt;br /&gt;Zero-sum encounters are those in which, for any particular outcome, the utilities of the two agents sum to zero.&lt;br /&gt;The Prisoner's Dilemma&lt;br /&gt;The result seems to imply that cooperation can only arise as a result of irrational&amp;nbsp;behavior, and that cooperative&amp;nbsp;behavior&amp;nbsp;can be exploited by those who behave rationally.&lt;br /&gt;Rational cooperation is possible in the iterated prisoner's dilemma with an infinite number of rounds.&lt;br /&gt;Even though a cooperative agent can suffer when playing against a defecting opponent, it can do well overall provided it it gets&amp;nbsp;sufficient&amp;nbsp;opportunity to interact with other cooperative agents.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: large;"&gt;7 Reaching Agreements&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Mechanism design is the design of protocols for governing multiagent interaction, such that these protocols have certain desirable properties.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;An auction takes place between an agent known as the auctioneer and a collection of agents known as the bidders. The goal of the auction is for the auctioneer to allocate the good to one of the bidders.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Negotiation: agent must reach agreements on the matters of mutual interest. &lt;br /&gt;&lt;/div&gt;&lt;div&gt;Argumentation&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: large;"&gt;8 Communication&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;A certain class of natural language utterances - speech acts - had the characteristics of actions, in the sense that they change the state of the world in a way analogous to physical actions.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The Knowledge Query and Manipulation Language(KQML) is a message-based language for agent communication which define a common format for messages.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The Knowledge Interchange Format(KIF) is a language intended to form the content parts of KQML messages. &lt;br /&gt;&lt;/div&gt;&lt;div&gt;Ontologies enable agents to agree on the terminology that they use to describe a domain.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;A DTD can be thought of as being analogous to the formal grammars used to define the syntax of programming languages.  &lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: large;"&gt;9 Working Together&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In parallel problem solving, the computational components are simply processors; a single node will be responsible for decomposing the overall problem into sub-components, allocating these to processors, and subsequently assembling the solution. The nodes are frequently assumed to be homogeneous in the sense that they do not have distinct expertise - they are simply processors to be exploited in solving the problem.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The Contract Net (CNET) protocol is a high-level protocol for achieving efficient cooperation through task sharing in networks of communicating problem solvers.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="font-size: large;"&gt;11 Applications&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Agent for information retrieval and management&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The most obvious difficulty from the point view of human users of the WWW is the 'information overload' problem. People get over-whelmed by the sheer amount of information available, making it hard for them to filter out the junk and irrelevancies and focus on what is important, and also to actively search for the right information.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In short, it is all too easy to become lost in cyberspace. When searching for a particular item of information, it is also easy for people to either miss or misunderstand things.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In multiagent information retrieval systems, each agent typically advertises its capabilities to some broker. Brokers come in several different types. They may be simply matchmakers or yellow page agent.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The goal of interface agents/expert assistants is to make computer programs that in certain circumstances could take the initiative, rather than wait for the user to spell out exactly what they wanted to do. This leads to the view of computer programs as cooperating with a user to achieve a task, rather than acting simply as servants.&lt;br /&gt;&lt;/div&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/5277669399194798662-7116466791999520445?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7116466791999520445/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7116466791999520445' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7116466791999520445'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7116466791999520445'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/11/introduction-to-multiagent-systems.html' title='An Introduction to MultiAgent Systems'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2277718023505126712</id><published>2009-11-02T00:40:00.000-08:00</published><updated>2009-11-02T01:00:41.931-08:00</updated><title type='text'>Digital signature and encryption</title><content type='html'>A digital signature or digital signature scheme is a mathematical scheme for demonstrating the authenticity of a digital message or document. A valid digital signature gives a recipient reason to believe that the message was created by a known sender(&lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;Authentication&lt;/span&gt;), and that it was not altered in transit(&lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;Integrity&lt;/span&gt;).&lt;div&gt;&lt;div&gt;A digital signature scheme typically consists of three algorithms:&lt;/div&gt;&lt;div&gt;&lt;ol&gt;&lt;li&gt;A key generation algorithm that selects a private key uniformly at random from a set of possible private keys. The algorithm outputs the private key and a corresponding public key.&lt;/li&gt;&lt;li&gt;A signing algorithm which, given a message and a &lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;private key&lt;/span&gt;, produces a signature.&lt;/li&gt;&lt;li&gt;A signature verifying algorithm which given a message, &lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;public key&lt;/span&gt; and a signature, either accepts or rejects.&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://upload.wikimedia.org/wikipedia/commons/thumb/2/2b/Digital_Signature_diagram.svg/800px-Digital_Signature_diagram.svg.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 600px; " src="http://upload.wikimedia.org/wikipedia/commons/thumb/2/2b/Digital_Signature_diagram.svg/800px-Digital_Signature_diagram.svg.png" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div&gt;Public-key cryptography&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The two main branches of public key cryptography are:&lt;/div&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://upload.wikimedia.org/wikipedia/commons/thumb/f/f9/Public_key_encryption.svg/250px-Public_key_encryption.svg.png"&gt;&lt;img style="float:right; margin:0 0 10px 10px;cursor:pointer; cursor:hand;width: 250px; height: 244px;" src="http://upload.wikimedia.org/wikipedia/commons/thumb/f/f9/Public_key_encryption.svg/250px-Public_key_encryption.svg.png" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;div&gt;&lt;ol&gt;&lt;li&gt;Public key encryption — a message encrypted with a &lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;recipient's public key&lt;/span&gt; cannot be decrypted by anyone except a possessor of the matching private key -- presumably, this will be the owner of that key and the person associated with the public key used. This is used for confidentiality.&lt;/li&gt;&lt;li&gt;Digital signatures — a message signed with a &lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;sender's private key&lt;/span&gt; can be verified by anyone who has access to the sender's public key, thereby proving that the sender had access to the private key (and therefore is likely to be the person associated with the public key used), and the part of the message that has not been tampered with. &lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&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/5277669399194798662-2277718023505126712?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2277718023505126712/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2277718023505126712' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2277718023505126712'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2277718023505126712'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/11/digital-signature-and-encryption.html' title='Digital signature and encryption'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8450294419640830779</id><published>2009-10-26T22:52:00.000-07:00</published><updated>2009-10-26T22:53:22.114-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='AI'/><title type='text'>Artificial neural network</title><content type='html'>&lt;div&gt;There are three major learning paradigms, each corresponding to a particular abstract learning task. These are supervised learning, unsupervised learning and reinforcement learning. Usually any given type of network architecture can be employed in any of those tasks.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Supervised learning&lt;/div&gt;&lt;div&gt;Tasks that fall within the paradigm of supervised learning are pattern recognition (also known as classification) and regression (also known as function approximation). &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Unsupervised learning&lt;/div&gt;&lt;div&gt;Tasks that fall within the paradigm of unsupervised learning are in general estimation problems; the applications include clustering, the estimation of statistical distributions, compression and filtering.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Reinforcement learning&lt;/div&gt;&lt;div&gt;Tasks that fall within the paradigm of reinforcement learning are control problems, games and other sequential decision making tasks.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Application areas include system identification and control (vehicle control, process control), quantum chemistry,[1] game-playing and decision making (backgammon, chess, racing), pattern recognition (radar systems, face identification, object recognition and more), sequence recognition (gesture, speech, handwritten text recognition), medical diagnosis, financial applications (automated trading systems), data mining (or knowledge discovery in databases, "KDD"), visualization and e-mail spam filtering.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Feedforward neural network&lt;/div&gt;&lt;div&gt;The feedforward neural network was the first and arguably simplest type of artificial neural network devised. In this network, the information moves in only one direction, forward, from the input nodes, through the hidden nodes (if any) and to the output nodes. There are no cycles or loops in the network.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8450294419640830779?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8450294419640830779/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8450294419640830779' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8450294419640830779'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8450294419640830779'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/10/artificial-neural-network.html' title='Artificial neural network'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-336900683185764462</id><published>2009-10-21T01:12:00.000-07:00</published><updated>2009-10-21T01:13:20.851-07:00</updated><title type='text'>Petri net</title><content type='html'>&lt;div&gt;A Petri net (also known as a place/transition net or P/T net) is one of several mathematical modeling languages for the description of discrete distributed systems. &lt;/div&gt;&lt;div&gt; &lt;/div&gt;&lt;div&gt;A Petri net consists of places, transitions, and directed arcs. Arcs run between places and transitions, never between places or between transitions. The places from which an arc runs to a transition are called the input places of the transition; the places to which arcs run from a transition are called the output places of the transition.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Places may contain any non-negative number of tokens. A distribution of tokens over the places of a net is called a marking. A transition of a Petri net may fire whenever there is a token at the end of all input arcs; when it fires, it consumes these tokens, and places tokens at the end of all output arcs. A firing is atomic, i.e., a single non-interruptible step.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-336900683185764462?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/336900683185764462/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=336900683185764462' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/336900683185764462'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/336900683185764462'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/10/petri-net.html' title='Petri net'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5485066111409244566</id><published>2009-10-21T01:10:00.000-07:00</published><updated>2009-10-27T00:50:55.590-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='AI'/><title type='text'>Reinforcement Learning</title><content type='html'>&lt;div&gt;Reinforcement learning is learning what to do--how to map situations to actions--so as to maximize a numerical reward signal.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The agent has to exploit what it already knows in order to obtain reward, but it also has to explore in order to make better action selections in the future. The agent must try a variety of actions and progressively favor those that appear to be best. &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5485066111409244566?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5485066111409244566/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5485066111409244566' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5485066111409244566'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5485066111409244566'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/10/reinforcement-learning.html' title='Reinforcement Learning'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7173074145075062890</id><published>2009-10-06T18:28:00.000-07:00</published><updated>2009-10-22T19:22:04.508-07:00</updated><title type='text'>Learning theory</title><content type='html'>&lt;div&gt;&lt;div&gt;There are three main categories or philosophical frameworks under which learning theories fall: behaviorism, cognitivism, and constructivism. &lt;/div&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt;Behaviorism focuses only on the objectively observable aspects of learning. &lt;/li&gt;&lt;li&gt;Cognitive theories look beyond behavior to explain brain-based learning. &lt;/li&gt;&lt;li&gt;And constructivism views learning as a process in which the learner actively constructs or builds new ideas or concepts.&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The effective learning is learner centered, knowledge centered, assessment centered, and community centered.&lt;/div&gt;&lt;/div&gt;          “new science of learning,” Bransford, Brown, and Cocking (1999)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-7173074145075062890?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7173074145075062890/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7173074145075062890' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7173074145075062890'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7173074145075062890'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/10/elearning.html' title='Learning theory'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5030361946385215470</id><published>2009-09-07T00:41:00.000-07:00</published><updated>2010-02-07T20:04:40.624-08:00</updated><title type='text'>Head first design patterns</title><content type='html'>&lt;b&gt;&lt;span style="color: #000099;"&gt;Chapter 1 (Strategy)&lt;/span&gt;&lt;/b&gt; &lt;br /&gt;&lt;div&gt;Instead of code reuse, with patterns you get experinece reuse.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Design Principle&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Identify the aspects of your applicaion that vary and seperate them from what stays the same.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Program to an interface, not an implementation.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Favor composition over inheritance.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Program to an implementation would be &lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;pre class="brush: java"&gt;Dog d = new Dog();&lt;br /&gt;d.bark();&lt;br /&gt;&lt;/pre&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;Program to an interface would be &lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;pre class="brush: java"&gt;Animal a = new Dog();&lt;br /&gt;a.makeSound();&lt;br /&gt;&lt;/pre&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Good OO designs are reuseable, extensiable and maitainable. &lt;/div&gt;&lt;div&gt;Most of patterns are principles address issues of change in software.&lt;/div&gt;&lt;div&gt;Most of patterns allow some part of a system to vary independly of all other part. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The Strategy pattern defines a family of algorithms, encapasulates each ones, and make them interchangable. Strategy let the algorithm vary independently from clients that use it. &lt;/div&gt;&lt;div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://caterpillar.onlyfun.net/Gossip/DesignPattern/images/Strategy-2.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="97" src="http://caterpillar.onlyfun.net/Gossip/DesignPattern/images/Strategy-2.jpg" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;&lt;span style="color: #000099;"&gt;Chapter 2(Observer) &lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;Publisher(Subject) + Subscribers(Observers) = Observer Pattern&lt;/div&gt;&lt;div&gt;The Observer pattern defines a one to many dependency between objects so that when one object changes state, all of its dependents are notified and updated automatically. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;Design Principle&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Strive for loosely coupled designs between objects that interact.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Java has build-in support for Observer, which are Observer interface and Observable class in the java.util package. Both JavaBean and Swing(addListener) also provide their own implementation of Observer Pattern.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Don't depend on a specific order of notification for your observers.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;b&gt;&lt;span style="color: #000099;"&gt;Chapter 3 (Decorator)&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;The Decorator Pattern attaches additional responsibilities to an object dynamically.Decorators provide a flexible alternative to subclassing for extending functionality.&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://caterpillar.onlyfun.net/Gossip/DesignPattern/images/Decorator-2.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="271" src="http://caterpillar.onlyfun.net/Gossip/DesignPattern/images/Decorator-2.jpg" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;span style="white-space: normal;"&gt;&lt;b&gt;Design Principle&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Classes should be open for extension, but closed for modification. &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;Applying the Open-Closed Principle EVERYWHERE is wasteful, unnecessary, and can lead to complex, hard to understand code. Decorators have the same supertype as the objects they decorate. You can use one or more decorators to wrap an object. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;Given that the decorator has the same supertype as the object it decorates, we can pass around a decorated object in place of the original (wrapped) object.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;Java I/O package is largely based on Decorator. (FileInputStream, BufferedInputStream, &lt;span style="white-space: pre;"&gt;&lt;/span&gt;LineNumberStream)&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;b&gt;Dark side&lt;/b&gt;: Decorator Pattern sometimes adds a lot of small classes to a design and this occasionally results in a design that’s less than straightforward for others to understand.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;You can usually insert decorators transparently and the client never has to know it’s dealing with a decorator. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;But some code is dependent on specific types and when you start introducing decorators, boom! Bad things happen.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;Composition and delegation can often be used to add new behaviors at runtime.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;Decorator classes mirror the type of the components they decorate. (In fact, they are the same type as the components they decorate, either through inheritance or interface implementation.)&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;You can wrap a component with any number of decorators. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;Decorators are typically transparent to the client of the component; that is, unless the client is relying on the component’s concrete type. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;Decorators can result in many small objects in our design, and overuse can be complex.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;b&gt;&lt;span style="color: #000099;"&gt;Chapter 4 (Factory)&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;When you see "new", think "concrete". When you see new you are certainly instantiating a concrete class,&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;so that's definitly an implementation, not an interface.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;A factory method handles object creation and encapsulate it in a subclass. This decouple the client code in the&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;superclass from the object creation code in the subclass.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;The factory method pattern defines an interface for creating an object, but let subclass to decide thich &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;class to instanticate. Factory mechod lets the class defer instantiation to subclass.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div class="separator" style="clear: both; text-align: center;"&gt;&lt;a href="http://caterpillar.onlyfun.net/Gossip/DesignPattern/images/FactoryMethod-1.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="150" src="http://caterpillar.onlyfun.net/Gossip/DesignPattern/images/FactoryMethod-1.jpg" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;&lt;span style="white-space: pre;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;span style="font-weight: bold; white-space: normal;"&gt;Design Principle&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Depend upon abstractions. Do not depend upon concrete classes. &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;&lt;b&gt;The Abstract Factory Pattern&lt;/b&gt; provides an interface for creating families of related or depend objects&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;without specifying their concrete classes. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span style="white-space: pre;"&gt;Abstract Factory allow a client to use an abstract interface to create a set of related products without knowing or caring about the concrete products that are actually produced. &lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;b&gt;&lt;span style="color: blue;"&gt;Chapter 5 (Singleton Pattern) &lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;The Singleton pattern ensures a class has only one intance, and provide a global single point of access to it.&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;Just keep in mind that synchronizing a method can decrease performance by a factor of 100.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;&lt;span style="color: blue;"&gt;Chapter 6 (Command Pattern)&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;The Command Pattern encapsulates a request as an object, thereby letting you parameterize other objects with different requests, queue or log requests, and support undoable operations.&lt;br /&gt;&lt;br /&gt;A null object is useful when you don't have a meaningful object to return, and yet you want to remove the responsibility for handling null from the client. The null object will act as a surrogate and do nothing when its execute method is called.&lt;br /&gt;&lt;br /&gt;Chapter 7 (Adapter and Facade Pattern)&lt;br /&gt;The Adapter Pattern converts the interface of a class into another interface the clients expect. Adapter lets classes work together that couldn't otherwise because of&amp;nbsp;incompatible&amp;nbsp;interfaces.&lt;br /&gt;&lt;br /&gt;Design Principle:&lt;br /&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Principle of Least Knowledge - talk only to your immediate friends.&lt;/span&gt;&lt;br /&gt;This principle prevents us from creating designs that have a large number of classes coupled together so that changes in one part of they system cascade to other classes.&lt;br /&gt;&lt;br /&gt;Chapter 8 (Template Method Pattern)&lt;br /&gt;The Template Method Pattern defines the skeleton of an algorithm in a method, deferring some steps to subclasses. Template Method lets subclasses redefine certain steps of an algorithm without changing the algorithm's structure.&lt;br /&gt;&lt;br /&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Design Principle:&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;The Hollywood Principle: Don't call us, we'll call you.&lt;/span&gt;&lt;/div&gt;&lt;div&gt;With the Hollywood Principle, we allow low-level components to hook themselves into a system, but the high-level components determine when they are needed, and how.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;Chapter 9 (Iterator and Composite Pattern)&lt;br /&gt;The Iterator Pattern provides a way to access the elements of an aggregate object sequentially without exposing its underlying representation.&lt;br /&gt;&lt;br /&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;Design Principle:&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;A class should have only one reason to change.&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;Cohesion is a term you will hear used as a measure of how closely a class or a module supports a single purpose or responsibility.&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The Composite Pattern allows you to compose objects into tree structures to represent part-whole hierarchies. Composite lets clients treat individual objects and compositions of objects uniformly.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;Chapter 10 (State Pattern)&lt;br /&gt;The state Pattern allows an object to alter its behavior when its internal state changes. The object will appear to change its class.&lt;br /&gt;&lt;br /&gt;Chapter 11 (Proxy Pattern)&lt;br /&gt;The Proxy Pattern provides a surrogate or placeholder for another object to control access to it.&lt;br /&gt;&lt;br /&gt;Chapter 12 (Compound Pattern)&lt;br /&gt;A compound pattern combines two or more patterns into a solution that solves a recurring or general problem.&lt;br /&gt;&lt;br /&gt;Chapter 13 (Pattern in the real world)&lt;br /&gt;A Pattern is a solution to a problem in a context.&lt;br /&gt;Refactoring time is a Patterns time!&lt;br /&gt;Take out what you don't really need. Don't be afraid to remove a Design Pattern from your design.&lt;br /&gt;If you don't need it now, don't do it now.&lt;br /&gt;The beginner uses patterns everywhere.&lt;br /&gt;As learning progresses, the Intermediate mind states to see where patterns are needed and where they aren't.&lt;br /&gt;The Zen mid is able to see patterns where they fit naturally.&lt;br /&gt;When you use Design Patterns, there can also be a downside. Design Patterns often introduce additional classes and objects, and so they can increase the complexity of your designs. Design Pattern can also add more layers to your design, which adds not only complexity, but also inefficiency.&lt;br /&gt;&lt;br /&gt;Chapter 14 (Leftover Patterns)&lt;br /&gt;Bridge&lt;br /&gt;Builder&lt;br /&gt;Chain of Responsibility&lt;br /&gt;Flyweight&lt;br /&gt;Interpreter&lt;br /&gt;Mediator&lt;br /&gt;Memento&lt;br /&gt;Prototype&lt;br /&gt;Visitor&lt;br /&gt;&lt;br /&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/5277669399194798662-5030361946385215470?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5030361946385215470/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5030361946385215470' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5030361946385215470'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5030361946385215470'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/09/head-first-design-patterns.html' title='Head first design patterns'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-337938831384206765</id><published>2009-08-17T06:20:00.000-07:00</published><updated>2009-08-17T06:33:52.309-07:00</updated><title type='text'>STL</title><content type='html'>&lt;tr&gt;&lt;th&gt;&lt;h3&gt;&lt;/h3&gt;&lt;/th&gt;&lt;th&gt;&lt;span class="Apple-style-span"   style=" font-weight: normal;  line-height: 19px; font-family:-webkit-sans-serif;font-size:13px;"&gt;&lt;table class="wikitable" style="font-size: 13px; color: black; background-color: rgb(249, 249, 249); margin-top: 1em; margin-right: auto; margin-bottom: 1em; margin-left: auto; background-image: initial; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; border-collapse: collapse; background-position: initial initial; "&gt;&lt;tbody&gt;&lt;tr&gt;&lt;th style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; background-image: initial; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: rgb(242, 242, 242); text-align: center; background-position: initial initial; "&gt;Container&lt;/th&gt;&lt;th style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; background-image: initial; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: rgb(242, 242, 242); text-align: center; background-position: initial initial; "&gt;Description&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;th colspan="2" style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; background-image: initial; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: rgb(242, 242, 242); text-align: center; background-position: initial initial; "&gt;&lt;a href="http://en.wikipedia.org/wiki/List_(computing)" title="List (computing)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;Sequences&lt;/a&gt; (Arrays / &lt;a href="http://en.wikipedia.org/wiki/Linked_List" title="Linked List" class="mw-redirect" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;Linked Lists&lt;/a&gt;) - ordered collections&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;&lt;a href="http://en.wikipedia.org/wiki/Vector_(STL)" title="Vector (STL)" class="mw-redirect" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;vector&lt;/a&gt;&lt;/b&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;a &lt;a href="http://en.wikipedia.org/wiki/Dynamic_array" title="Dynamic array" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;dynamic array&lt;/a&gt;, like &lt;a href="http://en.wikipedia.org/wiki/C_(programming_language)" title="C (programming language)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;C&lt;/a&gt; array (i.e., capable of &lt;a href="http://en.wikipedia.org/wiki/Random_access" title="Random access" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;random access&lt;/a&gt;) with the ability to resize itself automatically when inserting or erasing an object. Inserting and removing an element to/from back of the vector at the end takes &lt;a href="http://en.wikipedia.org/wiki/Amortized" title="Amortized" class="mw-redirect" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;amortized&lt;/a&gt; constant time. Inserting and erasing at the beginning or in the middle is linear in time.&lt;p style="margin-top: 0.4em; margin-right: 0px; margin-bottom: 0.5em; margin-left: 0px; line-height: 1.5em; "&gt;A specialization for type &lt;a href="http://en.wikipedia.org/wiki/Bool" title="Bool" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;bool&lt;/a&gt; exists, which optimizes for space by storing &lt;a href="http://en.wikipedia.org/wiki/Bool" title="Bool" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;bool&lt;/a&gt; values as bits.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;list&lt;/b&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;a &lt;a href="http://en.wikipedia.org/wiki/Doubly_linked_list" title="Doubly linked list" class="mw-redirect" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;doubly&lt;/a&gt;-&lt;a href="http://en.wikipedia.org/wiki/Linked_list" title="Linked list" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;linked list&lt;/a&gt;; elements are not stored in contiguous memory. Opposite performance from a vector. Slow lookup and access (linear time), but once a position has been found, quick insertion and deletion (constant time).&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;&lt;a href="http://en.wikipedia.org/wiki/Deque" title="Deque" class="mw-redirect" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;deque&lt;/a&gt;&lt;/b&gt; (&lt;i&gt;double ended &lt;a href="http://en.wikipedia.org/wiki/Queue_(data_structure)" title="Queue (data structure)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;queue&lt;/a&gt;&lt;/i&gt;)&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;a vector with insertion/erase at the beginning or end in amortized constant time, however lacking some guarantees on iterator validity after altering the deque.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;th colspan="2" style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; background-image: initial; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: rgb(242, 242, 242); text-align: center; background-position: initial initial; "&gt;&lt;a href="http://en.wikipedia.org/wiki/Associative_array" title="Associative array" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;Associative containers&lt;/a&gt; - unordered collections&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;&lt;a href="http://en.wikipedia.org/wiki/Set_(computer_science)" title="Set (computer science)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;set&lt;/a&gt;&lt;/b&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;a sorted &lt;a href="http://en.wikipedia.org/wiki/Set_(computer_science)" title="Set (computer science)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;set&lt;/a&gt;; inserting/erasing elements in a set does not invalidate iterators pointing in the set. Provides set operations &lt;a href="http://en.wikipedia.org/wiki/Union_(set_theory)" title="Union (set theory)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;union&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Intersection_(set_theory)" title="Intersection (set theory)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;intersection&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Set_difference" title="Set difference" class="mw-redirect" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;difference&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Symmetric_difference" title="Symmetric difference" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;symmetric difference&lt;/a&gt; and test of inclusion. Type of data must implement comparison operator &lt;code style="background-color: rgb(249, 249, 249); "&gt;&lt;&lt;/code&gt; or custom comparator function must be specified. Implemented using a &lt;a href="http://en.wikipedia.org/wiki/Self-balancing_binary_search_tree" title="Self-balancing binary search tree" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;self-balancing binary search tree&lt;/a&gt;.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;multiset&lt;/b&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;same as a set, but allows duplicate elements.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;&lt;a href="http://en.wikipedia.org/wiki/Map_(C%2B%2B_container)" title="Map (C++ container)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;map&lt;/a&gt;&lt;/b&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;a sorted &lt;a href="http://en.wikipedia.org/wiki/Associative_array" title="Associative array" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;associative array&lt;/a&gt;; allows mapping from one data item (a key) to another (a value). Type of key must implement comparison operator &lt;code style="background-color: rgb(249, 249, 249); "&gt;&lt;&lt;/code&gt; or custom comparator function must be specified. Implemented using a self-balancing binary search tree.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;multimap&lt;/b&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;same as a map, but allows duplicate keys.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;hash_set&lt;/b&gt;&lt;br /&gt;&lt;p style="margin-top: 0.4em; margin-right: 0px; margin-bottom: 0.5em; margin-left: 0px; line-height: 1.5em; "&gt;&lt;b&gt;hash_multiset&lt;/b&gt;&lt;br /&gt;&lt;b&gt;hash_map&lt;/b&gt;&lt;br /&gt;&lt;b&gt;hash_multimap&lt;/b&gt;&lt;/p&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;similar to a set, multiset, map, or multimap, respectively, but implemented using a &lt;a href="http://en.wikipedia.org/wiki/Hash_table" title="Hash table" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;hash table&lt;/a&gt;; keys are not sorted, but a &lt;a href="http://en.wikipedia.org/wiki/Hash_function" title="Hash function" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;hash function&lt;/a&gt; must exist for key type. These &lt;a href="http://en.wikipedia.org/wiki/Container_(data_structure)" title="Container (data structure)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;containers&lt;/a&gt; are not part of the C++ Standard Library, but are included in SGI's STL extensions, and are included in common libraries such as the GNU C++ Library in the &lt;code style="background-color: rgb(249, 249, 249); "&gt;__gnu_cxx&lt;/code&gt; namespace. These are scheduled to be added to the C++ standard as part of &lt;a href="http://en.wikipedia.org/wiki/Technical_Report_1" title="Technical Report 1" class="mw-redirect" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;TR1&lt;/a&gt;, with the slightly different names of unordered_set, unordered_multiset, &lt;a href="http://en.wikipedia.org/wiki/Unordered_map_(C%2B%2B_class)" title="Unordered map (C++ class)" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;unordered_map&lt;/a&gt; and unordered_multimap.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;th colspan="2" style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; background-image: initial; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: rgb(242, 242, 242); text-align: center; background-position: initial initial; "&gt;Other types of containers&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;bitset&lt;/b&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;stores series of bits similar to a fixed-sized vector of bools. Implements bitwise operations and lacks iterators. Not a Sequence.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;&lt;b&gt;valarray&lt;/b&gt;&lt;/td&gt;&lt;td style="border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-color: rgb(170, 170, 170); border-right-color: rgb(170, 170, 170); border-bottom-color: rgb(170, 170, 170); border-left-color: rgb(170, 170, 170); border-top-style: solid; border-right-style: solid; border-bottom-style: solid; border-left-style: solid; padding-top: 0.2em; padding-right: 0.2em; padding-bottom: 0.2em; padding-left: 0.2em; "&gt;another C-like array like vector, but is designed for high speed numerics at the expense of some programming ease and general purpose use. It has many features that make it ideally suited for use with vector processors in traditional vector supercomputers and SIMD units in consumer-level scalar processors, and also ease vector mathematics programming even in scalar computers.&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3   style="color: black; background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; font-weight: bold; margin-top: 0px; margin-right: 0px; margin-bottom: 0.3em; margin-left: 0px; padding-top: 0.5em; padding-bottom: 0.17em; border-bottom-width: initial; border-bottom-style: none; border-bottom-  background-position: initial initial; font-size:17px;color:initial;"&gt;&lt;span class="Apple-style-span"  style="font-size:7;"&gt;&lt;span class="Apple-style-span" style="font-size: 48px; font-weight: normal;"&gt;&lt;span class="Apple-style-span" style="font-size: 13px; "&gt;&lt;h3 style="color: black; background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; font-weight: bold; margin-top: 0px; margin-right: 0px; margin-bottom: 0.3em; margin-left: 0px; padding-top: 0.5em; padding-bottom: 0.17em; border-bottom-width: initial; border-bottom-style: none; border-bottom-color: initial; font-size: 17px; background-position: initial initial; "&gt;&lt;span class="mw-headline"&gt;Iterators&lt;/span&gt;&lt;/h3&gt;&lt;p style="margin-top: 0.4em; margin-right: 0px; margin-bottom: 0.5em; margin-left: 0px; line-height: 1.5em; "&gt;The STL implements five different types of &lt;a href="http://en.wikipedia.org/wiki/Iterator" title="Iterator" style="text-decoration: none; color: rgb(0, 43, 184); background-image: none; background-repeat: initial; background-attachment: initial; -webkit-background-clip: initial; -webkit-background-origin: initial; background-color: initial; background-position: initial initial; "&gt;iterators&lt;/a&gt;. These are &lt;i&gt;input iterators&lt;/i&gt; (which can only be used to read a sequence of values), &lt;i&gt;output iterators&lt;/i&gt; (which can only be used to write a sequence of values),&lt;i&gt;forward iterators&lt;/i&gt; (which can be read, written to, and move forward), &lt;i&gt;bidirectional iterators&lt;/i&gt; (which are like forward iterators but can also move backwards) and &lt;i&gt;random access iterators&lt;/i&gt; (which can move freely any number of steps in one operation).&lt;/p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/h3&gt;&lt;/span&gt;&lt;/th&gt;&lt;/tr&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-337938831384206765?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/337938831384206765/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=337938831384206765' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/337938831384206765'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/337938831384206765'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/08/stl.html' title='STL'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-7430461689859783354</id><published>2009-08-17T02:33:00.000-07:00</published><updated>2009-08-17T03:52:54.308-07:00</updated><title type='text'>Multi-thread programming</title><content type='html'>Many modern operating systems directly support both time-sliced and multiprocessor threading with a process scheduler. The kernel of an operating system allows programmers to manipulate threads via the system call interface. Some implementations are called a kernel thread, whereas a lightweight process (LWP) is a specific type of kernel thread that shares the same state and information.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;Operating systems schedule threads in one of two ways:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt;Preemptive multithreading is generally considered the superior approach, as it allows the operating system to determine when a context switch should occur. The disadvantage to preemptive multithreading is that the system may make a context switch at an inappropriate time, causing priority inversion or other negative effects which may be avoided by cooperative multithreading.&lt;/li&gt;&lt;li&gt;Cooperative multithreading, on the other hand, relies on the threads themselves to relinquish control once they are at a stopping point. This can create problems if a thread is waiting for a resource to become available.&lt;/li&gt;&lt;/ul&gt;&lt;div&gt;&lt;div&gt;A process is the "heaviest" unit of kernel scheduling. Processes own resources allocated by the operating system. Resources include memory, file handles, sockets, device handles, and windows. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;A kernel thread is the "lightest" unit of kernel scheduling. At least one kernel thread exists within each process. If multiple kernel threads can exist within a process, then they share the same memory and file resources.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Threading APIs offer synchronization primitives such as mutexes to lock data structures against concurrent access.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;POSIX&lt;/span&gt; Threads, or &lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;Pthreads&lt;/span&gt;, is a POSIX standard for threads. The standard defines an API for creating and manipulating threads. Pthreads are most commonly used on Unix-like POSIX systems such as FreeBSD, NetBSD, GNU/Linux, Mac OS X and Solaris, but Microsoft Windows implementations also exist. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;POSIX &lt;/span&gt;(pronounced /ˈpɒzɪks/) or "Portable Operating System Interface [for Unix"] is the name of a family of related standards specified by the IEEE to define the application programming interface (API), along with shell and utilities interfaces for software compatible with variants of the Unix operating system, although the standard can apply to any operating system.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;Cygwin&lt;/span&gt; – enables partial POSIX compliance for certain Microsoft Windows products.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;A &lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;lock &lt;/span&gt;is a synchronization mechanism for enforcing limits on access to a resource in an environment where there are many threads of execution. Locks are one way of enforcing concurrency control policies.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The more coarse the lock, the higher the likelihood that the lock will stop an unrelated process from proceeding. Conversely, using a fine granularity (a larger number of locks, each protecting a fairly small amount of data) increases the overhead of the locks themselves but reduces lock contention. More locks also increase the risk of deadlock.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;A &lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;semaphore&lt;/span&gt; is a protected variable or abstract data type which constitutes the classic method for restricting access to shared resources such as shared memory in a parallel programming environment. A counting semaphore is a counter for a set of available resources, rather than a locked/unlocked flag of a single resource. It was invented by Edsger Dijkstra. Semaphores are the classic solution to preventing race conditions in the dining philosophers problem, although they do not prevent resource deadlocks.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;The value of a semaphore is the number of units of the resource which are free. (If there is only one resource, a "binary semaphore" with values 0 or 1 is used.) The P operation busy-waits (uses its turn to do nothing) or maybe sleeps (tells the system not to give it a turn) until a resource is available, whereupon it immediately claims one. V is the inverse; it simply makes a resource available again after the process has finished using it. Init is only used to initialize the semaphore before any requests are made.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Assume the resources are toilets in a public toilet. And the processes which want access to toilets are people either waiting in a queue for any toilet to be available or people who are already using the toilet. A person sitting outside the toilet keeps track of how many toilets are free at the moment and who should go in next.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The number of free toilets is the value of the semaphore indicating the number of free resources(toilets) available. When a process(person) wants access to a toilet the semaphore(incharge) will tell him whether he has to wait in the queue or whether he can use the toilet. If the toilet is free the person(process) gets the access and the number of free toilets is decreased by 1(same as P or down operation). It means number of free resources is less by 1. If the number of free toilets is 0 the person(process) has to wait in the queue till it becomes free(it means the process has to sleep till s&gt;0). Once the person uses the toilet(process finishes it work with the resource) the next person can use it.It means the number of free toilets is increased by 1(this is same as calling V or Up operation). Now s has become greater than 0 and the person waiting(process sleeping) can have access to the toilet(resource).&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;Mutual exclusion&lt;/span&gt; (often abbreviated to mutex) algorithms are used in concurrent programming to avoid the simultaneous use of a common resource, such as a global variable, by pieces of computer code called critical sections. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;A mutex is also a common name for a program object that negotiates mutual exclusion among threads, also called a lock.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;An &lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;event&lt;/span&gt; is a type of synchronization mechanism that is used to indicate to waiting processes when a particular condition has become true.&lt;/div&gt;&lt;div&gt;An event is an abstract data type with a boolean state and the following operations:&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;    * wait - when executed, causes the executing process to suspend until the event's state is set to true. If the state is already set to true has no effect.&lt;/div&gt;&lt;div&gt;    * set - sets the event's state to true, release all waiting processes.&lt;/div&gt;&lt;div&gt;    * clear - sets the event's state to false.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&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/5277669399194798662-7430461689859783354?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/7430461689859783354/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=7430461689859783354' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7430461689859783354'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/7430461689859783354'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/08/multi-thread-programming.html' title='Multi-thread programming'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-4054472804696524468</id><published>2009-08-16T23:16:00.000-07:00</published><updated>2009-08-16T23:27:56.453-07:00</updated><title type='text'>Message-oriented middleware (MOM)</title><content type='html'>Message-oriented middleware (MOM) is infrastructure focused on sending and receiving messages that increases the interoperability, portability, and flexibility of an application by allowing the application to be distributed over heterogeneous platforms.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;MOM comprises a category of inter-application communication software that generally relies on asynchronous message-passing, as opposed to a request-response metaphor.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Most message-oriented middleware depend on a message queue system, but there are some implementations that rely on broadcast or multicast messaging systems.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The primary advantage of a message-based communications protocol lies in its ability to store, route or transform messages in the process of delivery.&lt;/div&gt;&lt;div&gt;Storage, Routing, Transformation&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;The Java EE programming environment provides a standard API called JMS (Java Message Service), which is implemented by most MOM vendors and aims to hide the particular MOM API implementations; however, JMS does not define the format of the messages that are exchanged, so JMS systems are not interoperable. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Microsoft's MSMQ doesn't support JMS, although there are third-party products that can offer this.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The Advanced Message Queuing Protocol (AMQP) is an emerging standard that defines the protocol and formats used in the messaging server and client, so implementations are interoperable. AMQP is defined to provide flexible routing, including common messaging paradigms like point-to-point, fanout, publish/subscribe, and request-response. It also supports transaction management, queuing, distribution, security, management, clustering, federation and heterogeneous multi-platform support. &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/5277669399194798662-4054472804696524468?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/4054472804696524468/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=4054472804696524468' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4054472804696524468'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/4054472804696524468'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/08/message-oriented-middleware-mom.html' title='Message-oriented middleware (MOM)'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-8475376866358648685</id><published>2009-07-30T01:51:00.000-07:00</published><updated>2009-07-30T03:03:01.330-07:00</updated><title type='text'>Project Management</title><content type='html'>&lt;div&gt;Two of those techniques were called &lt;b&gt;Critical Path Management&lt;/b&gt; (CPM) and &lt;b&gt;Program Evaluation and Review Techniques&lt;/b&gt; (PERT). &lt;/div&gt;&lt;div&gt;They were similar and you will now often find the technique refered to as: CPM/PERT.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Once you've identified the critical path, any delay on any part of the critical path will cause a delay in the whole project.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In MS Project, you use the Tracking Gantt diagram to show the critical path in red and you can see the PERT diagram by looking at the Network view.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-8475376866358648685?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/8475376866358648685/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=8475376866358648685' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8475376866358648685'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/8475376866358648685'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/07/project-management.html' title='Project Management'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-253935740084201004</id><published>2009-07-28T03:04:00.000-07:00</published><updated>2009-07-28T03:05:07.602-07:00</updated><title type='text'>Web Application Framework</title><content type='html'>&lt;span class="Apple-style-span"  style="color:#FF0000;"&gt;Django&lt;/span&gt; (pronunciation: /ˈdʒæŋgoː/, JANG-goh[1]) is an open source web application framework, written in Python, which follows the model-view-controller architectural pattern.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-253935740084201004?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/253935740084201004/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=253935740084201004' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/253935740084201004'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/253935740084201004'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/07/web-application-framework.html' title='Web Application Framework'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-1716305657979866281</id><published>2009-07-14T01:23:00.000-07:00</published><updated>2009-07-14T01:55:40.009-07:00</updated><title type='text'>Enterprise Software</title><content type='html'>&lt;b&gt;&lt;span class="Apple-style-span"  style="font-size:large;"&gt;Enterprise resource planning (ERP)&lt;/span&gt;&lt;/b&gt;&lt;div&gt;&lt;div&gt;Enterprise resource planning (ERP) is a company-wide computer software system used to manage and coordinate all the resources, information, and functions of a business from shared data stores.[1]&lt;/div&gt;&lt;div&gt;An ERP system has a service-oriented architecture with modular hardware and software units and "services" that communicate on a local area network. The modular design allows a business to add or reconfigure modules (perhaps from different vendors) while preserving data integrity in one shared database that may be centralized or distributed.&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;The initials ERP originated as an extension of MRP (material requirements planning; later manufacturing resource planning) and CIM (Computer Integrated Manufacturing). ERP systems now attempt to cover all core functions of an enterprise, regardless of the organization's business or charter. These systems can now be found in non-manufacturing businesses, non-profit organizations and governments.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;To be considered an ERP system, a software package must provide the function of at least two systems. For example, a software package that provides both payroll and accounting functions could technically be considered an ERP software package.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Ideally, ERP delivers a single database that contains all data for the software modules, which would include:&lt;/div&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt;Manufacturing &lt;/li&gt;&lt;li&gt;Supply chain management &lt;/li&gt;&lt;li&gt;Financials &lt;/li&gt;&lt;li&gt;Project management &lt;/li&gt;&lt;li&gt;Human resources &lt;/li&gt;&lt;li&gt;Customer relationship management &lt;/li&gt;&lt;li&gt;Data warehouse&lt;/li&gt;&lt;li&gt;Access control&lt;/li&gt;&lt;li&gt;Customization&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div&gt;ERP systems typically handle the manufacturing, logistics, distribution, inventory, shipping, invoicing, and accounting for a company. ERP software can aid in the control of many business activities, including sales, marketing, delivery, billing, production, inventory management, quality management and human resource management.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Due to the complexities of most ERP systems and the negative consequences of a failed ERP implementation, most vendors have included "Best Practices" into their software. These "Best Practices" are what the Vendor deems as the most efficient way to carry out a particular business process in an Integrated Enterprise-Wide system.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;ERP vendors have designed their systems around standard business processes, based upon best business practices. Different vendor(s) have different types of processes but they are all of a standard, modular nature. Firms that want to implement ERP systems are consequently forced to adapt their organizations to standardized processes as opposed to adapting the ERP package to the existing processes.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;b&gt;&lt;span class="Apple-style-span"  style="font-size:large;"&gt;SAP ERP Enterprise Resource Planning (ERP) &lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;SAP AG is the largest European software enterprise, with headquarters in Walldorf, Germany.&lt;/div&gt;&lt;div&gt;SAP is the world's largest business software company and the third-largest independent software provider in terms of revenues.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Service-oriented architecture moves the ERP (Enterprise Resource Planning) landscape toward software-based and web services-based business activities. This move increases adaptability, flexibility, openness and efficiency. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;While its original products were typically used by Fortune 500 companies[citation needed], SAP is now also actively targeting small and medium sized enterprises (SME) with its SAP Business One and SAP Business All-in-One.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span"  style="font-size:large;"&gt;&lt;b&gt;PeopleSoft&lt;/b&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;PeopleSoft, Inc. was a company that provided human resource management systems (HRMS), customer relationship management (CRM), manufacturing, financials, enterprise performance management, and student administration software solutions to large corporations, governments, and organizations. The Oracle Corporation acquired PeopleSoft,Inc..&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;PeopleSoft's product suite (also called PeopleSoft) was initially based on a client-server architecture. The entire software suite moved to a web-centric design called Pure Internet Architecture (PIA) with the release of PeopleSoft Version 8. The new format allowed all of a company's business functions to be accessed and run on a web browser. &lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The architecture is built around PeopleSoft’s proprietary PeopleTools technology. PeopleTools includes many different components a developer needs to create Web-based application using a SQL database; including a scripting language called PeopleCode, design tools to define various types of metadata, standard security structure, and batch processing tools. The metadata describes data for user interfaces, tables, messages, security, navigation, portals, and so forth. The benefit of creating their own development platform allowed PeopleSoft applications to run on top of many different operating systems and database platforms. Currently, it is not tied to any specific database platform.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;As of 2008[3], Doris Wong of Oracle quoted the following statistics about PeopleSoft in use:&lt;/div&gt;&lt;div&gt;&lt;ul&gt;&lt;li&gt;9 of top 10 commercial banks are PS customers&lt;/li&gt;&lt;li&gt;59% of top 100 of fortune 500 companies own PS&lt;/li&gt;&lt;li&gt;Retail - the 5 biggest use PS&lt;/li&gt;&lt;li&gt;6 of top 10 communications companies use PeopleSoft&lt;/li&gt;&lt;li&gt;60% of the top 15 insurance companies use PeopleSoft&lt;/li&gt;&lt;li&gt;70% of top 10 health care organizations use PeopleSoft&lt;/li&gt;&lt;li&gt;19 US States use PeopleSoft&lt;/li&gt;&lt;li&gt;50 of largest US Counties and Cities use PeopleSoft&lt;/li&gt;&lt;li&gt;7 of top 10 Research universities use PeopleSoft&lt;/li&gt;&lt;li&gt;8 of top 10 printing and publishing companies use PeopleSoft&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;The largest PeopleSoft system currently planned is for the United States Department of Defense, which has over 10 million people on payroll.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"   style=" border-collapse: collapse;  line-height: 19px; -webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family:-webkit-sans-serif;font-size:13px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&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/5277669399194798662-1716305657979866281?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/1716305657979866281/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=1716305657979866281' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1716305657979866281'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/1716305657979866281'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/07/enterprise-software.html' title='Enterprise Software'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5677954778125703940</id><published>2009-07-13T23:15:00.000-07:00</published><updated>2009-07-13T23:16:12.528-07:00</updated><title type='text'>Ruby on Rails</title><content type='html'>Ruby on Rails, often shortened to Rails or RoR, is an open source web application framework for the Ruby programming language. It is intended to be used with an Agile development methodology which is used by web developers for rapid development.Like many contemporary web frameworks, Rails uses the Model-View-Controller (MVC) architecture pattern to organize application programming.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-5677954778125703940?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5677954778125703940/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5677954778125703940' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5677954778125703940'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5677954778125703940'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/07/ruby-on-rails.html' title='Ruby on Rails'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-826365616665176189</id><published>2009-07-13T04:19:00.000-07:00</published><updated>2009-07-13T04:25:56.578-07:00</updated><title type='text'>Six Sigma</title><content type='html'>&lt;div&gt;Six Sigma is a business management strategy, initially implemented by Motorola, that today enjoys widespread application in many sectors of industry.&lt;/div&gt;&lt;div&gt;Six Sigma seeks to improve the quality of process outputs by identifying and removing the causes of defects (errors) and variation in manufacturing and business processes.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Sigma (the lower-case Greek letter σ) is used to represent the standard deviation (a measure of variation) of a statistical population. The term "six sigma process" comes from the notion that if one has six standard deviations between the process mean and the nearest specification limit, there will be practically no items that fail to meet specifications.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-826365616665176189?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/826365616665176189/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=826365616665176189' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/826365616665176189'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/826365616665176189'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/07/six-sigma.html' title='Six Sigma'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-5324183877736604620</id><published>2009-07-13T04:10:00.000-07:00</published><updated>2009-07-13T04:17:20.121-07:00</updated><title type='text'>Agile software development</title><content type='html'>&lt;div&gt;Agile software development refers to a group of software development methodologies based on iterative development, where requirements and solutions evolve through collaboration between self-organizing cross-functional teams.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;Agile methods break tasks into small increments with minimal planning, and don't directly involve long-term planning. Iterations are short time frames ("timeboxes") that typically last from one to four weeks. Each iteration is worked on by a team through a full software development cycle including planning, requirements analysis, design, coding, unit testing, and acceptance testing when a working product is demonstrated to stakeholders. This helps minimize overall risk, and lets the project adapt to changes quickly.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;Test-driven development&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;Extreme Programming&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&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/5277669399194798662-5324183877736604620?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/5324183877736604620/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=5324183877736604620' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5324183877736604620'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/5324183877736604620'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/07/agile-software-development.html' title='Agile software development'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-3533285617341005721</id><published>2009-07-09T23:20:00.000-07:00</published><updated>2009-07-09T23:24:57.991-07:00</updated><title type='text'>DDoS attack</title><content type='html'>A denial-of-service attack (DoS attack) or distributed denial-of-service attack (DDoS attack) is an attempt to make a computer resource unavailable to its intended users.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/5277669399194798662-3533285617341005721?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/3533285617341005721/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=3533285617341005721' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3533285617341005721'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/3533285617341005721'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/07/ddos-attack.html' title='DDoS attack'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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-5277669399194798662.post-2401869019562000304</id><published>2009-07-09T23:01:00.000-07:00</published><updated>2010-03-07T22:22:47.292-08:00</updated><title type='text'>Wireless</title><content type='html'>&lt;span class="Apple-style-span" style="font-size: large;"&gt;4G&lt;/span&gt;&lt;br /&gt;&lt;div&gt;&lt;div&gt;A nominal data rate of 100 Mbit/s while the client physically moves at high speeds relative to the station, and 1 Gbit/s while client and station are in relatively fixed positions as defined by the ITU-R,&lt;/div&gt;&lt;div&gt;A data rate of at least 100 Mbit/s between any two points in the world,&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-size: large;"&gt;WiMax&lt;/span&gt;&lt;/div&gt;&lt;div&gt;WiMAX, meaning Worldwide Interoperability for Microwave Access, is a telecommunications technology that provides wireless transmission of data using a variety of transmission modes, from point-to-multipoint links to portable and fully mobile internet access. The technology provides up to 3 Mbit/s broadband speed without the need for cables. The technology is based on the IEEE 802.16 standard (also called Broadband Wireless Access).&lt;/div&gt;&lt;div&gt;&lt;div&gt;WiMAX is a term coined to describe standard, interoperable implementations of IEEE 802.16 wireless networks, similar to the way the term Wi-Fi is used for interoperable implementations of the IEEE 802.11 Wireless LAN standard.  &lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-size: x-large;"&gt;GPS&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: SimSun; font-size: 14px; line-height: 25px;"&gt;GPS的信号有两种C/A码，P码。&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: SimSun; font-size: 14px; line-height: 25px;"&gt;C/A码的误差是29.3m到2.93米。&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: SimSun; font-size: 14px; line-height: 25px;"&gt;P码的误差为2.93米到0.293米是C/A码的十分之一。但是P码只能美国军方使用，AS（Anti-Spoofing），是在P码上加上的干扰信号。&lt;/span&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/5277669399194798662-2401869019562000304?l=zl220.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://zl220.blogspot.com/feeds/2401869019562000304/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=5277669399194798662&amp;postID=2401869019562000304' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2401869019562000304'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5277669399194798662/posts/default/2401869019562000304'/><link rel='alternate' type='text/html' href='http://zl220.blogspot.com/2009/07/telecom.html' title='Wireless'/><author><name>Mr. Bright</name><uri>http://www.blogger.com/profile/09114266153155470744</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></feed>
