锘??xml version="1.0" encoding="utf-8" standalone="yes"?>BlogJava-Enjoy yourself,and don't care about others' thinking!http://www.67529968.com/TiGERTiAN/----TiGERTiANzh-cnMon, 25 Feb 2019 15:15:33 GMTMon, 25 Feb 2019 15:15:33 GMT60MVC/MVP/MVVMhttp://www.67529968.com/TiGERTiAN/archive/2017/05/10/432509.htmlTiGERTiANTiGERTiANWed, 10 May 2017 03:03:00 GMThttp://www.67529968.com/TiGERTiAN/archive/2017/05/10/432509.htmlhttp://www.67529968.com/TiGERTiAN/comments/432509.htmlhttp://www.67529968.com/TiGERTiAN/archive/2017/05/10/432509.html#Feedback0http://www.67529968.com/TiGERTiAN/comments/commentRss/432509.htmlhttp://www.67529968.com/TiGERTiAN/services/trackbacks/432509.html鍚?/h2>

濡傛灉鎶婅繖涓夎呮斁鍦?#28051;璧锋瘮杈冿紝鍏堣涓涓?#28051;夎呯殑鍏?#37722;?#37904;癸紝涔熷氨鏄疢odel鍜孷iew锛?/p>

  • Model锛氭暟鎹?#28725;?#29854;紝鍚屾椂?#32029;?#24385;渚涙湰搴旂敤澶栭儴瀵?#25652;旂敤绋?#25652;忔暟鎹殑鎿嶄綔?#27537;?#24116;鍙紝涔熷彲鑳?#37734;暟鎹?#37721;樺寲?#26882;鍙?#37713;?#37721;?#37831;撮氱煡銆?span style="box-sizing: border-box; outline: 0px !important; font-weight: 700;">Model涓?#28186;?#29863;栦簬View?#27537;?#30084;鐜?/span>?#32029;鍙?#29781;?#28598;栭儴绋?#25652;忚皟?#25956;Model?#27537;?#24116;鍙氨鑳?#28598;熷疄鐜?#28725;规暟鎹殑澧炲垹鏀规煡銆?/p>

  • View锛歎I灞傦紝?#24385;渚?#28725;规渶缁堢敤鎴风殑浜?#27996;?#37823;嶄綔鍔?#38003;斤紝鍖呮?#29716;I灞?#37916;?#28000;爜鍙?#28051;浜涚浉鍏崇殑鐣岄潰閫?#26440;?#28000;爜銆?/p>

寮?/h2>

涓夎呯殑宸?#23534;?#37734;簬濡備?#26336;鍚View鍜孧odel?#32029;?#30084;鐜扮敤鎴风殑浜?#27996;?#37823;嶄綔浠?#37721;?#37721;?#37831;撮氱煡

  • Controller

Controller?#24116;鏀View?#27537;鎿嶄綔浜嬩?#35769;紝鏍?#37817;?#27996;嬩欢涓?#37722;岋紝鎴?#38000;呰皟?#25956;Model?#27537;?#24116;鍙繘琛屾暟鎹?#37823;嶄綔?#32029;鎴?#38000;呰繘琛孷iew?#27537;?#28902;杞紝浠?#38000;?#28052;?#37808;忓?#23815;涓涓狢ontroller鍙?#28000;?#28725;?#25652;?#28598;?#28051;猇iew銆侰ontroller瀵筕iew?#27537;?#30084;鐜?#28051;?#28598;?#37711;?#36423;冿紝鍙細琚?#37716;?#37734;版帴鏀讹紝Model?#27537;?#26271;鎹?#37721;?#37831;?#28051;?#38315;氳繃Controller?#27967;?#24116;閫氱煡View?#32029;閫氬父View閲囩敤瑙?#28725;?#38000;呮寮?#37929;?#37722;琈odel?#27537;鍙樺寲銆?/p>

  • Presenter

Presenter涓嶤ontroller涓鏍凤紝?#24116;鏀View?#27537;?#25057;浠紝瀵筂odel?#32344;琛屾?#23940;綔锛?#28051;嶤ontroller涓?#37722;岀殑鏄Presenter?#32048;鍙嶄綔?#25956;?#31788;View?#32029;Model?#27537;鍙?#37831;撮氱煡棣?#37711;堣?#29571;resenter鑾峰緱?#32029;?#21159;鍚嶱resenter鍐嶅幓鏇存柊View銆?#28051;涓狿resenter鍙?#28725;?#25652;斾簬涓涓猇iew銆傛牴鎹甈resenter鍜孷iew瀵?#38315;?#26440;?#28000;?#37934;佸垎鎷呯殑绋?#25652;?#28051;?#37722;岋紝?#32342;绉?#22959;?#23534;?#37721;堟湁涓?#32457;?#37807;?#37712;?#38171;歅assive View鍜孲upervisor Controller銆?/p>

  • ViewModel

娉?#37808;忚繖閲岀殑“Model”鎸囩殑鏄疺iew?#27537;Model?#32029;?#31393;MVVM涓殑涓涓狹odel涓?#37828;?#28051;鍥?#27996;?#37510;傛墍璋揤iew?#27537;Model?#27688;鏄寘鍚View?#27537;涓浜涙暟鎹?#28766;?#37804;?#37724;屾?#23940;綔?#27537;?#32342;涔?#28051;涓?#28051;?#28051;滐紝?#32342;绉?#22959;?#23534;忕殑鍏?#38335;?#37814;鏈氨鏄暟鎹?#32513;?#28729;?#38171;data binding锛夛紝View?#27537;鍙樺寲浼氱洿?#24116;褰卞搷ViewModel?#32029;ViewModel?#27537;鍙樺寲鎴?#38000;?#37712;?#28729;?#28052;?#28028;氱洿?#24116;浣?#37916;?#37734;View涓?#37510;傝繖绉?#22959;?#23534;忓疄闄?#28051;?#37828;?#22935;嗘鏇?#25652;旂敤寮鍙?#38000;呭仛浜?#28051;浜?#23480;綔?#32029;寮鍙?#38000;?#37721;渶瑕?#26440;?#28751;戠殑浠?#37934;佸氨鑳藉疄鐜版瘮杈?#28598;嶆潅?#27537;浜?#27996;?#37510;?/p>

]]>Volley+Gson+MQTT?#30084;鐜?#28051;濂楁帴娲惧?#26336;郴缁?/title><link>http://www.67529968.com/TiGERTiAN/archive/2016/08/20/431647.html</link><dc:creator>TiGERTiAN</dc:creator><author>TiGERTiAN</author><pubDate>Sat, 20 Aug 2016 04:23:00 GMT</pubDate><guid>http://www.67529968.com/TiGERTiAN/archive/2016/08/20/431647.html</guid><wfw:comment>http://www.67529968.com/TiGERTiAN/comments/431647.html</wfw:comment><comments>http://www.67529968.com/TiGERTiAN/archive/2016/08/20/431647.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.67529968.com/TiGERTiAN/comments/commentRss/431647.html</wfw:commentRss><trackback:ping>http://www.67529968.com/TiGERTiAN/services/trackbacks/431647.html</trackback:ping><description><![CDATA[Volley闄嶄綆缃?#32513;?#27996;?#27996;?#28598;嶆潅搴?#38171;?br />Gson绠?#23538;浜Json?#27537;澶勭?#21997;紝浣垮緱瀵?#29854;?#37724;孞son鎶枃涔嬮棿?#27537;浜掔浉杞?#37817;?#37721;樺緱寰?#28729;?#37828;紝浠爜鏇?#32480;娲?#38171;?br />MQTT?#30084;鐜版?#22559;伅?#27537;鎺?#38315;?#26473;?#37828;?#23536;?#28051;?#38335;欑殑锛?img src ="http://www.67529968.com/TiGERTiAN/aggbug/431647.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.67529968.com/TiGERTiAN/" target="_blank">TiGERTiAN</a> 2016-08-20 12:23 <a href="http://www.67529968.com/TiGERTiAN/archive/2016/08/20/431647.html#Feedback" target="_blank" style="text-decoration:none;">鍙?#29723;?#29831;勮</a></div>]]></description></item><item><title>Android浼?#37808;熷櫒浠?#32513;?/title><link>http://www.67529968.com/TiGERTiAN/archive/2015/11/18/428265.html</link><dc:creator>TiGERTiAN</dc:creator><author>TiGERTiAN</author><pubDate>Wed, 18 Nov 2015 07:33:00 GMT</pubDate><guid>http://www.67529968.com/TiGERTiAN/archive/2015/11/18/428265.html</guid><wfw:comment>http://www.67529968.com/TiGERTiAN/comments/428265.html</wfw:comment><comments>http://www.67529968.com/TiGERTiAN/archive/2015/11/18/428265.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.67529968.com/TiGERTiAN/comments/commentRss/428265.html</wfw:commentRss><trackback:ping>http://www.67529968.com/TiGERTiAN/services/trackbacks/428265.html</trackback:ping><description><![CDATA[     鎽?#29781;? 澶?#28598;氭暟Android璁?#28598;囨湁鍐呯疆?#27537;浼?#37808;熷櫒?#32029;鏉祴閲忚繍鍔紝鏂?#37722;?#37724;?#37722;勭鐜?#28583;?#37833;?#28000;?#37510;傝繖浜涗紶鎰熷櫒鑳芥彁渚涢珮绮?#25652;?#37724;?#37713;?#32429;?#25652;殑鍘熷?#23339;暟鎹紝濡傛灉浣?#37807;崇洃鎺?#29825;?#28598;?#28051;?#32513;?#26473;?#37716;?#37812;?#38000;?#28003;?#32515;紝鎴?#38000;?#28003;?#37807;崇洃鎺?#29825;?#28598;囧懆?#27967;?#27537;鐜?#28583;?#37721;樺寲?#32029;鏄?#38344;炲父?#28225;?#25956;?#27537;銆?#28186;?#28641;傦紝?#29238;鎴?#37721;?#38003;?#29882;熻釜璁?#28598;?#38322;?#37716;涗紶鎰熷櫒?#27537;?#26271;鎹紝鏉?#37818;?#37826;?#28598;嶆潅?#27537;?#25956;鎴?#26851;栭鍜屽姩?#32148;?#32029;渚?#28641;傚?#37826;滐紝闇?#37716;紝鏃?#26462;紝鎴?#38000;呮尟骞?#37510;?#37722;屾?#39118;殑?#32029;澶?#23000;?#25652;旂敤鍙?#38003;?#28003;跨敤璁?#28598;囩殑娓?#25652;?#28028;?#37808;熷櫒鍜屾箍搴?#28028;?#37808;熷櫒?#27537;?#26271;鎹?#37833;?#29825;?#32480;?#37724;?#37814;憡缁?#38343;?#37904;癸紝鎴?#38000;呮?#21616;搴旂敤鍙?#38003;?#28003;跨敤?#37734;?#28028;?#37808;?..  <a href='http://www.67529968.com/TiGERTiAN/archive/2015/11/18/428265.html'>闃呰鍏枃</a><img src ="http://www.67529968.com/TiGERTiAN/aggbug/428265.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.67529968.com/TiGERTiAN/" target="_blank">TiGERTiAN</a> 2015-11-18 15:33 <a href="http://www.67529968.com/TiGERTiAN/archive/2015/11/18/428265.html#Feedback" target="_blank" style="text-decoration:none;">鍙?#29723;?#29831;勮</a></div>]]></description></item><item><title>OSGi and Hadoop and Node.jshttp://www.67529968.com/TiGERTiAN/archive/2015/02/23/422997.htmlTiGERTiANTiGERTiANMon, 23 Feb 2015 02:12:00 GMThttp://www.67529968.com/TiGERTiAN/archive/2015/02/23/422997.htmlhttp://www.67529968.com/TiGERTiAN/comments/422997.htmlhttp://www.67529968.com/TiGERTiAN/archive/2015/02/23/422997.html#Feedback0http://www.67529968.com/TiGERTiAN/comments/commentRss/422997.htmlhttp://www.67529968.com/TiGERTiAN/services/trackbacks/422997.htmlOpen Service Gateway initiative(寮?#25985;鏈?#37716;?#32515;?#37711;冲?#24538;)
http://www.osgi.org/Technology/HomePage

