You are here



Blog Terms: 

1 换个思路理解 DID

在软件建构领域,有一个原则叫DID, 通常用来保证资源和时间的最小化。


  • 设计(Design)20倍的容量。
  • 实现(Implement)3倍的容量。
  • 部署(Deploy)1.5倍的容量。


换个思路,在需求开发与系统设计层面出发,也应该遵循这种规律,即在前期设计层面下足功夫,用更周到的设计来实现 方案,以便在部署上线后的改动最小。

但是,往往在实际开发中这个过程都是本末倒置的,从 ‘拍脑袋就做’ 到 ‘开发中发现行不通’ 到 ‘返工’,或者更严重的上线 之后才发现问题,导致更大的返工成本。

2 过度设计


Regular Expression, 3 digi number, only 5 times' numbers are allowed

Blog Terms: 

Number from 0-999, only 5 times' numbers are allowed: 0, 5, 10, 15, 20... 995
The following is the test in javascript:

var reg = new RegExp('^(\\d{0,2}[0,5])$');

How to upload Multiple APK in Android Market

Blog Terms: 

Android Market supports multi APK from July, as Google said, this is good solution help developers manage their products more effectively in Android Market, and help users to avoid compatible problem. I havnt noticed this news until many users complained me that they can not download my app from Google Market, they got "Compatibility Problem", but the app ran well in their devices before July.

Android USB driver for HTC Desire S

Blog Terms: 

In android developing i found Eclipse ADT can not detect my new HTC Desire S, even i have updated the newest USB driver from Google. Someone said it need HTC Sync. But i found it is not necessary, you can find the HTC USB driver here:

HTC Android USB Driver for Microsoft PC

 install and everything works fine!

How to Add Logging to Ant Builds

Blog Terms: 

The Apache Ant build tool is a great aid in automating builds and deployments.
When the build fails, however, diagnosing the problem can be painful -
especially if it only occurs intermittently. Logging details of the Ant
build can therefore be useful.

Test Push service with MDS and BlackBerry Widgets

Blog Terms: 

 You will find the both push demo and the blackberry widgets demo soure here:

I have done everything following the tuturial step by step, but when i tried to send push data using the push demo, i always get the "400 Response error' from local MDS server.
Logs:  400 PushServlet: FAILED -#06 The specified delivery method is not possible

(T)Android - Driving Direction (Route Path)

The DrivingDirection package ( is
removed since Android SDK 1.1. However, in this article, you will leanr
how to adopt driving direction function in
MapView object without the DrivingDirection package.

Read more:


Some Andorid WMS clients

Blog Terms: 

1. gvSIG Mini is a free viewer of many On/Offline Maps:
- OpenStreetMap
- Yahoo
- Microsoft Bing
- Google Maps
- Ordnance Survey (UK)
- Yandex (RU)
- etc

It also has interesting features, such as:
- WMS & WMS-C Client
- Route calculation
- Address/POI search
- Share location (twitter, SMS, e-mail, facebook, ...)
- GPS, cell & WiFi location
- Navigation mode
- Compass support
- Street View integration
- Layer configuration downloader
- QuickZoom: SlideBar or DoubleTap
- Android 2.1 support (now from 1.5 up to 2.1)

Determining whether or not a polygon (2D) has its vertices ordered clockwise or counterclockwise(T)

Blog Terms: 

Org link:


Determining whether or not a polygon (2D) has its
vertices ordered clockwise or counterclockwise
Written by Paul Bourke
March 1998

Subscribe to RSS - Programming