原创 How to Get CPU Information on Android Android上獲取cpu信息

    Unlike iPhone, Android devices come with different hardware from different manufacturers. One important difference

原创 android kill process 殺死進程的方法

1: 殺死自己進程的方法 android.os.Process.killProcess(android.os.Process.myPid()); 2: 殺死自己進程的方法 java.lang.System.exit(int statu

原创 設計模式之代理模式 proxy

代碼下載:http://download.csdn.net/detail/jzp12/43710441)基本概念: 在 Gof 的書中對Proxy模

原创 Difference Between String , StringBuilder And StringBuffer Classes With Example : Java

Today we are going to understand the difference between String , StringBuilder and StringBuffer . As you will find tha

原创 [android]am start []...

其中 INTENT 的表示法,可以對照 android.content.Intent 的說明: [-a <ACTION>] [-c <CATEGORY>]... [-n <COMPONENT>] [-d <

原创 [android studio]java.lang.IllegalStateException: ScrollView can host only one direct child

error stack:E/AndroidRuntime(21460): FATAL EXCEPTION: main E/AndroidRuntime(21460): java.lang.IllegalStateException: Sc

原创 How to catch java.lang.NoClassDefFoundError?

NoClassDefFoundError is a subclass of Error and not an Exception. Hence you need to use: try { new org.eclipse.cd

原创 刪除ROM中內置的應用

手機rom中有一個運營商或者第三方rom方製作方內置的應用,即使root了,還是無法通過豌豆莢或其它工具卸載,沒有辦法,只能通過手動來刪除了,先運行該應用,然後通過dumpsys activity查看最top的activity<span

原创 設計模式之外觀模式 facade

代碼下載:http://download.csdn.net/detail/jzp12/4371049 我將通過對外觀模式 (Facade Pattern) 的講解來開始我們對設計模式的學習。也許在過去你就已經使用到了外觀設計模式只是你並

原创 android linux c/c++內存泄露

1)android資源泄露檢測? 2)android linux c/c++內存泄露靜態檢測方法 3)android linux c/c++內存泄露動態檢測方法 在linux 平臺可以用ps命令,來監視內存的使用,比如下面的命令(觀測指定

原创 android之Adapter

圖1 Adapter、數據、UI三者關係 適配器的繼承結構 Android開發——說說Adapter那點事 Android Adapter適配器 android 適配器Adapter的使用總結 android 適配器Adpter的使用

原创 linux開發基礎之 vi gdb調試(一)

1)vi vi工作模式:編輯方式、插入方式和命令方式。當運行vi時,首先進入編輯方式 命令行模式功能鍵: yy    :複製光標所在行到緩衝區 [n]yy :例如,6yy 表示拷貝從光標所在的該行“往下數”6行文字 p     :將緩衝區

原创 linux socket開發參考文章

1) 示例代碼有明顯錯誤,但不失爲好的參考文件Linux下Socket編程 IBM文檔庫: Linux socket 編程,第一部分http://w

原创 linux編程錯誤總結

1)error: ‘string’ does not name a type 添加using std::string或者使用using namespace std; 2)c++ compile error: discards quali

原创 C/C++面試題--數組作爲函數參數的幾個問題

void fun(int array[10]) { int *p = &array[-1]; //p = &array[0] - 1; cout<<"function:fun()"<<endl; cout<<"address o