Hadoop
http://hadoop.apache.org/

Node.js
https://cnodejs.org/
http://nodejs.org/


]]>
javacc宸?#37711;峰?#24538;http://www.67529968.com/TiGERTiAN/archive/2015/01/31/422602.htmlTiGERTiANTiGERTiANSat, 31 Jan 2015 05:12:00 GMThttp://www.67529968.com/TiGERTiAN/archive/2015/01/31/422602.htmlhttp://www.67529968.com/TiGERTiAN/comments/422602.htmlhttp://www.67529968.com/TiGERTiAN/archive/2015/01/31/422602.html#Feedback0http://www.67529968.com/TiGERTiAN/comments/commentRss/422602.htmlhttp://www.67529968.com/TiGERTiAN/services/trackbacks/422602.htmlhttps://javacc.java.net/

Java Compiler Compiler tm (JavaCC tm) is the most popular parser generator for use with Java tm applications. A parser generator is a tool that reads a grammar specification and converts it to a Java program that can recognize matches to the grammar. In addition to the parser generator itself, JavaCC provides other standard capabilities related to parser generation such as tree building (via a tool called JJTree included with JavaCC), actions, debugging, etc.

涓?#26462;?#37722;庣殑浣跨敤鏂瑰紡锛圡ac&Linux锛?#38171;?br />

echo 'java -cp /path/to/javacc.jar $(basename $0) "$@"' > javacc

chmod 755 javacc

ln -s javacc jjtree

ln -s javacc jjdoc





]]>
杩?#37828;繖閲屾瘮杈?#28729;?#38344;?/title><link>http://www.67529968.com/TiGERTiAN/archive/2013/12/10/407419.html</link><dc:creator>TiGERTiAN</dc:creator><author>TiGERTiAN</author><pubDate>Tue, 10 Dec 2013 13:46:00 GMT</pubDate><guid>http://www.67529968.com/TiGERTiAN/archive/2013/12/10/407419.html</guid><wfw:comment>http://www.67529968.com/TiGERTiAN/comments/407419.html</wfw:comment><comments>http://www.67529968.com/TiGERTiAN/archive/2013/12/10/407419.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.67529968.com/TiGERTiAN/comments/commentRss/407419.html</wfw:commentRss><trackback:ping>http://www.67529968.com/TiGERTiAN/services/trackbacks/407419.html</trackback:ping><description><![CDATA[鏍?#37712;?-宸?#32513;?#28051;?#23534;?br />寰崥--寰?#28751;?#28051;?#27996;?br />鏈?#37721;?#37734;?-浜?#28598;?#28598;?br />铏?#37808;熻?#22796;浜?#28003;?#32495;昏秺鏉秺鍚?#32457;?#28725;嗗寲鍙?#28766;紝浣?#26473;?#37828;繖閲屽?#26020;紝娌?#27996;虹煡?#32029;娌?#27996;?#29831;嗭紝涔?#28051;嶄?#27693;湁閭?#28052;?#28598;?#27996;?#29831;勮鎴?#37721;戠殑涓?#29783;匡紝鎴?#38000;呮棤鑱婄殑鐐?#8220;璧?#8221;銆?br />鍓?#28051;?#39582;寸殑杩疯尗?#32029;鍒?#37916;?#37734;殑閲?#38014;锋柟鍚戯紝涔湰鑰?#28051;?#37828;?#27996;?#29825;?#37812;?#37808;熻鏇?#28729;?#36423;冿紝?#26537;娆仛涓涓?#37910;卞涔犵殑浜?#37510;傚墠閫?#37712;?#26473;疯尗?#32029;涔?#28051;?#38003;?#26473;?#28598;辫嚜宸?#38171;涢亾璺?#37712;嶈垝鏈嶏紝涔?#28051;?#38003;藉繕璁?#38007;?#23480;?#37510;?br />甯屾?#28060;嚜宸?#28051;?#29781;佹?#25118;祽鍣?#37731;氨?#32342;鏍?#29863;?#27996;?#37510;?br /><br /><br /><br /><br /><img src ="http://www.67529968.com/TiGERTiAN/aggbug/407419.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.67529968.com/TiGERTiAN/" target="_blank">TiGERTiAN</a> 2013-12-10 21:46 <a href="http://www.67529968.com/TiGERTiAN/archive/2013/12/10/407419.html#Feedback" target="_blank" style="text-decoration:none;">鍙?#29723;?#29831;勮</a></div>]]></description></item><item><title>鍧戠埞?#27537;Android?#26570;ADThttp://www.67529968.com/TiGERTiAN/archive/2013/05/13/399233.htmlTiGERTiANTiGERTiANMon, 13 May 2013 13:18:00 GMThttp://www.67529968.com/TiGERTiAN/archive/2013/05/13/399233.htmlhttp://www.67529968.com/TiGERTiAN/comments/399233.htmlhttp://www.67529968.com/TiGERTiAN/archive/2013/05/13/399233.html#Feedback0http://www.67529968.com/TiGERTiAN/comments/commentRss/399233.htmlhttp://www.67529968.com/TiGERTiAN/services/trackbacks/399233.html


]]>
濡備綍寮鍚疉ndroid鏂版墜鏈虹殑?#30367;璇?#22959;?#23534;?/title><link>http://www.67529968.com/TiGERTiAN/archive/2013/04/09/397602.html</link><dc:creator>TiGERTiAN</dc:creator><author>TiGERTiAN</author><pubDate>Tue, 09 Apr 2013 12:48:00 GMT</pubDate><guid>http://www.67529968.com/TiGERTiAN/archive/2013/04/09/397602.html</guid><wfw:comment>http://www.67529968.com/TiGERTiAN/comments/397602.html</wfw:comment><comments>http://www.67529968.com/TiGERTiAN/archive/2013/04/09/397602.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.67529968.com/TiGERTiAN/comments/commentRss/397602.html</wfw:commentRss><trackback:ping>http://www.67529968.com/TiGERTiAN/services/trackbacks/397602.html</trackback:ping><description><![CDATA[<span style="color: #444444; font-family: Tahoma, Helvetica, SimSun, sans-serif; background-color: #ffffff;">鍦?/system/etc/init.d ?#32342;涓?#37929;綍涓嬶紝?#28225;寰?#28598;氳?#27693;湰?#32029;鎶?#28729;?#28000;?#37711;儴瀵?#37713;?#38171;堟柟渚挎煡?#22744;锛?鏃?#37808;?#28051;?#37734;?99snakes ?#32342;涓枃浠舵壘鍒?#27996;?#28051;鍙?/span><div style="word-wrap: break-word; overflow: hidden; margin: 10px 0px; padding-top: 10px; padding-bottom: 5px; padding-left: 10px; background-image: url(http://bbs.gfan.com/static/image/gfan/codebg.gif); background-color: #f7f7f7; color: #666666; zoom: 1; border: 1px solid #cccccc; font-family: Tahoma, Helvetica, SimSun, sans-serif; background-position: 0px 0px; background-repeat: no-repeat repeat;"><div id="code_5ew" style="word-wrap: break-word;"><ol style="word-wrap: break-word; margin: 0px 0px 0px 10px !important; padding: 0px !important;"><li style="word-wrap: break-word; margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, 'Lucida Console', 'Courier New', serif; font-size: 12px; line-height: 1.8em;"># disable logger - (comment and reboot for logcat)<br style="word-wrap: break-word;" /></li><li style="word-wrap: break-word; margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, 'Lucida Console', 'Courier New', serif; font-size: 12px; line-height: 1.8em;">rm /dev/log/main</li></ol></div><em style="word-wrap: break-word; font-style: normal; color: #336699 !important; margin-left: 43px; font-size: 12px; cursor: pointer;">澶嶅埗浠爜</em></div><span style="color: #444444; font-family: Tahoma, Helvetica, SimSun, sans-serif; background-color: #ffffff;">鎰熷姩涓?#37510;?#37510;?#37510;傛妸rm /dev/log/main ?#32342;鍙幓鎺夊氨琛?#27996;唦閲?#37722;?#37722;?#28751;卞彲浠皟璇?#27996;嗭紝?#32342;涓?#28051;嶇敤鍒峰?#28850;師鐢熺殑鍐呮浜嗭紝鍝堝搱?#32029;鐖絶</span><img src ="http://www.67529968.com/TiGERTiAN/aggbug/397602.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.67529968.com/TiGERTiAN/" target="_blank">TiGERTiAN</a> 2013-04-09 20:48 <a href="http://www.67529968.com/TiGERTiAN/archive/2013/04/09/397602.html#Feedback" target="_blank" style="text-decoration:none;">鍙?#29723;?#29831;勮</a></div>]]></description></item><item><title>WindowsPhone涓?#29863;勬簮鍥?#38340;呭寲?#27537;寮鍙?/title><link>http://www.67529968.com/TiGERTiAN/archive/2012/09/14/387708.html</link><dc:creator>TiGERTiAN</dc:creator><author>TiGERTiAN</author><pubDate>Fri, 14 Sep 2012 03:28:00 GMT</pubDate><guid>http://www.67529968.com/TiGERTiAN/archive/2012/09/14/387708.html</guid><wfw:comment>http://www.67529968.com/TiGERTiAN/comments/387708.html</wfw:comment><comments>http://www.67529968.com/TiGERTiAN/archive/2012/09/14/387708.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.67529968.com/TiGERTiAN/comments/commentRss/387708.html</wfw:commentRss><trackback:ping>http://www.67529968.com/TiGERTiAN/services/trackbacks/387708.html</trackback:ping><description><![CDATA[1銆?#28725;逛簬搴旂敤鍚?#32457;?App Title)鍜屽紑濮?#28766;忓?#26336;殑蹇?#37817;锋?#29808;紡(Tile)鍚?#32457;帮紝?#28214;瑕?#37721;?#37907;?a href="http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff967550%28v=vs.92%29.aspx">http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff967550%28v=vs.92%29.aspx</a> 鏉?#23534;鍙戯紝?#32342;閲屾彁渚?#28051;涓?#36423;?#37817;风殑鐢?#37812;?#23480;?#37711;?a href="/Files/TiGERTiAN/WP7AppResLib.zip">/Files/TiGERTiAN/WP7AppResLib.zip<br /></a>鍦WMAppManifest.xml涓殑?#30367;?#25956;鏂瑰紡Title="@AppResLib.dll,-100"     <Title>@AppResLib.dll,-200</Title>?#32029;100鍜?00鍒?#37714;?#28725;?#25652;?#27996;咥pp Title鍜孴ile銆?br /><br />2銆?#37734;?#32459;?#25652;忓?#21615;殑鍥?#38340;呭寲?#32029;鍦?#23534;鍙?#23480;?#32459;?#28051;紝?#26570;寤?#28051;涓猂esource鐩綍?#32029;涓嬮潰?#26570;寤篈ppResource.resx璧勬簮?#32029;?#25313;瀵?#28051;?#37722;岃瑷鍙?#28000;?#23524;虹珛涓?#37722;岀殑璧勬簮AppResource.en-US.resx绛?#37510;?#37734;?#32459;?#25652;?#28051;洿?#24116;浣跨敤浠?#28051;?#37713;芥暟灏卞彲浠皟?#25956;宸?#32513;?#38320;?#32515;?#28610;界殑鍥?#38340;呭寲璧勬簮锛?br /><div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />-->        <span style="color: #0000FF; ">private</span> <span style="color: #0000FF; ">static</span> <span style="color: #0000FF; ">readonly</span> ResourceManager ResourceManager = <span style="color: #0000FF; ">new</span> ResourceManager("XXXX.Resource.AppResource", Assembly.GetExecutingAssembly());<br />        <br />        <span style="color: #0000FF; ">public</span> <span style="color: #0000FF; ">static</span> <span style="color: #0000FF; ">string</span> GetString(<span style="color: #0000FF; ">string</span> keyName)<br />        {<br />            <span style="color: #0000FF; ">return</span> Utilities.ResourceManager.GetString(keyName);<br />        }</div><br />3銆?#28725;逛簬?#28214;瑕?#37824;?#37816;佺殑璇?#29815;?#32029;杩?#29781;佷慨鏀筩sproj?#26499;浠讹紝?#24936;鏀?#28641;?#28051;?#38171;?br /><div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />-->    <span style="color: #0000FF; "><</span><span style="color: #800000; ">SilverlightApplication</span><span style="color: #0000FF; ">></span>true<span style="color: #0000FF; "></</span><span style="color: #800000; ">SilverlightApplication</span><span style="color: #0000FF; ">></span><br />    <span style="color: #0000FF; "><</span><span style="color: red; ">SupportedCultures</span><span style="color: #0000FF; ">></span>zh-CN;en-US;<br />    <span style="color: #0000FF; "></</span><span style="color: red; ">SupportedCultures</span><span style="color: #0000FF; ">></span><br />    <span style="color: #0000FF; "><</span><span style="color: #800000; ">XapOutputs</span><span style="color: #0000FF; ">></span>true<span style="color: #0000FF; "></</span><span style="color: #800000; ">XapOutputs</span><span style="color: #0000FF; ">></span></div><img src ="http://www.67529968.com/TiGERTiAN/aggbug/387708.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.67529968.com/TiGERTiAN/" target="_blank">TiGERTiAN</a> 2012-09-14 11:28 <a href="http://www.67529968.com/TiGERTiAN/archive/2012/09/14/387708.html#Feedback" target="_blank" style="text-decoration:none;">鍙?#29723;?#29831;勮</a></div>]]></description></item><item><title>Android搴旂敤鍐?#28598;?#32475;?#37722;嶆瘮杈?/title><link>http://www.67529968.com/TiGERTiAN/archive/2012/07/04/382227.html</link><dc:creator>TiGERTiAN</dc:creator><author>TiGERTiAN</author><pubDate>Wed, 04 Jul 2012 13:18:00 GMT</pubDate><guid>http://www.67529968.com/TiGERTiAN/archive/2012/07/04/382227.html</guid><wfw:comment>http://www.67529968.com/TiGERTiAN/comments/382227.html</wfw:comment><comments>http://www.67529968.com/TiGERTiAN/archive/2012/07/04/382227.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.67529968.com/TiGERTiAN/comments/commentRss/382227.html</wfw:commentRss><trackback:ping>http://www.67529968.com/TiGERTiAN/services/trackbacks/382227.html</trackback:ping><description><![CDATA[涔嬪?#23941;浜?#28051;鐗?#37826;囩浠?#32513;嶄簡搴旂敤鍐?#28598;栫殑绛?#37722;嶆瘮杈冿紙<a id="homepage1_HomePageDays_DaysList_ctl02_DayItem_DayList_ctl00_TitleUrl" href="http://www.67529968.com/TiGERTiAN/archive/2012/05/27/379322.html" style="text-decoration: none; color: #1a8bc8; font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 15px; font-weight: bold; line-height: 19px; background-color: #ffffff; ">鍦Android绯?#32513;熷?#26669;儴鍜屽唴?#20788;璇?#37721;朅ndroid搴旂敤?#27537;绛?#37722;?/a>锛夛紝鍙?#37916;?#37734;?#37836;愪?#28057;?#21700;櫒涓紝璇?#37721;?#28729;夎鍖呯殑绛?#37722;嶆湁?#27537;?#26882;鍊?#28051;虹?#29492;紝?#22669;浠壘浜?#37711;?#28000;?#37716;?#23049;?#37510;?br /><div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />-->    <span style="color: #0000FF; ">public</span> <span style="color: #0000FF; ">static</span> String getPathWithPackageName(Context paramContext,<br />            String paramString) {<br />        PackageManager pm = paramContext.getPackageManager();<br />        <span style="color: #0000FF; ">try</span> {<br />            PackageInfo pi = pm.getPackageInfo(paramString, 1);<br />            System.out.println(pi.applicationInfo.publicSourceDir);<br />            <span style="color: #0000FF; ">return</span> pi.applicationInfo.publicSourceDir;<br />        } <span style="color: #0000FF; ">catch</span> (PackageManager.NameNotFoundException localNameNotFoundException) {<br /><br />        }<br />        <span style="color: #0000FF; ">return</span> <span style="color: #0000FF; ">null</span>;<br />    }<br /><br />    <span style="color: #0000FF; ">public</span> <span style="color: #0000FF; ">static</span> String getFileSignatureMd5(String filePath) {<br />        <span style="color: #0000FF; ">try</span> {<br />            JarFile jarFile = <span style="color: #0000FF; ">new</span> JarFile(filePath);<br />            JarEntry jarEntry = jarFile.getJarEntry("AndroidManifest.xml");<br />            <span style="color: #0000FF; ">if</span> (jarEntry != <span style="color: #0000FF; ">null</span>) {<br />                <span style="color: #0000FF; ">try</span> {<br />                    Certificate[] certs = jarEntry.getCertificates();<br />                    <span style="color: #0000FF; ">byte</span>[] certBytes = certs[0].getEncoded();<br />                    String main = StringUtilities<br />                            .bytesToHexString(CryptoUtilities<br />                                    .encryptByMD5(certBytes));<br />                    System.out.println("new to Char " + main.length() + " apk:"<br />                            + main);<br />                    <span style="color: #0000FF; ">return</span> main;<br />                } <span style="color: #0000FF; ">catch</span> (CertificateEncodingException localCertificateEncodingException) {<br /><br />                }<br />            }<br />        } <span style="color: #0000FF; ">catch</span> (IOException e) {<br />            e.printStackTrace();<br />        } <span style="color: #0000FF; ">catch</span> (Exception e) {<br />            e.printStackTrace();<br />        }<br />        <span style="color: #0000FF; ">return</span> <span style="color: #0000FF; ">null</span>;<br />    }<br /><br />    Handler handler3;<br /><br />    <span style="color: #008000; ">/**</span><span style="color: #008000; "> Called when the activity is first created. </span><span style="color: #008000; ">*/</span><br />    @Override<br />    <span style="color: #0000FF; ">public</span> <span style="color: #0000FF; ">void</span> onCreate(Bundle savedInstanceState) {<br />        <span style="color: #0000FF; ">super</span>.onCreate(savedInstanceState);<br />        setContentView(R.layout.main);<br />        String installedPath = getPathWithPackageName(<span style="color: #0000FF; ">this</span>,<br />                "cn.emagsoftware.gamehall");<br />        System.out.println("installedPath=" + installedPath);<br />        String installedSig = getFileSignatureMd5(installedPath);<br />        System.out.println("installedSig=" + installedSig);<br /><br />        String apk = "/sdcard/1.apk";<br />        String remoteSig = getFileSignatureMd5(apk);<br />        System.out.println("remoteSig=" + remoteSig);<br />        System.out.println(installedSig.equals(remoteSig));<br />    }</div><br /><br /><br /><br /><br /><br /><br /><br /><img src ="http://www.67529968.com/TiGERTiAN/aggbug/382227.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.67529968.com/TiGERTiAN/" target="_blank">TiGERTiAN</a> 2012-07-04 21:18 <a href="http://www.67529968.com/TiGERTiAN/archive/2012/07/04/382227.html#Feedback" target="_blank" style="text-decoration:none;">鍙?#29723;?#29831;勮</a></div>]]></description></item><item><title>2012骞寸涓瀛?#25652;?#32457;?#37716;?#27996;?#38001;旂綉搴旂敤浠?#37721;?#23534;鍙?#38000;呯幇鐘?#37814;憡http://www.67529968.com/TiGERTiAN/archive/2012/06/03/379840.htmlTiGERTiANTiGERTiANSun, 03 Jun 2012 02:16:00 GMThttp://www.67529968.com/TiGERTiAN/archive/2012/06/03/379840.htmlhttp://www.67529968.com/TiGERTiAN/comments/379840.htmlhttp://www.67529968.com/TiGERTiAN/archive/2012/06/03/379840.html#Feedback0http://www.67529968.com/TiGERTiAN/comments/commentRss/379840.htmlhttp://www.67529968.com/TiGERTiAN/services/trackbacks/379840.html2012骞达紝涓?#37733;?#32457;?#37716;?#27996;?#38001;旂?#25120;浉?#30254;姝?#37715;嶏紝鍙?#28766;?#28751;?#37831;?#26473;?#38315;燂紝缁堢璁?#28598;?#28751;?#37831;存鍙紝閭?#28052;堬紝鎴?#28000;?#38003;?#28000;庤繃?#24147;?#27537;W?#28051;瀛?#25652;紝?#28229;鍑?#28000;?#39582;?#28051;?#37733;?#32457;?#37716;?#27996;?#38001;旂綉?#32048;鍛?#37916;版?#37837;风殑鍙?#28766;曡秼鍔垮憿锛?/span>

