Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

javaÓëC++ÖÐÎÄ×Ö·ûµÄÎÊÌâ

 
ÖÐÎĵıàÂë³£ÓõÄÓÐ3ÖÖ¸ñʽ£º1£©gb2312(¾ÍÊÇasciiÂ뷽ʽ£¬Ò²Ëµansi) 2)unicode 3)utf-8
c++Ò»°ã²ÉÓÃanciiÂ룬¶øjavaÒ»°ã²ÉÓÃunicode£¬¶øSymbianC++£¨ÒÔºó¼ò³Æsymbian£©²ÉÓÃunicode»òutf-8
±ÈÈ纺×Ö“ºÃ”£º unicodeΪ“7D 59”£¬¶øasciiΪ“BA C3”, utf-8±àÂëΪ3¸ö×Ö½Ú¡£
ÖÕ¶ËÄã¿ÉÒÔÑ¡ÔñʹÓÃchar *, unsigned char *, µ«ÊÇÕâ²»ÊÇÍƼöʹÓõģ¬ºÜ¶àʱºò´¦ÀíµÄʱºòÈç½çÃæµÈÐèҪת»¯ÎªÖն˵Ä×Ö·û±àÂë¸ñʽ¡£
ÏÖÔÚ·Ö4²¿·Ö½²½â×Ö·û±àÂëת»¯£¨Àý×Ó¼ÙÉ裬javaºÍsymbian¼ä²ÉÓÃutf-8£¬c++ºÍsymbianÖ®¼ä²ÉÓÃASCIIÂ룩£º
1) Symbian -> Java ·¢Ëͺ¬ÓÐÖÐÎĵÄÏûÏ¢  
   ÎÒÃǼÙÉèÄãµÄSymbianµÄ·¢ËÍÏûÏ¢µÄ½Ó¿Ú²ÉÓõÄÊÇHBufC8 * (utf-8)
   ÄÇôÄãÔÚ·¢ËÍÄãµÄÏûϢ֮ǰ£¬ÐèÒª½«Êý¾Ýת»¯Îªutf-8¸ñʽ£¬
   ÀýÈ磬Äã¿ÉÒÔʹÓÃCnvUtfConverter::ConvertfromUnicodeToUtf8()½«½çÃæµÄTBufת»¯Îª8λµÄutf-8¸ñʽ£¬×ª»¯¹ý³ÌÖÐÄãÒªÓÈÆä×¢Ò⣬ΪHBufC8 * ¿ª±ÙµÄÄÚ´æÓ¦¸ÃÊÇTBuf³¤¶ÈµÄ2±¶!
  
ÖÁÓÚÖÕ¶ËÈçºÎ´¦ÀíJava¶Ë·¢Ë͵ÄÏûÏ¢¾Í²»ÑÔ¶øÓ÷ÁË£¬Javaͨ³£»áÖ»·¢ËÍÒ»¸öString,
Ò²¾ÍÊÇÒ»¸öUnicode×Ö·û´®£¬Õâ¸öʱºòÒ»°ãSymbian»áÒÔTDes8½ÓÊÕ£¬Êµ¼ÊÉϽÓÊÕµÄÊý¾ÝÊÇUnicodeµÄ¶ø²»ÊÇutf-8µÄ£¬µ«ÊÇ
SymbianÖ§³ÖÕâÖÖ¸ñʽ£¬ËùÒÔ¿ÉÒÔÖ±½Ó¾Í°´ÕâÖÖ·½Ê½´¦Àí£¬¶ø²»ÐèҪת»¯¡£µ±È»£¬ÒªÔÚ½çÃæÉÏÏÔʾµÄ»°»¹ÊÇÐèÒªCnvUtfConverter::
ConvertToUnicodefromUtf8())  
2) Java -> Symbian ·¢Ëͺ¬ÓÐÖÐÎĵÄÏûÏ¢
   ·þÎñÆ÷¶Ë
µ±È»Ò²Òª´¦ÀíÖÐÎÄÁË£¬¸Õ²ÅÒѾ­ËµÁË£¬·¢Ë͵ÄʱºòÄã¿ÉÒÔÖ±½Ó·¢ËÍString
(Unicode)£¬ÈÃSymbianÈ¥½âÎö£¬µ«ÊǽÓÊվ͵ÃÊ®·ÖСÐÄ£¡£¡ÖÕ¶ËSymbian¹ýÀ´µÄÊÇHBufC8*
(utf-8)¸ñʽ£¬JavaÇмɲ»ÒªÖ±½ÓÓÃStringÈ¥½ÓÊÕ£¬ÐèÒª°´×Ö½Ú½ÓÊÕ£¬È»ºóÔÙ½«ÕâЩ×Ö½Ú½âÎö³Éutf-8,ÔÙת»¯ÎªString,Óм¸Ìõ¼òµ¥
µÄÓï¾ä¿ÉÒÔÍê³ÉÕâ¸ö²Ù×÷£º
   byte b3[] £½ ...; //À´×ÔSymbianµÄutf-8×Ö½Ú
   DataInputStream dis=new DataInputStream(new ByteArrayInputStream(b3));
   String chinastring = dis.readUTF();
