Time of Update: 2015-01-29
標籤:ios objective-c // Car.h// 類的聲明// 類名:Car// 屬性:m_nSpeed// 行為:run#import <Foundation/Foundation.h> // NSObject@interface Car : NSObject{// 屬性:成員變數(可以是基礎類型,枚舉,結構體和類對象指標)@publicint m_nSpeed;// 預設初始化為0}//
Time of Update: 2015-01-28
標籤: phonegap提供的本機資料庫功能不可用,最終請教高手後使用SQLitePlugin外掛程式來實現。網上很多都是介紹IOS外掛程式如何編程,少有介紹如何使用外掛程式:一、外掛程式安裝:1、下載,解壓,複製以下檔案: Cordova-SQLitePlugin-master\src\ios目錄下的SQLitePlugin.h和SQLitePlugin.m,複製到phonggap項目的plugin目錄下。 Cordova-SQLitePlugin-master\www目錄下的SQLit
Time of Update: 2015-01-28
標籤:Xamarin是基於Mono的平台,目前主要有以下產品(更具體請見:http://xamarin.com/products):Xamarin Studio:IDE,是從原來的MonoDevelop改名而來。現在從MonoDevelop官方網站下載的其實也是Xamarin Studio:http://monodevelop.com/。
Time of Update: 2015-01-28
標籤:android開發 最佳化 類 layout
Time of Update: 2015-01-28
標籤: networkComms.net2.3.1開源版本,基於gpl V3協議。因為不能公開3.x版本的源碼,所以基於此版本進行學習。3.X版本進行了諸多改進和Bug修複,使用方法上兩者相差不大。/*請注意使用以下代碼,需遵循GplV3協議*/using System;using System.Collections.Generic;using System.Text;using System.IO;namespace DPSBase{ /// 發送全部或者部分資料流
Time of Update: 2015-01-28
標籤:2015.1.23//迴圈(計算某個數的位元) 輸入一個正整數, 計算這個正整數的位元//int main(int argc, const char * argv[]) {// int n;// int cnt=0;// scanf("%d", &n);// while (n) {// cnt++;//
Time of Update: 2015-01-28
標籤:2015年伊始,Google發布了關於Android效能最佳化典範的專題, 一共16個短視頻,每個3-5分鐘,協助開發人員建立更快更優秀的Android App。課程專題不僅僅介紹了Android系統中有關效能問題的底層工作原理,同時也介紹了如何通過工具來找出效能問題以及提升效能的建議。主要從三個 方面展開,Android的渲染機制,記憶體與GC,電量最佳化。下面是對這些問題和建議的總結梳理。0)Render
Time of Update: 2015-01-28
標籤:2015.1.26//函數:函數又叫方法,實現一定功能,或者代碼複用的代碼體;函數通過函數名進行調用 // *// ***// *****//******* //void print(void)//{// printf(" *\n");// printf(" ***\n");// printf(" *****\n");//
Time of Update: 2015-01-28
標籤:在工程中匯入XMPP第三庫時,出現link錯誤,錯誤如下: Undefined symbols for architecture i386: "_iconv", referenced from: _mem_cd_iconv in libidn.a(striconv.o) _str_cd_iconv in libidn.a(striconv.o)
Time of Update: 2015-01-28
標籤:ios objective-c 一 文法基礎1 關鍵字關鍵字基本上都是以@開頭,常見關鍵字如下:@interface,@implement,@end,@public,@private,@selector,@required,@encode等其他id,self,super等2 字串以@開頭@"Hello world!"3 布爾類型Yes/No4 空類型nil(值為0)5 其他C語言文法二
Time of Update: 2015-01-28
標籤: 當我們需要動態多介面切換的時候,就需要將UI元素和Activity融合成一個模組。在2.3中我們一般通過各種Activity中進行跳轉來實現多介面的跳轉和單個介面動態改變。在4.0或以上系統中就可以使用新的特性來方便的達到這個效果--Fragment類。Fragment類似一個嵌套Activity,可以定義自己的layout和自己的生命週期。
Time of Update: 2015-01-28
標籤:- (void)drawRect:(CGRect)rect { CGContextRef context = UIGraphicsGetCurrentContext(); CGContextClearRect(context, rect); CGContextSetLineWidth(context, _lineWidth); //設定畫筆寬度
Time of Update: 2015-01-28
標籤:acm c++ codeforces dfs 圖論 題目連結:http://codeforces.com/contest/505/problem/D題目大意:在一個圖中,有n個頂點,給出m對數字(u,v)表示頂點u和頂點v必須直接或者間接相連,讓你構造一個這樣的圖,輸出最少需要多少條邊。分析:毫無疑問,n個頂點的話,我們最
Time of Update: 2015-01-28
標籤:1:進入模式 adb shell 2:進入目錄cd dir 3:查看sqlite 資料庫 sqlite>sqlite3 name.db 4:查看該資料庫有那些表,查看錶名sqlite> .tables 4:查看錶結構 sqlite> .schemaCREATE TABLE android_metadata (locale TEXT); CREATE TABLE record(_id integer
Time of Update: 2015-01-28
標籤:Activity間跳轉,在startActivity(intent)後面可以重寫public void overridePendingTransition (R.anim.enterAnim, R.anim.exitAnim);其中enterAnim為進入動畫,exitAnim為出去動畫。在drawable檔案夾中建立enterAnim.xml檔案<?xml version="1.0" encoding="utf-8"?><scale
Time of Update: 2015-01-28
標籤: 方法一,在控制項被初始化的時候設定gridView.setSelector(new ColorDrawable(Color.TRANSPARENT));listView.setSelector(new ColorDrawable(Color.TRANSPARENT));方法二,在布局檔案中設定listSelector屬性<GridView android:listSelector="@android:color/transparent"
Time of Update: 2015-01-28
標籤:本地通知//Android發送多個notification ,<span style="font-size: 11.8181819915771px; font-family: Arial, Helvetica, sans-serif;">PendingIntent的ID很重要。</span>public void addNotification(JSONArray args, CallbackContext callbackContext)
Time of Update: 2015-01-28
標籤:
Time of Update: 2015-01-29
標籤:A.ASI架構中的下載1.實現步驟在實際的開發中如果要使用asi架構來下載伺服器上的檔案,只需要執行下面簡單的幾個步驟即可。(1)建立請求對象;(2)設定下載檔案儲存的路徑;(3)發送下載檔案的網路請求(非同步)。按照上面的幾個步驟執行,程式會自動開啟非同步線程,一點一點的把資料寫入到指定的檔案路徑,而且不論是下載多大的檔案都不會佔用大量的記憶體空間。ASI架構是基於底層的cfnoteworking的,效能很好。當然也可以設定block,或者是監聽下載的進度。 自動會使用&ldq
Time of Update: 2015-01-29
標籤:雖然App Store能夠提醒使用者軟體更新,但很多使用者不會主動去更新一大堆的軟體(我機器上待更新的軟體在100個左右)。如果在軟體開啟時提醒使用者更新 或者