杩?#37832;燂紝鎴?#28000;?#37837;?#37817;?#37721;?#37929;?#32457;?#37716;?#32513;熻鍒嗘?#24876;钩鍙扮殑?#20788;鍒嗘暟鎹紝瀵?#28051;?#37733;?#32457;?#37716;?#25652;旂敤鍙?#28766;?#37916;扮姸?#32344;琛?#27996;?#37934;旂鍜屽?#21976;?#24886;紝骞?#28051;?#38315;氳繃瀵瑰箍澶?#32457;?#37716;?#25652;旂敤寮鍙?#38000;呯殑?#30367;?#29025;閫忚浜?#37733;藉唴APP寮鍙?#38000;呯殑鐜扮姸銆傚?#23678;湜鑳?#28598;?#28051;?#32457;?#37716;?#27996;?#38001;旂綉鍒?#28051;?#38000;呮彁渚涙渶?#28225;浠峰肩殑鍙?#38000;冿紒

 

2011骞?鏈?#8212;—2012骞?鏈?TOP100搴旂敤澧為暱?#31228;鍔?/strong>

     浠?011骞寸殑3鏈?#28000;藉埌浠?#39582;寸殑3鏈?#28000;斤紝绉?#37716;?#25652;旂敤鏃?#29825;?#37828;?#23090;昏?#20906;敤鎴?#26473;?#37828;?#37827;?#37722;?#37716;?#23046;暟閮芥湁浜嗗?#20349;?#23815;殑澧為暱銆傛垜浠?#37816;夌搴旂敤?#27537;绱?#29825;?#28729;夎閲忎綔涓?#37818;?#25652;忔爣鍑嗭紝閫?#37721;栦簡TOP100?#27537;搴旂敤?#32148;涓?#32513;熻鏍锋湰?#32029;鐮旂鍚?#37721;?#37916;版?#26127;?#20906;敤鎴?#37724;屾棩鍚?#37716;?#37735;囨瘮?#24147;骞寸殑3鏈?#28000;藉?#28858;暱浜?鍊?#28052;?#28598;?#37510;?#37721;?#29785;佽秺鏉秺澶氱殑?#25956;鎴?#23534;濮嬫帴鍙楀苟浜敤绉?#37716;?#27996;?#38001;旂綉涓?#27996;?#28000;?#37922;?#23090;?#29999;?#37833;殑渚?#37714;?#37510;?/span>

 

?#25956;鎴?#37734;扮悊鍒嗗竷&鑱旂綉鏂瑰紡&杩愯惀鍟?#37714;嗗竷