3) Symbian -> C++ ·¢Ëͺ¬ÓÐÖÐÎĵÄÏûÏ¢
   ÏÖÔÚÎÒÃÇÔÙÀ´ÌÖÂÛÏ£¬ÈçºÎ½«SymbianµÄÏûÏ¢·¢Ë͸øC++×ÓϵͳÄØ£¬ ÏÔÈ»£¬C++×ÓϵͳÊÇ°´ÕÕchar */unsigned char *´¦Àí×Ö·û´®µÄ£¬Ò²¾ÍÊÇASCIIÂ뷽ʽ£¨ÖÐÎľÍÊÇÀ©Õ¹µÄANSI¼´GB2312£


Ïà¹ØÎĵµ£º

sql 2005 ´æ´¢¹ý³Ì·ÖÒ³ java ´úÂë

 create PROCEDURE pagelist
@tablename nvarchar(50),
@fieldname nvarchar(50)='*',         
@pagesize int output,--ÿҳÏÔʾ¼Ç¼ÌõÊý
@currentpage int output,--µÚ¼¸Ò³
@orderid nvarchar(50),--Ö÷¼üÅÅÐò
@sort int,--ÅÅÐò·½Ê½£¬1±íʾÉýÐò£¬0±íʾ½µÐòÅÅÁÐ ......

º½¿Õ¹«Ë¾¹ÜÀíϵͳ(VC++ ÓëSQL 2005)

ϵͳ»·¾³£ºWindows 7
Èí¼þ»·¾³£ºVisual C++ 2008 SP1 +SQL Server 2005
±¾´ÎÄ¿µÄ£º±àдһ¸öº½¿Õ¹ÜÀíϵͳ
      ÕâÊÇÊý¾Ý¿â¿Î³ÌÉè¼ÆµÄ³É¹û£¬ËäÈ»³É¼¨²»¼Ñ£¬µ«ÊÇ×÷ΪÎÒÓÃVC++ ÒÔÀ´±àдµÄ×î´ó³ÌÐò»¹ÊÇ´«µ½ÍøÉÏ£¬ÒÔ¹©²Î¿¼¡£ÓÃVC++ ×öÊý¾Ý¿âÉè¼Æ²¢²»ÈÝÒ×£¬µ«Ò²²»ÊDz»¿ÉÄÜ¡£ÒÔÏÂÊÇÎҵijÌÐò½çÃ棬ºóÃæ ......

javaÃæÊÔÌâ1

l    JBS
1.Áоٳö 10¸öJAVAÓïÑÔµÄÓÅÊÆ
a:Ãâ·Ñ£¬¿ªÔ´£¬¿çƽ̨(ƽ̨¶ÀÁ¢ÐÔ)£¬¼òµ¥Ò×Ó㬹¦ÄÜÍêÉÆ£¬ÃæÏò¶ÔÏ󣬽¡×³ÐÔ£¬¶àỊ̈߳¬½á¹¹ÖÐÁ¢£¬ÆóÒµÓ¦ÓõijÉÊìƽ̨, ÎÞÏßÓ¦ÓÃ
2.ÁоٳöJAVAÖÐ10¸öÃæÏò¶ÔÏó±à³ÌµÄÊõÓï
a:°ü£¬À࣬½Ó¿Ú£¬¶ÔÏó£¬ÊôÐÔ£¬·½·¨£¬¹¹ÔìÆ÷£¬¼Ì³Ð£¬·â×°£¬¶à̬£¬³éÏ󣬷¶ÐÍ
3.ÁоٳöJAVAÖÐ6¸ ......

C/C++——С±à̸CÓïÑÔº¯ÊýÄÇЩÊÂ(26)

C³ÌÐòÊÇÓÉÒ»×é»òÊDZäÁ¿»òÊǺ¯ÊýµÄÍⲿ¶ÔÏó×é³ÉµÄ¡£ º¯ÊýÊÇÒ»¸ö×ÔÎÒ°üº¬µÄÍê³ÉÒ»¶¨Ïà¹Ø¹¦ÄܵÄÖ´ÐдúÂë¶Î¡£ÏÂÃæС±àºÍ´ó¼Ò·ÖÏíÏÂCÓïÑÔÖеĺ¯Êý¡£
 
1.   sopenº¯Êý
sopenº¯ÊýµÄ¹¦ÄÜÊÇ´ò¿ªÒ»¹²ÏíÎļþ£¬ÆäÓ÷¨Îª£ºint sopen(char *pathname, int access, int shflag, int permiss);³ÌÐòʵÀýÈçÏ£º
#include ......

javaÓësql server 2005µÄÏà¹Ø²Ù×÷

//±¾³ÌÐòÁ¬½ÓµÄÊÇsql server 2005£¬ÓëÁ¬½Ósql server 2000Óе㲻ͬ£ºdriverNameºÍURL¶¼²»Í¬
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
public class create{
   public void getConnection() th ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