翻蚳è
ã®ãšã³ããªãŒ
éå»2幎éã«ããã£ãŠWindows Mobileãã©ãããã©ãŒã ã®éçºã«æºãã£ãŠããç§ã¯ãApple IPhoneãGoogle AndroidãPalm Preãªã©ã®æ°ãããã©ãããã©ãŒã ã«ã€ããŠè³ãåŸããããåŸãŸããã§ããã ãã°ããåãç§ã¯Windows Mobileéçºè
ã®ããã°ã«åºããããŸããããã®ããã°ã¯ãã30æ¥ã®Windows Mobileãããããã£åããŠããªãratherç¬çãªã¹ã¿ã€ã«ã«ä¿ã¡ããã®ã·ãªãŒãºã®åœŒã®æçš¿ã¯ã30 Days of Bitching about .NET CFã ã.NET CFã®è£ã§30æ¥éã®ãŽã·ããããªã©ã ãããã®æçš¿ã§ã圌ã¯éçºäžã«ééããèœãšãç©Žã«ã€ããŠèª¬æããŸããã
æ°ãæåããã®ããã¬ãŒã¯HTC G1ãè²·åããAndroidéçºã®äžçã«çªå
¥ããŸããã AndroidããŒã±ããã§ããã€ãã®ã¢ããªã±ãŒã·ã§ã³ããªãªãŒã¹ããKushik DuttaïŒããã¯ãŸãã«åœŒã®ååã§ãïŒã¯ãWindows MobileãšAndroidã®éçºäœéšã®æ¯èŒåæãæžãããšã«ããŸããã
ãªãªãžãã«ã¯
ãã¡ãã§ãã ãã®èšäºã¯2008幎11æã«äœæãããŸããããä»æ¥ãäžéšã®æ
å ±ã¯å€å°å€ããªã£ãŠããŸãããããã«ãã£ãŠæªåããããšã¯ãããŸããã§ããã ããã¹ãã«ã¯ããã©ãŒã [X]ã®åç
§ãããã€ããããæåŸã«ãã©ã³ã¹ã¯ãªããããããŸãã
Android vs Windows Mobile
Andriodã®éçºã«ã€ããŠååæ·±ãæãäžãããŸã§ããã®ãããã¯ã«é¢ããããã°ãæ§ããããšæããŸããã ãããŠãç§ã¯Androidãã©ãããã©ãŒã ã®ç¬¬äžäººè
ã§ã¯ãããŸããããç§ã¯å·éã«ããªãäžè¬çãªå£°æãåºãã誰ãã®æ°Žç±ãèžã¿ãç§ã®æèŠãå®ãããšãã§ãããšä¿¡ããŠããŸã[0]
ãã€ãã³ãŒã
Googleã¯ãAndroidã«é¢ããŠèå³æ·±ã建ç¯çããã³æŠç¥çãªæ±ºå®ãäžããŸããã æã泚ç®ãã¹ãã¯ãéçºèšèªãšããŠã®Javaãšä»®æ³ãã·ã³ãšããŠã®
Dalvikã§ãã èŠããã«ãDalvikã¯ãå®è¡æã«Sun JavaãŸãã¯Microsoft Intermediate LanguageïŒILïŒ[1]ã®ãã€ãã³ãŒããšããŠè§£éããããã€ãã³ãŒãã§ãã ãã®
ãã°ãããèšäºãèªããŸã§ãGoogleãJavaçšã«ç¬èªã®ãã€ãã³ãŒãä»æ§ãäœæããããšã«ããçç±ãç解ã§ããŸããã§ããã ããããæçµçã«ã¯ãSunã¯Java MEã®ã©ã€ã»ã³ã¹ã«åé¡ããããã¢ãã€ã«ããã€ã¹ã®ããªãŒãã³ãã¢ã©ã€ã¢ã³ã¹ïŒOpen Handset AllianceïŒã¯ã倧äŒæ¥ã溶æ¥ãè©Šã¿ãªãå¯èœæ§ããªãéãããªãŒãã³ãã©ãããã©ãŒã ãå®éã«æã€ããšã¯ã§ããŸããã¢ã«ãŠã³ã[2]
ããããçåã¯æªè§£æ±ºã®ãŸãŸã§ããILããã®ãããªã©ã€ã»ã³ã¹ã«ãã£ãŠä¿è·ãããŠããªãã®ã«ããªãæ°ãããã€ãã³ãŒããçºæããã®ã§ããïŒ
ECMAãæ¿èªããæšæºã§ããïŒã ããããã°ãŒã°ã«ã¯ãILãã¢ãã€ã«ãã©ãããã©ãŒã ã«é©ããŠããªããããŸãã¯Microsoftãšåããããã§ç ããããªããšèãã決å®ãããããããŸããã åŸè
ãæãå¯èœæ§ãé«ããšæããŸãã
èšèª
äžè¬çã«ãèå°è£ã§çæããããã€ãã³ãŒãã¯ãéŽäžã®è²ãšåããããéèŠã§ãã ç§ã¯å®æçã«ããã«ã€ããŠèããŠããŸããã ããããæ¬åœã«éèŠãªã®ã¯ããªããæžãèšèªã§ãã Googleã¯ãã¿ãŒã²ããéçºè
ãæ°ãããã©ãããã©ãŒã ã«ç§»è¡ããããããããã«Javaãéžæããããšãç解ã§ããŸãããããã§ã...ã¯ããæåŸã«èšããŸãã Javaã¯ãã¡ã
ãªãJavaã¯åžãã®ã§ããïŒ æ°ããŸãããã
- ããã±ãŒãž/ãã¡ã€ã«/ãã£ã¬ã¯ããª/ã¯ã©ã¹åã«é¢ããæãããå¶é
- å¿åã¡ãœããã®æ¬ åŠ
- ééã®æ¬ åŠ
- ã©ã ãåŒã®æ¬ åŠ
- ã€ãã³ã/ããªã²ãŒããªã
- éšåã¯ã©ã¹ã®æ¬ åŠ
- ãªã¹ãã®é¢çœãå®è£
- ãžã§ããªãã¯ã®ã²ã©ãå®è£
- æ§é ã®æ¬ åŠãšãçµæãšããŠãè€åãªããžã§ã¯ããå
šäœãšããŠã¹ã¿ãã¯ã«æ ŒçŽããããšãã§ããŸããã ããã¯ãéèŠãªããã©ãŒãã³ã¹ã«å€§ãã圱é¿ããŸãã
- æååã¯äžå€ã§ãããã€ã³ã¿ãŒã³ãããŸããïŒ ã€ã³ã¿ãŒã³ãåç
§ïŒ
- å®å
šã§ãªãã³ãŒããžã®ã¢ã¯ã»ã¹ãªã
- ããããã£ã®ååŸ/èšå®ã¡ãœããã¯ãããŸãã
- ãªãã¬ãŒã¿ãŒã®éè² è·ãªã
- æ¡åŒµæ¹æ³ã¯ãããŸãã
- æåŸã«æãã§çŽæçã§ã¯ãªããã©ã±ãã
ããã€ã®çç±ããããŸããïŒ 15ïŒ ããã
ç§ã¯é害ãèŠã€ããããšã¯ããŠããŸãã-äžèšã«ãªã¹ããããŠãããã®ã¯ãã¹ãŠãç§ã¯å®æçã«äœ¿çšããŠããŸãã ãã ããå¿åã¯ã©ã¹ã¯ããçšåºŠå¥œãã§ãããã€ãã³ã/ããªã²ãŒãããªããã°ã»ãšãã©åœ¹ã«ç«ããªãããšã«æ³šæããŠãã ããã ç§ããªã¹ãããã®ã¯ãæŠããŠæ§æç³è¡£ã§ãããJavaãCïŒããäºããã匷åã§ã¯ãªãããšãç解ããŠããŸã-äž¡æ¹ã®èšèªã¯ããªããå¿
èŠãšãããã¹ãŠã®èšèªã§ããªããå¿
èŠãšãããã¹ãŠãè¡ãããšãã§ããŸãããªãèªèº«ã«ã CïŒã䜿çšãããšãéçºãããéããããå¹ççã«ããããšã¬ã¬ã³ãã«é²ããããšãã§ããŸã[3]ã
éçºç°å¢
Eclipseã¯å·šå€§ãªéŠãã®ããäœåã§ã...ããã ã¯ããéåžžã«è±å¯ã§æè»æ§ããããŸããããã®ãŽãã®äœ¿ããããã®ãã¹ããå®æœãã人ã¯ãéŠã®åšãã®ããŒãã®å§çž®åŒ·åºŠã®ãã¹ãã«åãçµãå¿
èŠããããŸãã
ç§ã®ãæ°ã«å
¥ãã®çã¿ã¯ãåŒãã¥ãŒãã¯ãªãã¯ããã ãã§äœãç·šéã§ããªãããšã§ãã å¿
ãå³ã¯ãªãã¯ããŠã[è¿œå /ç·šé]ãéžæããŠãã ããã ãã®çµæãIntellisenseã®ãªãããªããã£ãããã¹ããšãã£ã¿ãŒãéããããã§åŒãå°å·ãããšã©ãŒããªãããšãç¥ã£ãŠ[OK]ãã¯ãªãã¯ããŸãã ééã£ãŠããŸã-ããäžåºŠç¹°ãè¿ããŸãã
以åãJavaã®å
éšã¯ã©ã¹ã®æ©èœãè³è³ããŸããã Eclipseãã©ãã»ã©åªããŠããŠããEclipseã¯ãã®å©äŸ¿æ§ãã»ãšãã©ç¡å¹ã«ããŸããå
éšã¯ã©ã¹ã®èŠªã¯ã©ã¹å€æ°ã®å€ãèŠãããšãã§ããŸããïŒ ããã¯ãããã°ãæ¬åœã«èŠçã«ãããŸããäœããããŸããããªãå Žåã芪ã¯ã©ã¹ãããŒã«ã«å€æ°ã«ããŒãããå¿
èŠããããŸãã 確ãã«ããããEclipseãJavaãAndroidã®ãããã®åé¡ãªã®ãããããŸããã
Eclipseã®èªåã¢ããªã³ã¯ããã£ãšããã»ã©éªéã§ãã éçºè
ã®åžæã«é¢ä¿ãªãããã¹ãŠãããã»ã©æ¿ããè£ãããšã¯ã§ããŸããã ãã®çµæã圌ãç§ã«æ¿å
¥ãããã®ã¯ã»ãšãã©åœ¹ã«ç«ããªãã£ãã®ã§ããã¹ãŠãå®å
šã«ãªãã«ããŸããã ãããããªãŒãã³ã³ããªãŒããå®å
šã«ãªãã«ããŠããEclipseã¯åŒãç¶ãæ¬åŒ§ãä»ããŠãããŸã...
SDK
Androidã®éçºã«ã€ããŠå€ãã®èŠæ
ãç³ãç«ãŠãŸããããAndroidèªäœã«ã€ããŠã¯èŠæ
ãç³ãç«ãŠãŠããªãããšã«æ³šæããŠãã ããã å®éãç§ãèããããšãã§ããAPIã¯ãã¹ãŠæšæºåãããŠååšããŠããŸãã
ãã®æå³ã§ã®ç§ã®ãªããã¹ãã¹ãã¯ã
ã¯ã©ã¯ãœã³ãAndroidã«ç§»æ€ããããšã§ããã 2ã€ã®ãã©ãããã©ãŒã ã®å€§ããªéãã匷調ããã®ã«å€§ãã«åœ¹ç«ã¡ãŸããã
ç§å人ã«ãšã£ãŠæãé¡èãªéãã¯ãããŒããŠã§ã¢ã»ã³ãµãŒã«ã¢ã¯ã»ã¹ããããã®APIã§ããã Android SDK 1.0ã¯ç°¡åãªSensorManagerã¯ã©ã¹ãæäŸããŸãããããã¯5åã§ããããŸããã Microsoftã«ã¯ãSensor APIã®ãªãWindows Mobileã®6ã€ã®ããŒãžã§ã³ããããŸããã
第äºã«ãAndroidã§ã®ã¹ã±ãžã¥ãŒã«ãããã¢ããªã±ãŒã·ã§ã³ã®èµ·åã¯ãWindows Mobileãããã¯ããã«ç°¡åã§ãã Windows Mobileã§ããã«å¯ŸåŠããæ¹æ³ãæ¯èŒããŸãã
- ç§ã¯CeRunAppAtTimeããå§ããŸãã ã çŽ æŽãããP / InvokeãæžããŸããã ãã°ããåäœãããã®åŸå®å
šã«åæ¢ããŸãã ä»ã®äººãåãåé¡ãæ±ããŠããŸããã å¥ã®ã¡ã«ããºã ã«åãæ¿ããå¿
èŠããããŸããã
- 次ã«ã CeSetUserNotificationExãè©ŠããŸãã ã å¥ã®å€é¡ã®P / InvokeãäœæããŸããã
- ãããæ©èœããããã«ã¯ã UserNotificationTriggeræ§é äœãé©åã«èšå®ããæ¹æ³ãç解ããå¿
èŠããããŸãã ã
- ãã®åŸãããã€ã¹ãã¹ãªãŒãããŠããå Žåã Klaxonã¯åžžã«æ£ããåäœããªãããšãå€æããŸãã ã
- ããäžåºŠããã¥ã¡ã³ããã·ã£ãã«ãããã®åé¡ã解決ããŸãããããã€ã¹ã«enableã³ãã³ããæ瀺çã«éä¿¡ããå¿
èŠããããŸããããããªããšãåã³ã¹ãªãŒãç¶æ
ã«ãªããŸãã
- Klaxonã¯ãå€æéãžã®åãæ¿ããè¡ããããŸã§ãããå°ãäœæ¥ãç¶ããŸããã äžéšã®é»è©±ã§ã¯ã1æéåŸã«éç¥ãããªã¬ãŒãããŸãã çç±ã¯ããããŸããã ãããããã
次ã«ãAndroidãšæ¯èŒããŸãã
- AlarmManagerãåç
§ããŠãã ãã
- ç¹å®ã®æéã«ã€ãã³ãïŒæå³ïŒã®ããªã¬ãŒãæ§æãã
- ã€ãã³ããåŠçãã
ãã¹ãŠãæ£åžžã«æ©èœããåé¡ãããŸããã ã€ãã³ãã¯äœ¿ãããããé©ãã»ã©æè»ã§åæ§ã«åŒ·åã§ãããšèšããªããã°ãªããŸããã
ãããã£ãŠãAndroidäžã®Windows Mobileã®éçºäžã®2ã€ã®å°é£ãªéšåã®1ã€ã¯ã梚ã®æ®»ãããã®ãšåããããç°¡åã§ããããšãå€æããŸããã æåŸã«-ãŠãŒã¶ãŒã€ã³ã¿ãŒãã§ã€ã¹ã
Windowsãã©ãŒã ãšAndroid XMLã¬ã€ã¢ãŠãã Windows Formsã¯ã絶察寞æ³ãšé
眮ã§åäœããŸãã Androidã¯çžå¯Ÿçãªãµã€ãºãšäœçœ®ã§åäœããŸãã ã¢ãã¡ãŒã·ã§ã³ã³ã³ãããŒã«ã«å¯Ÿãããéçãã³ã³ãããŒã«ã å®éãæ¯èŒãããã®ã¯äœããªãã®ã§ãç§ã¯ããããšã¯ããŸããã
ç°¡åã«èšãã°ãAndroid SDKã¯Windows Mobile SDKã«çŽ°ååãããŸãïŒèšèªãšãã¬ãŒã ã¯ãŒã¯ã®æ©èœã¯èæ
®ãããŸããïŒã
Windows Mobileã«ã¯ã¯ããã«åªããããã¥ã¡ã³ãïŒMSDNïŒããããŸãããããã¯è¥ãSDKã®éåœã§ãã
ãã©ãããã©ãŒã
Androidã¯ã»ãã¥ãªãã£ã®èŠ³ç¹ããéåžžã«å³ããå¶éãããŠããŸãã ã¢ããªã±ãŒã·ã§ã³ã¯å¿
èŠãªæ©èœãç»é²ããå¿
èŠãããããŠãŒã¶ãŒã¯ãããã確èªããå¿
èŠããããŸãã ããããããã¯éåžžã«ååããªããšã§ãããæ¬ ç¹ããããŸãã ããšãã°ãèªå以å€ã®ãã®ã®ã¹ã¯ãªãŒã³ã·ã§ãããæ®ãã¢ããªã±ãŒã·ã§ã³ãæžãããšã¯äžå¯èœã§ãããªããªãã å®å
šã§ãªããšèŠãªããã[4]
ãŸããAndroidã®ããã§ã¯ãããŸããããé»è©±ã¯ããã»ã©ããªãŒãã³ãã§ã¯ãããŸããã 圌ãã¯ããããå©æããŸãã ããšãã°ããŠãŒã¶ãŒã¯
rootã¢ã«ãŠã³ãã«ã¢ã¯ã»ã¹ã§ããŸããã ããã«ãããAndroidã«ã€ã³ã¹ããŒã«ãããŠããæšæºã¢ããªã±ãŒã·ã§ã³ãèšå®/å€æŽããããšã¯ã§ããŸããã ããã§ãã«ãŒãã¢ã¯ã»ã¹ãååŸ
ã§ããå Žå
㯠ãæšæºã¢ããªã±ãŒã·ã§ã³ãå®éã«å€æŽ
ã§ããŸãã ãããã¯ãœãŒã¹ã«ãããŸãã
äžæ¹ãWindows Mobileã¯äœãé ããŸããã éçºè
ã¯ã絶察ã«ãããããã®ã«äœã¬ãã«ã§ã¢ã¯ã»ã¹ã§ããŸãã ããšãã°ãAndroidã«ã»ã³ãµãŒAPIããªãå Žåãéçºè
ã«ã¯ãã£ã³ã¹ããããŸããïŒADBçµç±ã§ãã€ããªãæåã§ã€ã³ã¹ããŒã«ããå Žåãé€ãïŒã å¥ã®äŸïŒAndroidã¯ãŸã Media Playerãä»ããã¹ããªãŒãã³ã°ãããªããµããŒãããŠããŸãããç§ã®ç¥ãéããOTAæŽæ°ãä»ããŠã·ã¹ãã ãã€ããªã«ããããé©çšããªãéããäœãã§ããŸããã
ãããããAndroidããŒã±ããã§ãïŒ ååããäœãèšããªãã®ã§ããã¹ãŠãæ確ã§ãã
泚ïŒã¯ããMarketplaceã¯2009幎ã®ç§ã«ã®ã¿è¡šç€ºãããŸã...ãããã«
æã®4æã«ããªãããã®çŽ æŽãããçµè«ãæžããªãã§ãããã Windows Mobileåãã®éçºãæ¬åœã«å¥œãã ãšããèšããŸããã èšèªãšéçºããŒã«ã¯çŽ æŽãããã§ãã ãã ãããã©ãããã©ãŒã ãšã¢ããªã±ãŒã·ã§ã³ã®äœ¿çšã¯ããŸã䟿å©ã§ã¯ãããŸããã äžæ¹ãAndroidã®éçºã«ã¯ããã»ã©æºè¶³ããŠããŸãããããã©ãããã©ãŒã ãã¢ããªã±ãŒã·ã§ã³ã䜿ããããã¯çŽ æŽãããã§ãïŒ æåŸã«ãæºåž¯é»è©±ãšæŠã£ãŠãªã³ã©ã€ã³ã«ããå¿
èŠã¯ãããŸããã ã ãããã©ã®é»è©±ããã€ãç§ãšäžç·ã«ãããšæããŸãã ãããŠãã©ã®æºåž¯é»è©±ã®éçºã«ãã£ãšèå³ãããããèããŠãã ããã
ãã€ã¯ããœããã
ãŠãŒã¶ãŒãã¬ã³ããªãŒãªãã©ãããã©ãŒã ãäœæããŠãç§ã幞ããªãŠãŒã¶ãŒã§ããéçºè
ã«ããŠãããããšãæ¬åœã«é¡ã£ãŠããŸãã ç§ã¯ãããèšã£ãŠãããšã¯æããŸããããAppleããã¯ããããŒãžãåé€ããå¿
èŠããããšèšããŸãããåŸæ¹äºææ§ãå¿ããæ¢åã®ã¢ããªã±ãŒã·ã§ã³ãå¿ããæ©èœããå®å
šã«æ°ãããã©ãããã©ãŒã ãäœãã ãã§ãã ã ããŸãã«ãé·ãéã圌ãã¯ãåŸæ¹äºææ§ããšãããã³ãã©ã«é Œããããã¯åã«åœŒããå
ã«é²ãã®ã劚ããŠããŸãã ãã®éã圌ãã¯çåžå Žããé ãããã€ã€ããããã®äžéšã¯è² ããæããŠããŸãã
è泚
[0]ç§ã¯AndroidããŒã±ããåãã«TelnetãšKlaxonã®2ã€ã®ã¢ããªã±ãŒã·ã§ã³ãéçºããŸããããã®ãããAndroidãã©ãããã©ãŒã åãã®éçºã«ã€ããŠã¢ã€ãã¢ããããšæããŸãã Klaxonã¯ã2ã€ã®ãã©ãããã©ãŒã ã®å€§ããªéãã匷調ããã®ã«éåžžã«åœ¹ç«ã¡ãŸããã
[1]ã¯ããILã¯Windows Mobileã§ã¯è§£éãããªãããšãç解ããŠããŸãã JITã³ã³ãã€ã«ãééããŸãã
[2]ãã€ã¯ããœããã®ãæªããäœã§ããããã®ç¹èš±ãæè·ããããšããè©Šã¿ã§ã¯ããã¥ãŒã¹ã§ã¯èŠãããŸããã§ããã
倪éœãšã¯ç°ãªã[3] RubyãèŠãã
[4]å°æ¥çã«ã¯Googleãè¡ããããããŸããã