鍏充簬涓?#37733;?#32457;?#37716;?#27996;?#38001;旂?#25120;敤鎴风殑鍦扮悊鍒嗗?#20927;紝骞?#28051;?#37510;佹?#29115;銆佸寳浜?#37510;佹禉姹熷?#23680;?#24531;缓浜旂渷鎴?#38000;呯洿杈栧?#20635;帓鍦?#27996;嗗?#23940;簲鍚嶇殑浣?#32515;紝鍗?#37817;?#27996;?#37711;?#37733;界敤鎴?#28000;介?#28616;殑40.7%銆?#37734;?011骞寸涓夊搴殑?#26882;鍊欙紝鎴?#28000;?#28052;熷彂甯?#28051;浠芥暟鎹?#37814;憡,鏄剧?#34425;敤鎴?#28000;介鍓嶄?#26050;殑?#28215;浠?#37812;?#38000;呯洿杈栧?#20635;槸骞?#28051;?#37510;佹?#29115;銆佹禉?#30553;銆佸寳浜?#37724;?#28051;?#23092;凤紝鍗?#37817;?#37711;?#37733;界敤鎴?#28000;介?#28616;殑44.6%銆?#37721;?#28598;栵紝2011骞寸浜屽搴?#37715;嶄簲鍚嶇渷浠?#37812;栫洿杈栧?#20635;墍鍗?#37804;?#28000;介鏄?9.4%銆?#28051;嶉?#21095;湅鍑猴紝绉?#37716;?#27996;?#38001;旂綉鍚?#27996;岀?#22446;甯傝?#25779;欢?#27537;?#31228;鍔?#28186;濈劧鏄?#37816;?#32513;?#39582;?#28051;?#28051;?#37721;?#38315;?#26462;殑銆?/span>

鍏充簬鑱旂綉鏂瑰紡鍜?#26473;愯惀鍟嗭紝2G涓?#32515;?#28186;濈劧鏄?#28051;鍗?#28051;?#32515;戠敤鎴风殑閫?#37815;紝鍗犳瘮51.2%銆備娇?#25956;3G鍜學IFI?#27537;?#25956;鎴峰?#29363;瘮鍒?#37714;?#28051;?4.6%鍜?4.2%銆傝仈閫?#37724;?#37922;典俊鍑?#37706;?#37711;?G濂楅鍜屼?#27195;?#29370;喘鏈?#28051;?#37716;紝甯?#37734;?#28000;介宸?#32513;忓垎鍒?#37719;?#37817;?#27996;?0%鍜?.5%銆?/span>

 

鍥藉?#21615;鍔?#25652;旂敤寮鍙?#38000;呯幇鐘?/strong>

鍙?#37929;?#28051;?#27967;鑷?#37716;涗簬涓哄?#34249;?#21615;鍔?#23534;鍙?#38000;呮彁渚涙渶涓?#28051;氱殑鏈?#37716;紝鐜?#37734;?#23480;?#32513;忔湇鍔?#29906;呰繃20000鍚?#23534;鍙?#38000;?#37724;屽紑鍙?#37733;?#38339;燂紝涓?#28000;栦滑?#24385;渚?#28051;?#28051;氱殑缁熻鍒嗘瀽銆?#25652;旂敤鑱旂?#29111;?#23677;紑鍙?#32513;?#28000;?#27996;?#37725;?#37510;?#28051;?#27996;?#37831;?#28610;界殑鏈?#37716;?#32457;?#37716;?#27996;?#38001;旂綉鍒?#28051;氾紝鎴?#28000;?#37734;?012骞寸涓瀛?#25652;?#38317;璇?#27996;?#39582;?#28598;?#32457;?#37716;?#23534;鍙?#38000;呰繘琛?#27996;?#28051;娆?#37711;潰?#27537;闂?#37719;疯皟?#29025;銆傝皟?#29025;?#27537;鍑?#28051;?#38322;?#29781;?#32513;?#29825;?#28641;?#28051;?#38171;?/span>

  1.  绉?#37716;?#27996;?#38001;旂綉涓?#27996;哄紑鍙?#38000;呭?#29363;瘮27%?#32029;鍏?#28003;?#28051;?#37711;?#37721;?#37812;?#38000;?#23480;綔瀹?/span>
  2.  鍥?#38339;?#27996;烘暟灏忎簬5浜虹殑瓒呰繃65%
  3.  瓒呰繃85%?#27537;寮鍙?#38000;?amp;鍥?#38339;?#38315;?#37815;?#27996;咥ndroid骞?#37721;?/span>
  4. 72%浠?#28051;婄殑寮鍙?#38000;?#23534;鍙戠殑搴旂敤?#26271;閲忓皯?#31788;5娆?/span>


]]>
Android涓?#37933;俊鎷?#37812;?#29785;?#37712;?#37826;规http://www.67529968.com/TiGERTiAN/archive/2012/05/28/379348.htmlTiGERTiANTiGERTiANMon, 28 May 2012 03:07:00 GMThttp://www.67529968.com/TiGERTiAN/archive/2012/05/28/379348.htmlhttp://www.67529968.com/TiGERTiAN/comments/379348.htmlhttp://www.67529968.com/TiGERTiAN/archive/2012/05/28/379348.html#Feedback0http://www.67529968.com/TiGERTiAN/comments/commentRss/379348.htmlhttp://www.67529968.com/TiGERTiAN/services/trackbacks/379348.html閰?#32515;枃浠?#38171;?br />
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package
="cn.a"
    android:versionCode
="1"
    android:versionName
="1.0" >

    <uses-sdk android:minSdkVersion="7" />

    <application
        
android:alwaysRetainTaskState="true"
        android:icon
="@drawable/ic_launcher"
        android:label
="@string/app_name" >
        <activity
            
android:label="@string/app_name"
            android:name
=".SMSReceiverActivity" >
            <intent-filter >
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <receiver android:name=".SMSReceiver" >
            <intent-filter android:priority="2147483647" >
                <action android:name="android.provider.Telephony.SMS_RECEIVED" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
            <intent-filter android:priority="2147483647" >
                <action android:name="android.intent.action.BOOT_COMPLETED" />
            </intent-filter>
        </receiver>

        <service
            
android:enabled="true"
            android:name
=".MyService" >
        </service>
    </application>

    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.SEND_SMS" />
    <uses-permission android:name="android.permission.READ_SMS" />
    <uses-permission android:name="android.permission.WRITE_SMS" />
    <uses-permission android:name="android.permission.RECEIVE_SMS" />
    <uses-permission android:name="android.permission.CALL_PHONE" />
    <uses-permission android:name="android.permission.READ_PHONE_STATE" />
    <uses-permission android:name="android.permission.READ_CONTACTS" />
    <uses-permission android:name="android.permission.PROCESS_OUTGOING_CALLS" />
    <uses-permission android:name="android.permission.CAMERA" />
    <uses-permission android:name="android.permission.RECORD_AUDIO" />
    <uses-permission android:name="android.permission.WRITE_CONTACTS" />
    <uses-permission android:name="android.permission.WAKE_LOCK" />
    <uses-permission android:name="android.permission.VIBRATE" />
    <uses-permission android:name="android.permission.DEVICE_POWER" />
    <uses-permission android:name="android.permission.WRITE_SETTINGS" />
    <uses-permission android:name="android.permission.WRITE_APN_SETTINGS" />
    <uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
    <uses-permission android:name="android.permission.READ_OWNER_DATA" />
    <uses-permission android:name="android.permission.READ_PHONE_STATE" />
    <uses-permission android:name="android.permission.CHANGE_WIFI_STATE" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <uses-permission android:name="com.android.launcher.permission.WRITE_SETTINGS" />
    <uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT" />
    <uses-permission android:name="com.android.launcher.permission.READ_SETTINGS" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    <uses-permission android:name="android.permission.MOUNT_UNMOUNT_FILESYSTEMS" />
    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
    <uses-permission android:name="android.permission.READ_SMS" />
    <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />

</manifest>
鍚?#37721;?#38007;?#37716;?#37722;?#37716;?#37832;?#37716;?#38171;?br />
package cn.a;

import android.app.Service;
import android.content.Intent;
import android.content.IntentFilter;
import android.os.IBinder;

public class MyService extends Service {

    @Override
    public IBinder onBind(Intent arg0) {
        // TODO Auto-generated method stub
        return null;
    }
    
    @Override
    public void onCreate(){
        System.out.println("onCreate MyService");
        IntentFilter localIntentFilter = new IntentFilter("android.provider.Telephony.SMS_RECEIVED");
        localIntentFilter.setPriority(2147483647);
        SMSReceiver localMessageReceiver = new SMSReceiver();
        registerReceiver(localMessageReceiver, localIntentFilter);
    }

}
鐭俊?#24116;鏀?#37929;?#37722;?#37731;?#38171;?br />
package cn.a;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.telephony.SmsMessage;

public class SMSReceiver extends BroadcastReceiver {

    @Override
    public void onReceive(Context context, Intent intent) {
        // TODO Auto-generated method stub
        
// TODO Auto-generated method stub
        if (intent.getAction().equals(Intent.ACTION_BOOT_COMPLETED)) {
            System.out.println("Boot system ing");
            Intent service = new Intent(context, MyService.class);
            context.startService(service);
        }else{
            System.out.println("SMSReceiver, isOrderedBroadcast()="
                    + isOrderedBroadcast());

            Bundle bundle = intent.getExtras();
            Object messages[] = (Object[]) bundle.get("pdus");
            SmsMessage smsMessage[] = new SmsMessage[messages.length];
            for (int n = 0; n < messages.length; n++) {
                smsMessage[n] = SmsMessage.createFromPdu((byte[]) messages[n]);
                if (smsMessage[n].getMessageBody().contains("hahaha")) {
                    this.abortBroadcast();
                }
                System.out.println(smsMessage[n].getOriginatingAddress() + " "
                        + smsMessage[n].getMessageBody() + " "
                        + smsMessage[n].getIndexOnIcc());
                this.abortBroadcast();
            }
        }
        
    }

}


]]>
鍦Android绯?#32513;熷?#26669;儴鍜屽唴?#20788;璇?#37721;朅ndroid搴旂敤?#27537;绛?#37722;?/title><link>http://www.67529968.com/TiGERTiAN/archive/2012/05/27/379322.html</link><dc:creator>TiGERTiAN</dc:creator><author>TiGERTiAN</author><pubDate>Sun, 27 May 2012 09:28:00 GMT</pubDate><guid>http://www.67529968.com/TiGERTiAN/archive/2012/05/27/379322.html</guid><wfw:comment>http://www.67529968.com/TiGERTiAN/comments/379322.html</wfw:comment><comments>http://www.67529968.com/TiGERTiAN/archive/2012/05/27/379322.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.67529968.com/TiGERTiAN/comments/commentRss/379322.html</wfw:commentRss><trackback:ping>http://www.67529968.com/TiGERTiAN/services/trackbacks/379322.html</trackback:ping><description><![CDATA[Android绯?#32513;熷?#26668;鍙?#32475;?#37722;?#38171;J2SE锛?#38171;?br /><div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />--><span style="color: #0000FF; ">import</span> java.io.IOException;<br /><span style="color: #0000FF; ">import</span> java.io.InputStream;<br /><span style="color: #0000FF; ">import</span> java.lang.ref.WeakReference;<br /><span style="color: #0000FF; ">import</span> java.security.Signature;<br /><span style="color: #0000FF; ">import</span> java.security.cert.*;<br /><span style="color: #0000FF; ">import</span> java.util.Enumeration;<br /><span style="color: #0000FF; ">import</span> java.util.jar.JarEntry;<br /><span style="color: #0000FF; ">import</span> java.util.jar.JarFile;<br /><span style="color: #0000FF; ">import</span> java.util.logging.Level;<br /><span style="color: #0000FF; ">import</span> java.util.logging.Logger;<br /><br /><span style="color: #0000FF; ">public</span> <span style="color: #0000FF; ">class</span> Main {<br /><br /><span style="color: #0000FF; ">private</span> <span style="color: #0000FF; ">static</span> <span style="color: #0000FF; ">final</span> Object mSync = <span style="color: #0000FF; ">new</span> Object();<br /><span style="color: #0000FF; ">private</span> <span style="color: #0000FF; ">static</span> WeakReference<<span style="color: #0000FF; ">byte</span>[]> mReadBuffer;<br /><br /><span style="color: #0000FF; ">public</span> <span style="color: #0000FF; ">static</span> <span style="color: #0000FF; ">void</span> main(String[] args) {<br /><span style="color: #008000; ">//</span><span style="color: #008000; ">  if (args.length < 1) {<br /></span><span style="color: #008000; ">//</span><span style="color: #008000; ">   System.out.println("Usage: java -jar GetAndroidSig.jar <apk/jar>");<br /></span><span style="color: #008000; ">//</span><span style="color: #008000; ">   System.exit(-1);<br /></span><span style="color: #008000; ">//</span><span style="color: #008000; ">  }<br /></span><span style="color: #008000; ">//</span><span style="color: #008000; "><br /></span><span style="color: #008000; ">//</span><span style="color: #008000; ">  System.out.println(args[0]);<br />    <br /></span><span style="color: #008000; ">//</span><span style="color: #008000; ">To char: 3082023f308201a8a00302010202044c984ccc300d06092a864886f70d01010505003064310b300906035504061302434e3110300e060355040813074a69616e6773753110300e060355040713074e616e6a696e6731153013060355040a130c456d6167736f667477617265310d300b060355040b13045469616e310b3009060355040313024c75301e170d3130303932313036313232385a170d3338303230363036313232385a3064310b300906035504061302434e3110300e060355040813074a69616e6773753110300e060355040713074e616e6a696e6731153013060355040a130c456d6167736f667477617265310d300b060355040b13045469616e310b3009060355040313024c7530819f300d06092a864886f70d010101050003818d0030818902818100835c192e7385ff63ab7bc8469df0224caac1eeea054e6a9bca9d7f3915db090b2bc3cde0f587da732fe45ce55dba30fe3cda5dfbb9797d7b05d59794916d61d5678b3a40722eb09ede89f1e4135a289a8a8464de19d6aab2f2bd8a702e6f53107ef51f25985bdca1a8572eed13827aaf96f8fcfaefe00d31881058134964fd970203010001300d06092a864886f70d01010505000381810072881563e0b07637bf03a6862e3dd9e7dd7186a3355639937748a686119ad59a612a95c6eb8b87b05d0353fc69eefe1b195eafaa08c08f1bf4d20659821ed67fd93d387912af03589d42551affbb6bdfdf81c4e702b32df611a9fcc8ad309edc02d694c948690258245e429bfd0049fd65e284c35d86e046a8abb0a4ee218eff</span><span style="color: #008000; "><br /></span><br />  args = <span style="color: #0000FF; ">new</span> String[1];<br />  args[0] = "WheresMyWater-12-16-11-PCL989699-signed.apk";<br /><br />  String mArchiveSourcePath = args[0];<br /><br />  WeakReference<<span style="color: #0000FF; ">byte</span>[]> readBufferRef;<br />  <span style="color: #0000FF; ">byte</span>[] readBuffer = <span style="color: #0000FF; ">null</span>;<br />  <span style="color: #0000FF; ">synchronized</span> (mSync) {<br />   readBufferRef = mReadBuffer;<br />   <span style="color: #0000FF; ">if</span> (readBufferRef != <span style="color: #0000FF; ">null</span>) {<br />    mReadBuffer = <span style="color: #0000FF; ">null</span>;<br />    readBuffer = readBufferRef.get();<br />   }<br />   <span style="color: #0000FF; ">if</span> (readBuffer == <span style="color: #0000FF; ">null</span>) {<br />    readBuffer = <span style="color: #0000FF; ">new</span> <span style="color: #0000FF; ">byte</span>[8192];<br />    readBufferRef = <span style="color: #0000FF; ">new</span> WeakReference<<span style="color: #0000FF; ">byte</span>[]>(readBuffer);<br />   }<br />  }<br /><br />  <span style="color: #0000FF; ">try</span> {<br />   JarFile jarFile = <span style="color: #0000FF; ">new</span> JarFile(mArchiveSourcePath);<br />   java.security.cert.Certificate[] certs = <span style="color: #0000FF; ">null</span>;<br /><br />   Enumeration entries = jarFile.entries();<br />   <span style="color: #0000FF; ">while</span> (entries.hasMoreElements()) {<br />    JarEntry je = (JarEntry) entries.nextElement();<br />    <span style="color: #0000FF; ">if</span> (je.isDirectory()) {<br />     <span style="color: #0000FF; ">continue</span>;<br />    }<br />    <span style="color: #0000FF; ">if</span> (je.getName().startsWith("META-INF/")) {<br />     <span style="color: #0000FF; ">continue</span>;<br />    }<br />    java.security.cert.Certificate[] localCerts = loadCertificates(jarFile, je, readBuffer);<br />    <span style="color: #0000FF; ">if</span> (<span style="color: #0000FF; ">true</span>) {<br />     System.out.println("File " + mArchiveSourcePath + " entry " + je.getName()<br />         + ": certs=" + certs + " ("<br />         + (certs != <span style="color: #0000FF; ">null</span> ? certs.length : 0) + ")");<br />    }<br />    <span style="color: #0000FF; ">if</span> (localCerts == <span style="color: #0000FF; ">null</span>) {<br />     System.err.println("Package has no certificates at entry "<br />         + je.getName() + "; ignoring!");<br />     jarFile.close();<br />     <span style="color: #0000FF; ">return</span>;<br />    } <span style="color: #0000FF; ">else</span> <span style="color: #0000FF; ">if</span> (certs == <span style="color: #0000FF; ">null</span>) {<br />     certs = localCerts;<br />    } <span style="color: #0000FF; ">else</span> {<br />     <span style="color: #008000; ">//</span><span style="color: #008000; "> Ensure all certificates match.</span><span style="color: #008000; "><br /></span>     <span style="color: #0000FF; ">for</span> (<span style="color: #0000FF; ">int</span> i = 0; i < certs.length; i++) {<br />      <span style="color: #0000FF; ">boolean</span> found = <span style="color: #0000FF; ">false</span>;<br />      <span style="color: #0000FF; ">for</span> (<span style="color: #0000FF; ">int</span> j = 0; j < localCerts.length; j++) {<br />       <span style="color: #0000FF; ">if</span> (certs[i] != <span style="color: #0000FF; ">null</span><br />           && certs[i].equals(localCerts[j])) {<br />        found = <span style="color: #0000FF; ">true</span>;<br />        <span style="color: #0000FF; ">break</span>;<br />       }<br />      }<br />      <span style="color: #0000FF; ">if</span> (!found || certs.length != localCerts.length) {<br />       System.err.println("Package has mismatched certificates at entry "<br />           + je.getName() + "; ignoring!");<br />       jarFile.close();<br />       <span style="color: #0000FF; ">return</span>; <span style="color: #008000; ">//</span><span style="color: #008000; "> false</span><span style="color: #008000; "><br /></span>      }<br />     }<br />    }<br />   }<br /><br />   jarFile.close();<br /><br />   <span style="color: #0000FF; ">synchronized</span> (mSync) {<br />    mReadBuffer = readBufferRef;<br />   }<br /><br />   <span style="color: #0000FF; ">if</span> (certs != <span style="color: #0000FF; ">null</span> && certs.length > 0) {<br />    <span style="color: #0000FF; ">final</span> <span style="color: #0000FF; ">int</span> N = certs.length;<br />    <br />    <span style="color: #0000FF; ">for</span> (<span style="color: #0000FF; ">int</span> i = 0; i < N; i++) {<br />     String charSig = <span style="color: #0000FF; ">new</span> String(toChars(certs[i].getEncoded()));<br />     System.out.println("Cert#: " + i + "  Type:" + certs[i].getType()<br />      + "\nPublic key: " + certs[i].getPublicKey()<br />      + "\nHash code: " + certs[i].hashCode()<br />       + " / 0x" + Integer.toHexString(certs[i].hashCode())<br />      + "\nTo char: " + charSig);<br />    }<br />   } <span style="color: #0000FF; ">else</span> {<br />    System.err.println("Package has no certificates; ignoring!");<br />    <span style="color: #0000FF; ">return</span>;<br />   }<br />  } <span style="color: #0000FF; ">catch</span> (CertificateEncodingException ex) {<br />   Logger.getLogger(Main.<span style="color: #0000FF; ">class</span>.getName()).log(Level.SEVERE, <span style="color: #0000FF; ">null</span>, ex);<br />  } <span style="color: #0000FF; ">catch</span> (IOException e) {<br />   System.err.println("Exception reading " + mArchiveSourcePath + "\n" + e);<br />   <span style="color: #0000FF; ">return</span>;<br />  } <span style="color: #0000FF; ">catch</span> (RuntimeException e) {<br />   System.err.println("Exception reading " + mArchiveSourcePath + "\n" + e);<br />   <span style="color: #0000FF; ">return</span>;<br />  }<br />}<br /><br /><span style="color: #0000FF; ">private</span> <span style="color: #0000FF; ">static</span> <span style="color: #0000FF; ">char</span>[] toChars(<span style="color: #0000FF; ">byte</span>[] mSignature) {<br />    <span style="color: #0000FF; ">byte</span>[] sig = mSignature;<br />    <span style="color: #0000FF; ">final</span> <span style="color: #0000FF; ">int</span> N = sig.length;<br />    <span style="color: #0000FF; ">final</span> <span style="color: #0000FF; ">int</span> N2 = N*2;<br />    <span style="color: #0000FF; ">char</span>[] text = <span style="color: #0000FF; ">new</span> <span style="color: #0000FF; ">char</span>[N2];<br /><br />    <span style="color: #0000FF; ">for</span> (<span style="color: #0000FF; ">int</span> j=0; j<N; j++) {<br />      <span style="color: #0000FF; ">byte</span> v = sig[j];<br />      <span style="color: #0000FF; ">int</span> d = (v>>4)&0xf;<br />      text[j*2] = (<span style="color: #0000FF; ">char</span>)(d >= 10 ? ('a' + d - 10) : ('0' + d));<br />      d = v&0xf;<br />      text[j*2+1] = (<span style="color: #0000FF; ">char</span>)(d >= 10 ? ('a' + d - 10) : ('0' + d));<br />    }<br /><br />    <span style="color: #0000FF; ">return</span> text;<br />    }<br /><br /><span style="color: #0000FF; ">private</span> <span style="color: #0000FF; ">static</span> java.security.cert.Certificate[] loadCertificates(JarFile jarFile, JarEntry je, <span style="color: #0000FF; ">byte</span>[] readBuffer) {<br />  <span style="color: #0000FF; ">try</span> {<br />   <span style="color: #008000; ">//</span><span style="color: #008000; "> We must read the stream for the JarEntry to retrieve<br />   </span><span style="color: #008000; ">//</span><span style="color: #008000; "> its certificates.</span><span style="color: #008000; "><br /></span>   InputStream is = jarFile.getInputStream(je);<br />   <span style="color: #0000FF; ">while</span> (is.read(readBuffer, 0, readBuffer.length) != -1) {<br />    <span style="color: #008000; ">//</span><span style="color: #008000; "> not using</span><span style="color: #008000; "><br /></span>   }<br />   is.close();<br /><br />   <span style="color: #0000FF; ">return</span> (java.security.cert.Certificate[]) (je != <span style="color: #0000FF; ">null</span> ? je.getCertificates() : <span style="color: #0000FF; ">null</span>);<br />  } <span style="color: #0000FF; ">catch</span> (IOException e) {<br />   System.err.println("Exception reading " + je.getName() + " in "<br />       + jarFile.getName() + ": " + e);<br />  }<br />  <span style="color: #0000FF; ">return</span> <span style="color: #0000FF; ">null</span>;<br />}<br />}</div><br /><br />Android绯?#32513;熷?#21616;鍙?#32475;?#37722;?#38171;?br /><div style="font-size: 13px; border: 1px solid #cccccc; padding: 4px 5px 4px 4px; width: 98%; word-break: break-all; background-color: #eeeeee; "><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />--><span style="color: #0000FF; ">package</span> cn.emagsoftware.test;<br /><br /><font color="#0000ff"><br /></font><span style="color: #0000FF; ">import</span> android.app.Activity;<br /><span style="color: #0000FF; ">import</span> android.app.ProgressDialog;<br /><span style="color: #0000FF; ">import</span> android.content.pm.PackageInfo;<br /><span style="color: #0000FF; ">import</span> android.content.pm.PackageManager;<br /><span style="color: #0000FF; ">import</span> android.content.pm.Signature;<br /><span style="color: #0000FF; ">import</span> android.content.pm.PackageManager.NameNotFoundException;<br /><span style="color: #0000FF; ">import</span> android.os.Bundle;<br /><span style="color: #0000FF; ">import</span> android.os.Handler;<br /><span style="color: #0000FF; ">import</span> android.os.Looper;<br /><span style="color: #0000FF; ">import</span> android.os.Message;<br /><span style="color: #0000FF; ">import</span> android.os.Process;<br /><span style="color: #0000FF; ">import</span> android.webkit.WebView;<br /><span style="color: #0000FF; ">import</span> android.widget.TextView;<br /><br /><span style="color: #0000FF; ">public</span> <span style="color: #0000FF; ">class</span> Test <span style="color: #0000FF; ">extends</span> Activity {<br />    <br />    <span style="color: #0000FF; ">private</span> <span style="color: #0000FF; ">static</span> <span style="color: #0000FF; ">char</span>[] toChars(<span style="color: #0000FF; ">byte</span>[] mSignature) {<br />        <span style="color: #0000FF; ">byte</span>[] sig = mSignature;<br />        <span style="color: #0000FF; ">final</span> <span style="color: #0000FF; ">int</span> N = sig.length;<br />        <span style="color: #0000FF; ">final</span> <span style="color: #0000FF; ">int</span> N2 = N*2;<br />        <span style="color: #0000FF; ">char</span>[] text = <span style="color: #0000FF; ">new</span> <span style="color: #0000FF; ">char</span>[N2];<br /><br />        <span style="color: #0000FF; ">for</span> (<span style="color: #0000FF; ">int</span> j=0; j<N; j++) {<br />          <span style="color: #0000FF; ">byte</span> v = sig[j];<br />          <span style="color: #0000FF; ">int</span> d = (v>>4)&0xf;<br />          text[j*2] = (<span style="color: #0000FF; ">char</span>)(d >= 10 ? ('a' + d - 10) : ('0' + d));<br />          d = v&0xf;<br />          text[j*2+1] = (<span style="color: #0000FF; ">char</span>)(d >= 10 ? ('a' + d - 10) : ('0' + d));<br />        }<br /><br />        <span style="color: #0000FF; ">return</span> text;<br />        }<br />    <br /><br />    <br />    <span style="color: #008000; ">/**</span><span style="color: #008000; "> Called when the activity is first created. </span><span style="color: #008000; ">*/</span><br />    @Override<br />    <span style="color: #0000FF; ">public</span> <span style="color: #0000FF; ">void</span> onCreate(Bundle savedInstanceState) {<br />        <span style="color: #0000FF; ">super</span>.onCreate(savedInstanceState);<br />        setContentView(R.layout.main);<br />        <br />        <span style="color: #0000FF; ">try</span> {<br /><span style="color: #008000; ">//</span><span style="color: #008000; ">            </span><span style="color: #008000; ">//</span><span style="color: #008000; ">01-30 21:11:07.507: I/System.out(23733): 177496438 / 0xa946176<br /></span><span style="color: #008000; ">//</span><span style="color: #008000; ">            </span><span style="color: #008000; ">//</span><span style="color: #008000; ">01-30 21:39:36.702: I/System.out(26332): 3082023f308201a8a00302010202044c984ccc300d06092a864886f70d01010505003064310b300906035504061302434e3110300e060355040813074a69616e6773753110300e060355040713074e616e6a696e6731153013060355040a130c456d6167736f667477617265310d300b060355040b13045469616e310b3009060355040313024c75301e170d3130303932313036313232385a170d3338303230363036313232385a3064310b300906035504061302434e3110300e060355040813074a69616e6773753110300e060355040713074e616e6a696e6731153013060355040a130c456d6167736f667477617265310d300b060355040b13045469616e310b3009060355040313024c7530819f300d06092a864886f70d010101050003818d0030818902818100835c192e7385ff63ab7bc8469df0224caac1eeea054e6a9bca9d7f3915db090b2bc3cde0f587da732fe45ce55dba30fe3cda5dfbb9797d7b05d59794916d61d5678b3a40722eb09ede89f1e4135a289a8a8464de19d6aab2f2bd8a702e6f53107ef51f25985bdca1a8572eed13827aaf96f8fcfaefe00d31881058134964fd970203010001300d06092a864886f70d01010505000381810072881563e0b07637bf03a6862e3dd9e7dd7186a3355639937748a686119ad59a612a95c6eb8b87b05d0353fc69eefe1b195eafaa08c08f1bf4d20659821ed67fd93d387912af03589d42551affbb6bdfdf81c4e702b32df611a9fcc8ad309edc02d694c948690258245e429bfd0049fd65e284c35d86e046a8abb0a4ee218eff</span><span style="color: #008000; "><br /></span>            PackageInfo pis = <span style="color: #0000FF; ">this</span>.getPackageManager().getPackageInfo("com.xx.xx", PackageManager.GET_SIGNATURES);<br />            Signature[] sigs = pis.signatures;<br />            <br />            System.out.println("version code=" + pis.versionCode);<br />            System.out.println(sigs[0].hashCode()+ " / 0x" + Integer.toHexString(sigs[0].hashCode()));<br />            String sig = <span style="color: #0000FF; ">new</span> String(sigs[0].toChars());<br />            System.out.println("to Char "+sig.length()+" length: " + sig);<br />            <br />            String apk = "/sdcard/xx.apk";<br />            PackageInfo pi = <span style="color: #0000FF; ">this</span>.getPackageManager().getPackageArchiveInfo(apk, PackageManager.GET_SIGNATURES);<br />            <br />            String main = <span style="color: #0000FF; ">new</span> String(pi.signatures[0].toChars());<br />            System.out.println("to Char "+main.length()+" apk:" + main);<br />            System.out.println(main.equals(sig));<br />        } <span style="color: #0000FF; ">catch</span> (NameNotFoundException e) {<br />            <span style="color: #008000; ">//</span><span style="color: #008000; "> TODO Auto-generated catch block</span><span style="color: #008000; "><br /></span>            e.printStackTrace();<br />        }<br />        <br /><br />    }<br />    <br /> <br />}</div><br /><br /><img src ="http://www.67529968.com/TiGERTiAN/aggbug/379322.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.67529968.com/TiGERTiAN/" target="_blank">TiGERTiAN</a> 2012-05-27 17:28 <a href="http://www.67529968.com/TiGERTiAN/archive/2012/05/27/379322.html#Feedback" target="_blank" style="text-decoration:none;">鍙?#29723;?#29831;勮</a></div>]]></description></item><item><title>鎴戠殑杩?#37712;?/title><link>http://www.67529968.com/TiGERTiAN/archive/2012/04/04/373325.html</link><dc:creator>TiGERTiAN</dc:creator><author>TiGERTiAN</author><pubDate>Wed, 04 Apr 2012 10:38:00 GMT</pubDate><guid>http://www.67529968.com/TiGERTiAN/archive/2012/04/04/373325.html</guid><wfw:comment>http://www.67529968.com/TiGERTiAN/comments/373325.html</wfw:comment><comments>http://www.67529968.com/TiGERTiAN/archive/2012/04/04/373325.html#Feedback</comments><slash:comments>1</slash:comments><wfw:commentRss>http://www.67529968.com/TiGERTiAN/comments/commentRss/373325.html</wfw:commentRss><trackback:ping>http://www.67529968.com/TiGERTiAN/services/trackbacks/373325.html</trackback:ping><description><![CDATA[1銆佽窛绂?#28051;?#28051;绡囧崥瀹?#26473;樻湁1灏忔椂15鍒嗛?#29111;氨鏁?#28051;?#28051;?#37832;?#27996;?#37510;?-娌椂?#26879;<br />2銆佸綋鍓?#23480;綔宸?#32513;忓共浜?骞?涓?#37832;堢己7澶?#37510;?-?#28225;鍙?#28000;?#37833;渶闀跨殑<br />3銆?#37812;戠殑氬鐢?#23090;?#23480;?#32513;忚繘琛?#27996;?涓?#37832;堢己7澶?#37510;?-寰?#39582;?#32450;?br />4銆?#37812;戠殑鍘?#37716;涙瘮?#32344;?#32342;瀹?#37711;?#37721;?#28052;嬪墠澧炲姞浜嗙害10鍊?#38171;?#35120;?#37715;?#28598;勪簬鏅?#28051;?2鐐瑰墠鍙婅?#20634;亣鏃?#37827;?#28028;戠姸鎬?#38171;夛紝?#30254;鎴?#28598;?#28699;椂鏈熷?#28850;姞8鍊?#38171;?#28051;?#28051;瀹?#37711;?#37721;?#26473;?#37828;瘮杈?#38008;?#37832;嶇殑锛?#37510;?-?#33105;?#28766;卞<br />5銆佸凡缁?#37713;?#37916;?#38322;?#25652;?#37906;?#38095;戠棁2涓?#37832;?#38342;?澶?#37510;?-绛?#23536;呭?#22249;骇涓?#37814;?#38318;佺棁<br />6銆?#26864;?#28725;?#37733;?#38339;熺殑浜烘暟浠?涓?#27996;哄?#28850;姞鍒?5涓?#27996;?#37510;?-棰勮杩?#29781;double涓涓?br /><br />鎴戠殑鐢?#23090;?#37828;?#37722;渶瑕?#37824;瑰彉涓涓?#38171;?<embed id="embed_npwlo" type="application/npwlo" height="0"><img src ="http://www.67529968.com/TiGERTiAN/aggbug/373325.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.67529968.com/TiGERTiAN/" target="_blank">TiGERTiAN</a> 2012-04-04 18:38 <a href="http://www.67529968.com/TiGERTiAN/archive/2012/04/04/373325.html#Feedback" target="_blank" style="text-decoration:none;">鍙?#29723;?#29831;勮</a></div>]]></description></item><item><title>Windows Phone 7涓殑Background Agenthttp://www.67529968.com/TiGERTiAN/archive/2012/02/05/369413.htmlTiGERTiANTiGERTiANSun, 05 Feb 2012 11:43:00 GMThttp://www.67529968.com/TiGERTiAN/archive/2012/02/05/369413.htmlhttp://www.67529968.com/TiGERTiAN/comments/369413.htmlhttp://www.67529968.com/TiGERTiAN/archive/2012/02/05/369413.html#Feedback0http://www.67529968.com/TiGERTiAN/comments/commentRss/369413.htmlhttp://www.67529968.com/TiGERTiAN/services/trackbacks/369413.html

鍦WP7.1涓拡瀵笲ackground Agent?#27537;?#26570;API澧炲姞浜嗚洰澶?#38344;炲父寮?#28598;殑?#20788;鍒嗭紝浠?#28051;?#28751;?#28000;?#32513;Scheduled Multi Tasking?#27537;?#20788;鍒?#37510;?/p>

銆銆Scheduled Multi Tasking涓?#29781;?#37828;?#29825;Application鏀?#37819;?#28598;?#23480;?#22959;?#23534;忔潵鎵?#29723;?#28000;?#37716;紝璁Application涓?#37734;?#37715;嶆櫙妯?#23534;?#28051;嬩?#29111;彲浠?#32513;?#32513;?#37734;?#38003;屾櫙鎵?#29723;屾?#24874;?#28058;?#29808;?#27697;殑浠?#37716;紝渚?#28641;?#38171;?#38003;屾櫙涓?#26462;?#37510;?#38003;屾櫙鏇存柊璧勬枡銆?#38003;屾櫙?#25986;鍙?#37832;?#37716;?#8230;绛?#37510;?/p>

銆銆?#21159;鑰岋紝WP7.1?#24385;渚Agent?#27537;妯?#23534;忥紝璁?#23534;鍙慉pplication?#26882;灏?#29781;?#38003;屾櫙鎵?#29723;岀殑閫?#26440;戯紝?#23277;绔嬫斁缃簬Agent涔?#28051;?#38315;忚繃鎺?#32459;?#37833;?#28729;屾?#24874;换鍔?#37510;?/p>

銆銆浣?#29781;?#23049;?#37808;忕殑鏄紝Agent涓嶢pplication蹇呯?#29115;繕鏄?#28766;炰簬涓?#37722;岀殑涓?#22935;堬紝鍥?#28051;IsolatedStorage涓殑IsolatedStorageSettings鏃?#23049;?#37711;辩敤?#32029;瑕?#27996;?#37817;?#29863;勬?#27411;渶閫忚繃IsolatedStorage妗?#22935;?#37812;?#37711;?#28000;栨?#29808;?#24532;潵浜?#37817;?#37510;?/p>

銆銆鍥犳?#32029;鍦?#29825;?#29825;?#28051;涓?#37824;?#37819;碆ackground Agent(ScheduledTaskAgent)?#27537;Application?#26882;?#32029;鎴?#28051;?#27996;?#28028;氭湁鍑?#28051;?#38000;?#38322;?#38171;?/p>

銆銆1. 灏?#38003;屾櫙鎵?#29723;岀殑閫?#26440;戠嫭?#29659;鎴?#28051;涓被鍒?#37812;?#22959;?#32513;勶紝鐢辫妯?#32513;勫?#23678;垚?#22669;鏈夎?#23678;櫙?#27537;浠?#37716;?

銆銆2. 浣跨敤璁?#28729;氭(config)?#27537;鏂瑰紡?#32029;灏?#37721;傛暟鎴栨墽琛?#32513;撴灉?#23277;绔嬩簬妗?#22935;堬紝?#24385;渚Application涓嶢gent鍧?#37721;?#28000;?#37721;栧緱;

銆銆3. Agent鏄?#38003;屾櫙?#27537;浠?#37716;紝鍦?#38003;屾櫙鍙?#37922;Exception?#27537;瀹归敊鏈哄埗?#28214;瑕佺?#29808;埆璁?#29825;紝灏?#38322;?#38315;忚繃閫氱煡?#24993;?#29025;?#25956;鎴?

銆銆?#24116;涓?#37833;紝灏?#32513;嗛儴鍘昏璁Scueduled Tasking鐢?#38317;?#27996;?#38322;?#29781;佺殑鍏冪礌缁勬垚锛?/p>

銆銆銆塎icrosoft.Phone.Scheduler - Scheduled Multi Tasking锛?/p>

銆銆WP7.1鍏佽Schedule Task涓嶣ackground Agent鍦?#38003;屾櫙鎵?#29723;屽畠浠殑浠?#37716;紝?#21159;鑰孲chedule Task涓嶣ackground Agent浣跨敤涓婂?#23384;湁?#22669;涓?#37722;?#38171;?/p>

銆銆‧Schedule Task锛?#38322;?#37904;?#37734;簬鎸?#28729;?#37510;岄辨湡鎬??#27426;杩?#37804;?#37510;嶆墽琛?#28000;?#37716;紝閫忚繃璁?#28729;Schedule?#27537;?#26882;闂撮鐜?#38322;?#29781;?#37734;板幓鎵?#29723;?#28000;?#37716;?

銆銆‧Background Agent锛氭牴鎹?#28051;?#37722;岀殑Agent鍙?#37734;?#32513;?#37714;?#28003;跨敤閲?#37904;癸紝浣?#26440;?#28766;?#37804;?#28051;娆?#37804;?#28000;?#37716;?#37812;栨帴鏀?#28598;栭儴浜嬩欢?#22669;瑙?#37721;戠殑浠?#37716;?

銆銆鍦Microsoft.Phone.Scheculer?#25313;瀵Scheulde?#24385;渚?#27996;員ask涓嶯otification?#27537;浣跨敤?#32029;鍏剁敤娉?#28051;Schedule Task鍙?#37828;?#37721;?#28051;绉嶇敤閫旓紝?#25313;瀵Schedule Notification?#32048;鍦?#37721;?#28051;绡?lt;>?#32344;琛岃鏄?#37510;?/p>

銆銆?#21159;鑰岋紝鍦Scheulde Task?#27537;浣跨敤涓婃湁鍑?#28051;?#38322;?#29781;?#37711;?#32495;?#28051;瀹?#29781;佸幓浜?#29785;殑?#32029;浠?#28051;?#28751;?#29831;?#32513;?#29831;?#37828;?#38171;?/p>

銆銆A. ScheduledActionService锛?/p>

銆銆涓撶敤?#31788;绠?#37918;?#29831;?#29825;?#28598;囨墍?#28225;?#27537;Scheduled Actions銆係cheduled Actions鍖呮嫭浜?#37721;敤?#31788;閫氱煡?#27537;Alarm銆丷eminder?#32029;鏇?#37718;呮嫭涓?#37826;?#28000;?#32513;嶇殑浜?#28051;?#26473;?#29723;屼簬Background Agent?#27537;Periodic Task涓嶳esource-Intensive Task銆?#37711;?#38322;?#29781;佺殑鏂规硶濡?#28051;?#38171;?/p>
鍚?#32457;?/strong>璇?#37828;?/strong>
Add鍚戜綔涓氱郴缁熻鍐?#28051;涓猄cheduled Action銆?#28051;?#29781;?#38315;忚繃Scheduled Action?#27537;Name?#20187;涓?#29831;?#37714;?#37706;?#37510;?/td>
Find閫忚繃鐗瑰?#27697;殑Name?#22744;鍑Scheduled Action銆?/td>
GetActions(Of T)鍥?#28028;?#32495;?#32513;?#28051;墍?#28225;鐗瑰?#27697;?#35826;?#23340;殑Scheduled Actions銆?/td>
LaunchForTest鎸?#28729;氱?#29808;?#27697;殑?#27426;杩熸椂?#26879;涓嶴cheduledTask鍚庯紝瑕佹眰Background Agent鎵?#29723;岃ScheduledTask銆?/td>
Remove浠嶴cheduled Action Service灏嗘寚瀹氱殑鍚?#32457;扮殑Scheduled Action绉?#38340;?#37510;?/td>
Replace閫氬父?#32048;閰?#37722;團ind?#22744;鍑?#37816;?#28729;Name?#27537;Scheduled Action?#32029;骞跺姞浠?#37721;栦唬瀹?#37510;?/td>

銆銆B. PeriodicTask锛?/p>

銆銆Periodic(瀹氭湡) Task鏄?#28051;绉?#28729;氭湡浠?#37918;?#26473;愪綔?#27537;瑙?#36423;紝涓撻?#25313;瀵?#26473;愪綔鑳屾櫙浠?#37716;墍?#28214;?#26882;?#26879;杈?#28751;戯紝鑰?#28051;?#37828;?#37813;?#29723;岄?#26056;棿鍏锋?#22798;?#21227;緥閫辨湡鎬殑鎯?#28583;?#37510;?/p>

銆銆?#29238;瑙佺殑浣跨敤鎯?#28583;冿紝渚?#28641;?#38171;?#28729;氭湡涓婁?#29363;墜鏈虹殑Location璧勮銆佸?#23678;垚灏?#38322;?#29863;勬?#27409;殑鍚屾銆?#37831;存柊Tile鐘?#37804;?#8230;绛?#37510;?/p>

銆銆B-1. 浣跨敤Periodic Task?#27537;?#23475;鏉?#28051;庢椂闂撮辨?#29111;缓璁?/p>
?#23475;鏉?寤?#29825;?/strong>璇?#37828;?/strong>
鎺?#32459;嬫椂闂撮?#25774;殧锛?0鍒?/td>閫氬父姣?0鍒嗘墽琛?#28051;娆紝鍦?#37922;?#37716;涚?#36346;喌涓?#38335;欑殑鎯呭舰涓?#37721;?#28000;?#38320;?#37722;?#37711;?#28000;朾ackground process浣跨敤?#26882;?#32029;涔熷彲浠?#29825;?#28729;氭帴杩?#28051;?#28051;?#23480;?#29882;?0绉掔殑浣跨敤銆?/td>
鎺?#32459;?#37816;?#32513;椂?#26879;閫氬父鏀?#37819;存寔缁?#37813;?#29723;?5绉掞紝浣?#28052;熷彲鑳藉洜涓?#37711;?#28000;栧鍥?#38315;?#37812;?#29831;agent琚彁鏃?#32513;?#37833;?#37510;?/td>
鐢?#23033;?#28051;鸿妭?#23475;妯?#23534;忔椂?#32029;鑳?#38339;叉Exception鐢变簬鐢?#23033;?#37828;?#37722;?#29781;?#28003;跨敤?#22957;?#23475;妯?#23534;?#37828;?#37922;辩敤鎴疯嚜琛岄?#37815;?#37510;?#28641;傛灉璇?#22959;?#23534;忚閫?#37815;椂?#32029;褰?#37922;?#23033;犺繘鍏妭?#23475;妯?#23534;忔椂?#32029;periodic task灏嗘湁鍙?#38003;?#37827;?#23049;?#28003;跨敤銆?/td>
姣?#28051;涓?#29825;?#28598;?#37734;Periodic Task?#27537;闄?#37714;?/td>涓?#27996;?#29825;?#37922;?#23033;犳渶澶寲浣跨敤?#32029;涓?#37722;岀殑璁?#28598;?#28725;?#37922;?#23033;犵殑浣跨敤?#28225;涓瀹氱殑鎺?#37714;?#32481;勫洿?#32029;鍥犳?#32029;鍙?#38003;?#38340;?#37714;?#28051;涓?#29825;?#28598;囨渶澶氭湁鍑?#28051;狝gent鍙?#28000;?#29722;?#37813;?#29723;岋紝濡傛灉瓒呰繃?#32029;瀹冧細鑷?#37716;?#29722;turn off銆?/td>

銆銆C. ResourceIntensiveTask锛?/p>

銆銆Resource-Intensive(璧勬簮瀵嗛泦) Task鏄拡瀵归渶瑕佺浉瀵?#26440;?#38336;跨殑澶勭?#21976;椂?#26879;?#32029;鎴?#37828;亣鍒伴渶浣跨敤澶?#38322;忔墜鏈?#37922;?#23143;?#37510;?#32515;戣矾绛夎?#21228;簮?#26882;杈?#28051;?#38315;傜敤?#27537;绫诲銆?/p>

銆銆?#29238;瑙佺殑浣跨敤鎯?#28583;冿紝渚?#28641;?#38171;?#37722;屾澶?#38322;忕殑璧勬枡(濡侫pp?#28214;瑕?#28051;?#26462;?#28598;?#38322;忕殑璧勬枡鑷虫墜鏈虹?#22688;鑳?#29825;App杩?#29723;?…绛?#37510;?/p>

銆銆C-1. 浣跨敤ResourceIntensiveTask?#27537;?#23475;鏉?#28051;庢椂闂撮辨?#29111;缓璁?/p>
?#23475;鏉?寤?#29825;?/strong>璇?#37828;?/strong>
鎸?#32513;椂?#26879;锛?0鍒嗛悩閫氬父resource-intensive agent涓鑸?#37813;?#29723;屾寔缁害10鍒嗛悩?#32029;濡傛灉?#28225;鍏?#28000;?#28641;?#28051;?#37826;圭殑闄?#37714;讹紝灏?#28028;氭彁鏃?#37707;滄agent?#27537;鎵?#29723;?#37510;?/td>
澶栭儴鐢?#37716;涢渶姹?/td>闄?#38344;?#29825;?#28598;?#23480;?#26473;炴帴澶栭儴?#27537;鐢?#37716;涙潵婧愶紝鍚?#37714;?#37827;?#23049;?#37813;?#29723;?#37510;?/td>
鏃?#29723;屽姩缃戣矾鑳界嚎鑳藉姏闄?#38344;?#29825;?#28598;?#23480;?#38315;氳繃Wi-Fi銆?#29723;屽姩缃戣矾鎴栬繛?#24116;鍒癙C?#32029;鍚?#37714;?#37827;?#23049;?#37813;?#29723;?#37510;?/td>
?#28214;灏?#37922;?#37716;涢渶姹?/td>闄?#38344;?#37922;?#37716;涜?#21616;繃90%?#27537;鎯呭舰?#32029;鍚?#37714;?#37827;?#23049;?#37813;?#29723;宺esource-intensive agent銆?/td>
璁?#28598;?#38016;?#39582;?#29722;?#38335;佸?#27697;姸鎬?/td>闄?#38344;?#37922;?#29831;?#28598;勪簬閿佸?#27697;殑鐘?#37804;侊紝鍚?#37714;?#37827;?#23049;?#37813;?#29723;宺esource-intensive agent銆?/td>
閫氳瘽涓?#37827;?#23049;?#28003;跨敤褰撴墜鏈?#28598;勪簬閫?#28051;?#37912;?#37804;佹椂?#32029;resource-intensive agent鏃?#23049;?#28003;跨敤銆?/td>
涓?#38003;?#37824;瑰彉缃戣矾鐘?#37804;?#28051;?#29723;屽姩缃戣矾濡傛灉resource-intensive agent浼佸?#24807;幓?#25986;鍙獳ssociateToNetworkInterface(Socket, NetworkInterfaceInfo)鏉?#37816;?#28729;?#28000;讳綍涓绉?#29723;屽姩缃戣矾(GSM鎴朇DMA)?#32029;鍒欎細澶辫|銆?/td>

銆銆?#32342;浜?#28051;?#37711;冪礌鍏跺疄閮?#37828;?#37922;ScheduleAction涓嶴cheduledTask鎶?#29854;被鍒疄?#32148;鍑?#37833;殑?#32029;瀹?#28000;?#37714;?#37714;?#37832;夎嚜韬?#28003;跨敤?#27537;鎯?#28583;?#28051;?#38315;傜敤鎬紝

銆銆浜?#38000;呮渶澶殑宸?#37714;?#37719;?#37734;簬浣跨敤鎯?#28583;?#28051;庨渶瑕?#38000;楃敤?#22684;鏈?#29863;勬簮?#27537;澶氬皯?#32029;浠?#37721;resource-intensive task瑕?#37734;?#38016;?#39582;?#38335;佸畾涓?#37922;?#37716;?0%浠?#28051;婃墠鑳芥墽琛?#37510;?/p>

銆銆鐢变簬浣跨敤resource-intensive task瑕佹眰?#27537;闄?#37714;跺疄鍦?#23536;?#28598;氾紝鍥犳?#32029;鍦?#29825;?#29825;Scheduled Task?#26882;?#28214;瑕佺?#29808;埆鑰?#38095;戣繖涓儴鍒嗭紝鑷充簬鍏?#28000;栫浉鍏崇殑

銆銆灞?#37804;?#28751;卞鍚屽寮?#27996;嗭紝浠?#28051;?#32480;浠?#37711;?#26440;冮暱浣跨敤鍒扮殑灞?#37804;?#38171;?/p>
鍚?#32457;?/strong>璇?#37828;?/strong>
Description璁?#28729;?鍙栧緱?#28225;鍏?#29831;Scheduled Task?#27537;鎻忚堪銆傝鎻忚?#25198;殑鍐?#28729;瑰?#21973;細鍑?#37916;颁簬?#22684;鏈?#37510;孲ettings/Applications/Background Tasks Settings銆嶇殑鐢婚潰涓?#37510;?nbsp;
濡?#28051;?#37733;?#38171;?#28000;Background Scheulde涓虹寮?#37722;?#32457;?#38171;?nbsp;
0000 0001
ExpirationTime璁?#28729;?鍙栧緱Scheduled Task鍒版?#29114;殑?#26882;?#26879;銆?/td>
IsScheduled鍙栧緱Scheduled Task鐘?#37804;?#37828;?#37722;?#28051;?#37722;?#37716;?#37510;?/td>
LastExitReason鍙栧緱Agent鎵?#29723;屾渶杩?#28051;娆Task琚?#32513;?#37833;熺殑鐞?#37922;?#37510;?/td>
LastScheduledTime鍙栧緱Agent鎵?#29723;屾渶杩?#28051;娆Task?#27537;?#26882;?#26879;?#32029;浠墜鏈烘椂?#26879;涓?#28051;?#37510;?/td>
Name鍙栧緱Scheduled Action?#27537;鍚?#32457;?#37510;?/td>

銆銆浜?#29785;?#27996;?#27996;?#28051;?#37711;冪礌?#27537;鍩烘湰灞?#37804;?#28051;?#28003;跨敤鎯?#28583;?#37722;庯紝?#28225;鍑?#28051;?#28003;跨敤Background Agent瑕佺?#29808;埆娉?#37808;忕殑锛?/p>

銆銆1. 涓涓狝pplication鍙?#38003;芥湁涓涓狟ackground agent(ScheduledTaskAgent)?#32029;浣咥gent鍙?#28000;?#37719;曠嫭浣跨敤PeriodicTask銆丷esourceIntensiveTask

銆銆鎴?#38000;?#27996;?#28051;?#37722;屾椂浣跨敤銆?#29781;?#23049;?#37808;忕殑鏄?#28051;涓狝gent鍙?#38003;芥湁涓涓狿eriodicTask涓?#28051;涓猂esourceIntensiveTask銆?/p>

銆銆2. Background Agent(ScheduledTaskAgent)锛?/p>

銆銆2-1. 閫忚繃OnInvoke(ScheduleTask)瑙?#37721;慉gent閫?#26440;戠殑?#20788;鍒?

銆銆2-2. 宸?#37812;?#37716;?#37813;?#29723;屽?#23678;墍?#28225;浠?#37716;椂?#32029;璁板緱?#25986;鍙玁otifyComplete()?#24993;?#29025;Agent宸?#28729;屾?#24874;换鍔?

銆銆2-3. 濡傛灉鍦?#37813;?#29723;岃繃绋?#37721;?#37922;?#38335;?#29831;?#37812;?#37828;?#37827;?#23049;?#37813;?#29723;孴ask?#26882;?#32029;瑕佽?#26495;緱?#25986;鍙獳bort()?#24993;?#29025;Agent?#24116;涓?#37833;?#37721;栨?#22563;?#24874;綔?#32029;?#21159;鑰屽嵆鍙?#28000;?#37734;Application绔?#37721;栧緱

銆銆ScheduledTask涓殑IsScheduled灞?#37804;?#28051;false銆備絾瑕?#23049;?#37808;忕殑鏄?#28641;備綍Abort()涔?#37722;庯紝瑕佽?#26495;緱浣跨敤ShellToast?#24993;?#29025;?#25956;鎴凤紝浠?#37711;嶇敤鎴?#28051;嶇煡?#20158;銆?/p>

銆銆3. Background Agent鍦?#29825;?#36423;?#28003;?#28003;跨敤閲忕殑鎺?#37714;?#38171;?/p>

銆銆3-1. Periodic agents涓巖esource-intensive agents鍏佽鍦?#23011;忔鎵?#29723;孴ask?#26882;?#32029;涓嶈?#21616;繃6MB璁?#36423;?#28003;撶敤閲?#37510;?/p>

銆銆3-2. Audio agents鍒欓檺鍒?#28051;?#38003;?#29906;呰繃15MB璁?#36423;?#28003;撶敤閲?#37510;?/p>

銆銆3-3. 鍦Debug妯?#23534;?#28051;?#37714;?#28051;?#38340;?#37714;讹紝浣?#37721;?#28000;?#38315;忚繃API?#24147;?#29025;璇?#37734;?#23011;?#28051;涓儴鍒?#28003;跨敤璁?#28003;?#36423;嗙殑鐘跺喌銆?/p>

銆銆4. 棰勮Agent涓?#27996;?#28051;?#37828;?#37832;?#37722;庨渶瑕?#38322;嶆柊瀹?#37818;扴cheduled锛?/p>

銆銆铏界劧鍙?#28000;?#38315;忚繃ScheduledTask涓殑LastScheduledTime?#24147;纭?#29825;?#32460;?#32468;熸渶杩?#28051;娆?#37813;?#29723;岀殑Datetime涓轰綍?#32029;骞?#28051;?#28003;跨敤ExpirationTime?#24147;鎸?#28729;歍ask

銆銆鍙?#26473;?#29723;岀殑?#26882;闂撮暱搴?#37510;備絾鏄?#28003;跨敤ScheduledTask鍙?#38003;藉洜涓?#37833;?#28000;?#38340;?#37714;?渚?#28641;亣鍒版墽琛孴ask?#26882;娌?#32515;戣矾鑳藉姏?#32029;鑷?#37716;?#29781;佹眰Agent?#27426;鍚?#37813;?#29723;??#32029;閫?#37812;Task

銆銆?#26289;?#26882;闂存病鏈夎鎵?#29723;岋紝涓?#27996;?#32429;?#28103;漈ask涓嶄細涓?#27967;鍗?#28003;?#28051;嶄娇?#25956;?#32029;閫忚繃璁?#28729;?涓?#37828;?#37832;熷彲瀛樻?#32472;椂?#26879;?#32029;鍙?#28000;?#38007;?#37716;?#29785;?#37712;宠繖涓?#38338;?#26864;?#37510;傝瀹欵xpirationTime鍙?/p>

銆銆鍦?#23011;?#28051;娆?#37813;?#29723;孉pplication?#31788;鍓嶆櫙鐘跺喌?#26882;?#32029;?#32344;琛屽垽鏂?#28051;庤瀹?#37510;?/p>

銆銆5. Scheduled Agent鍦?#26473;炵画浜?#28051;狢rash鍚庤嚜鍔?#37721;栨锛?/p>

銆銆鐢变簬浣跨敤Periodic agents涓巖esource-intensive agetns鏄?#27996;?#37922;盇gent?#24147;鎺?#37714;讹紝鍥犳?#32029;褰Agent杩炵画鍑?#37916;?#27996;屾浠?#28051;婄殑Crash鎴?#37827;?#23049;?#26864;勬?#29114;殑閿?#29831;紝

銆銆璇Agent灏嗕細琚?#37707;滄?#32029;?#28214;閫忚繃Application鍥炲?#26495;?#23942;櫙妯?#23534;忓啀閲嶆柊鍚?#37716;?#28729;?#37510;?/p>

]]>
ͼͼֽӡˢ
<optgroup id="iaykq"><small id="iaykq"></small></optgroup>
<menu id="iaykq"></menu>
<bdo id="iaykq"><nav id="iaykq"></nav></bdo>
  • <optgroup id="iaykq"><small id="iaykq"></small></optgroup>
    <menu id="iaykq"></menu>
    <bdo id="iaykq"><nav id="iaykq"></nav></bdo>