<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    潛魚在淵

    Concentrating on Architectures.

    posts - 77, comments - 309, trackbacks - 0, articles - 0
      BlogJava :: 首頁 :: 新隨筆 :: 聯(lián)系 :: 聚合  :: 管理

    2006年6月28日
















    posted @ 2008-12-08 23:21 非魚 閱讀(1337) | 評論 (0)編輯 收藏

    I dont know what goes wrong here. Java 6 desktop applications could not use SCIM in ubuntu with LANG=zh_CN.GB18030. When I input a chinese character, it becomes to 2 english letters instead. I guess it's ubuntu's problem because SCIM works under Red Hat with same locale setting and java version.

    So I changed locale to zh_CN.GBK and the problem was solved.

    Another problem is that Java 6 applications conflict with eva. every time a message window pops up, the keyboard freezed in java (heavyweight?) window. I can only click on another (heavyweight) widget and navigate back to reactivate the keyboard.

    , , , ,

    posted @ 2008-11-19 00:08 非魚 閱讀(1383) | 評論 (0)編輯 收藏

         摘要: 使用具體的類定義變量  閱讀全文

    posted @ 2008-10-29 22:20 非魚 閱讀(3057) | 評論 (0)編輯 收藏

         摘要: Feature Envy  閱讀全文

    posted @ 2008-10-28 00:43 非魚 閱讀(2610) | 評論 (1)編輯 收藏

         摘要: 使用集合(Collection)“類”而不是接口來定義變量  閱讀全文

    posted @ 2008-10-27 20:25 非魚 閱讀(2543) | 評論 (0)編輯 收藏

         摘要: 父類引用子類  閱讀全文

    posted @ 2008-10-26 01:42 非魚 閱讀(2562) | 評論 (1)編輯 收藏

         摘要: instanceof檢查鏈  閱讀全文

    posted @ 2008-10-25 13:55 非魚 閱讀(2386) | 評論 (6)編輯 收藏

         摘要: 把實(shí)例造型(cast)成具體的類型  閱讀全文

    posted @ 2008-10-25 00:32 非魚 閱讀(2287) | 評論 (2)編輯 收藏

    In this MV, Yulia Savicheva looks like an angel. Browny long hair with tender eyes make her like a neighbor girl. Her lips' so sexy (I have no better word to state that, oh I'm so evil...)



    Юлия Савичева - Прости за любовь
     
    Прости за любовь

    原諒愛吧

    Послушай, ты был прав,

    聽,你是對的

    Послушай, мне не больно.

    聽,我不覺得疼

    И сердце без тебя

    沒有你的心

    Стучит спокойно.

    跳動的如此安靜

    Послушай, я ушла,

    聽,我走了

    Послушай, то что было.

    聽,曾經(jīng)的過往

    И скажет тишина,

    這沉默將說出

    Что я любила.

    我曾經(jīng)愛過

    Ты сердце моё

    你,我的心

    Прости за любовь,

    原諒愛吧

    Остыла.

    讓它變冷

    Послушай меня,

    聽我說

    Я просто любила.

    我僅僅是愛過了

    Ты сердце моё

    你,我的心

    Прости за любовь,

    原諒愛吧

    Остыла.

    讓它變冷

    Послушай меня,

    聽我說

    Я просто любила.

    我僅僅是愛過了


    Всё время без меня,

    所有沒有我的時間

    Всё время, то что лечит.

    所以用來療傷的時間

    И на прощанье взгляд тебе на плечи.

    當(dāng)我們分開的時候我看到了你的背影

    Оставлю для тепла,

    我在你那里留下一絲溫暖

    Оставлю след над крышей.

    我在你那里留下一絲記憶

    Сегодня я ушла,

    今天我離開了

    А ты не слышал.

    而你卻不知道

    Ты сердце моё

    你,我的心


    Прости за любовь,

    原諒愛吧

    Остыла.

    讓它變冷

    Послушай меня,

    聽我說

    Я просто любила.

    我僅僅是愛過了

    Ты сердце моё

    你,我的心

    Прости за любовь,

    原諒愛吧

    Остыла.

    讓愛變冷

    Послушай меня,

    聽我說

    Я просто любила.

    我僅僅是愛過了

    Many thanks to 桃溪兒 (北京), although you don't know that I googled the translation from you.


    ,

    posted @ 2008-10-23 19:59 非魚 閱讀(1314) | 評論 (0)編輯 收藏



    Юлия Савичева-Если в сердце живет любовь

    尤利婭 薩維切娃:如果心里還有愛

    Click here to download the mp3.

    , , ,

    posted @ 2008-10-23 00:05 非魚 閱讀(1496) | 評論 (0)編輯 收藏

    It's nearly about twenty years.

    Does anyone still remember that.

    Bleeding days gone with the wind.

    Someone's still alive.

    And trying to recall.

    He said:

    Twenty years, twenty yuan.

    If you want a t-shirt,

    Just try to google "20年20元".

    I was too young to understand.

    At that time.

    Now I know they were forerunners.

    I'm not looking forward to fucking things up.

    But when I turned around.

    I saw children's body.

    And disease.

    Murderers' coming up.

    “For whom the bells tolls?”

    For

    You and Me




    By Feelyou.

    , ,

    posted @ 2008-10-15 01:11 非魚 閱讀(284) | 評論 (1)編輯 收藏

         摘要: 討論UUID的定義、分類、應(yīng)用及生成工具。  閱讀全文

    posted @ 2008-10-14 22:52 非魚 閱讀(20528) | 評論 (3)編輯 收藏

         摘要: 在漫長的生命周期中,有些軟件越做越好,有些軟件越做越差。現(xiàn)在我們要關(guān)注的是:如何在一個較長的時期內(nèi),把一個軟件越做越好。這就是軟件開發(fā)的控制與改進(jìn)。  閱讀全文

    posted @ 2008-10-14 00:20 非魚 閱讀(1823) | 評論 (0)編輯 收藏

         摘要: Several days ago I found that in a certain environment JavaMail may throw an AuthenticationException even you have set right user/password. Maybe this will not happen in a different mail server, but I'm not sure. So I just write it down and hope this can help someone who encounters such a problem.  閱讀全文

    posted @ 2008-09-19 01:34 非魚 閱讀(1332) | 評論 (2)編輯 收藏

         摘要: 架構(gòu)師最重要的工作是思考。思考導(dǎo)致決策,或者選擇。  閱讀全文

    posted @ 2008-09-18 22:54 非魚 閱讀(2349) | 評論 (4)編輯 收藏

         摘要: 三鹿奶粉,BABY KILLER。  閱讀全文

    posted @ 2008-09-14 00:02 非魚 閱讀(264) | 評論 (0)編輯 收藏

         摘要: Before your software dies, it's valuable. Remember this.  閱讀全文

    posted @ 2008-09-13 18:20 非魚 閱讀(1871) | 評論 (2)編輯 收藏

         摘要: This is a clean version. Thank you for visit.  閱讀全文

    posted @ 2008-09-13 11:04 非魚 閱讀(353) | 評論 (0)編輯 收藏

    政府有對產(chǎn)品免檢的權(quán)力
    廠商有對產(chǎn)品投毒的選擇
    我們只有不買國貨的自由

    posted @ 2008-09-13 00:58 非魚| 編輯 收藏

    這是一首我非常喜歡的歌。也看過一些翻譯,感覺不是太好,自己試著翻譯了一下。

    Step one you say we need to talk
    開始你說我們得談?wù)?br /> He walks you say sit down it's just a talk
    他走來走去你說坐下吧隨便點(diǎn)
    He smiles politely back at you
    他轉(zhuǎn)頭試圖向你微笑
    You stare politely right on through
    你平靜的注視著他
    Some sort of window to your right
    就在窗邊
    As he goes left and you stay right
    你看著他走進(jìn)陰影
    Between the lines of fear and blame
    就在傍遑與無助之間
    And you begin to wonder why you came
    你不知如何是好
    Where did I go wrong, I lost a friend
    我已經(jīng)盡力了
    Somewhere along in the bitterness
    可是失去朋友讓我感到痛苦
    And I would have stayed up with you all night
    我無法拯救你
    Had I know how to save a life
    只能陪你渡過漫漫長夜

    Let him know that you know best
    告訴他你是個專家
    Cause after all you do know best
    確實(shí)如此
    Try to slip past his defence
    別管他的無知
    Without granting innocence
    繞過他的抗拒
    Lay down a list of what is wrong
    記錄所有的問題
    The things you've hold him all along
    你都已告訴他了
    And pray to God he hears you
    現(xiàn)在只能禱告
    And pray to God he hears you
    神啊,請讓他聽到
    Where did I go wrong, I lost a friend
    我已經(jīng)盡力了
    Somewhere along in the bitterness
    可是失去朋友讓我感到痛苦
    And I would have stayed up with you all night
    我無法拯救你
    Had I know how to save a life
    只能陪你渡過漫漫長夜

    As he begins to raise his voice
    他開始激動
    You lower yours and grant him one last choice
    別急,讓他來選擇吧
    Drive until you lose the road
    或者一意孤行
    Or break with the ones you've followed
    或者從善如流
    He will do one of two things
    他有他的權(quán)利
    He will admit to everything
    或者接受現(xiàn)實(shí)
    Or he'll say he's just not the same
    或者繼續(xù)盲目
    And you'll begin to wonder why you came
    畢竟你已經(jīng)盡力了
    Where did I go wrong, I lost a friend
    我已經(jīng)盡力了
    Somewhere along in the bitterness
    可是失去朋友讓我感到痛苦
    And I would have stayed up with you all night
    我無法拯救你
    Had I know how to save a life
    只能陪你渡過漫漫長夜

    Where did I go wrong, I lost a friend
    我已經(jīng)盡力了
    Somewhere along in the bitterness
    可是失去朋友讓我感到痛苦
    And I would have stayed up with you all night
    我無法拯救你
    Had I know how to save a life
    只能陪你渡過漫漫長夜

    How to save a life
    我拿什么來拯救你
    How to save a life
    拿什么來拯救你


    我該拿什么來拯救你!我清楚知道你的身體,卻不了解你的靈魂。為什么你總在抗拒,為什么你不能信任我?你知道我能夠幫助你,可是你不相信我的心。不是我不能給你安全感,而是你自己沒有安全感。我尊重你的選擇,也給你選擇的機(jī)會。。。我只能向神祈禱,希望你能做出正確的選擇。這首歌說的是醫(yī)生和病人的復(fù)雜友誼,但在多數(shù)情況下,也適合兩個人之間的關(guān)系,無論友情或愛情。

    所以當(dāng)我把第一段的翻譯給大民看的時候,他說,很有觸動。


    也希望所有看到的人能夠喜歡。

    posted @ 2008-09-11 19:15 非魚 閱讀(259) | 評論 (0)編輯 收藏

    ??? 最近用到了MulticastSocket,發(fā)現(xiàn)在有些情況下它不能工作,當(dāng)然這是編碼的問題,是一個BUG,不過這個BUG較少出現(xiàn),一旦出現(xiàn)了也讓人摸不著頭緒。

    ??? 由于以前沒有用過這個東東,首先在網(wǎng)上找了個簡單的例子:

    ??? Server端:

    ?1?import?java.net.DatagramPacket;
    ?2?import?java.net.InetAddress;
    ?3?import?java.net.MulticastSocket;
    ?4?
    ?5?public?class?Server?{
    ?6???public?static?void?main(String?[]?arstring)?{
    ?7?????try?{
    ?8???????//?Create?a?multicast?datagram?socket?for?receiving?IP
    ?9???????//??multicast?packets.??Join?the?multicast?group?at
    10???????//??230.0.0.1,?port?7777.
    11???????MulticastSocket?multicastSocket?=?new?MulticastSocket(7777);
    12???????InetAddress?inetAddress?=?InetAddress.getByName("230.0.0.1");
    13???????multicastSocket.joinGroup(inetAddress);
    14???????//?Loop?forever?and?receive?messages?from?clients.??Print
    15???????//??the?received?messages.
    16???????while?(true)?{
    17?????????byte?[]?arb?=?new?byte?[100];
    18?????????DatagramPacket?datagramPacket?=?new?DatagramPacket(arb,?arb.length);
    19?????????multicastSocket.receive(datagramPacket);
    20?????????System.out.println(new?String(arb));
    21???????}
    22?????}
    23?????catch?(Exception?exception)?{
    24???????exception.printStackTrace();
    25?????}
    26???}
    27?}

    ??? Client端:

    ?1?public?class?Client?{
    ?2???public?static?void?main(String?[]?arstring)?{
    ?3?????try?{
    ?4???????//?Create?a?datagram?package?and?send?it?to?the?multicast
    ?5???????//??group?at?230.0.0.1,?port?7777.
    ?6???????for?(;?;)?{
    ?7?????????byte?[]?arb?=?new?byte?[]{'h',?'e',?'l',?'l',?'o'};
    ?8?????????InetAddress?inetAddress?=?InetAddress.getByName("230.0.0.1");
    ?9?????????DatagramPacket?datagramPacket?=
    10?????????????????new?DatagramPacket(arb,?arb.length,?inetAddress,?7777);
    11?????????MulticastSocket?multicastSocket?=?new?MulticastSocket();
    12?//??????multicastSocket.joinGroup(inetAddress);
    13?????????multicastSocket.send(datagramPacket);
    14???????}
    15?????}
    16?????catch?(Exception?exception)?{
    17???????exception.printStackTrace();
    18?????}
    19???}
    20?}

    ??? 在公司編譯、運(yùn)行都正常,回到家里發(fā)現(xiàn)Server不能收到broadcast消息了。跟蹤程序也沒有發(fā)現(xiàn)問題,網(wǎng)上也沒有找到答案。后來考慮到公司和家 里的網(wǎng)絡(luò)情況不同:公司里是通過內(nèi)網(wǎng)連接到INTERNET;在家則是在局域網(wǎng)上撥號連接到INTERNET,相當(dāng)于有兩個邏輯的網(wǎng)絡(luò)接口卡。于是在上述 例子中增加如下代碼:

    multicastSocket.setNetworkInterface(NetworkInterface.getByInetAddress(InetAddress.getLocalHost()));

    ??? 再次測試,成功!

    ??? 總結(jié):使用MulticastSocket時,如果發(fā)現(xiàn)broadcast不成功,要注意是否使用了多個網(wǎng)絡(luò)接口卡(物理的或邏輯的)。

    posted @ 2006-06-28 23:35 非魚 閱讀(4134) | 評論 (2)編輯 收藏

    主站蜘蛛池模板: 欧洲美熟女乱又伦免费视频| 在线天堂免费观看.WWW| 亚洲精品久久久www | 欧美在线看片A免费观看| 亚洲视频在线观看网址| 无码人妻AV免费一区二区三区| 伊人久久大香线蕉亚洲| 成人A毛片免费观看网站| 中文国产成人精品久久亚洲精品AⅤ无码精品| 亚洲高清乱码午夜电影网| 日本特黄特黄刺激大片免费| 久久精品国产亚洲AV未满十八| 日韩高清免费在线观看| 激情婷婷成人亚洲综合| 夜色阁亚洲一区二区三区| 免费无遮挡无码视频在线观看| 久久亚洲AV永久无码精品| 两个人看的www免费高清| 亚洲国产精品线在线观看| 最近中文字幕mv免费高清视频8| 亚洲欧洲国产视频| 我要看WWW免费看插插视频| 99亚洲乱人伦aⅴ精品| 亚洲人成无码久久电影网站| 三级黄色在线免费观看| 91亚洲一区二区在线观看不卡| 国产大片免费网站不卡美女 | 最近中文字幕免费2019| 亚洲一线产区二线产区精华| 免费激情视频网站| 成人福利在线观看免费视频| 久久亚洲AV无码精品色午夜麻| 日韩精品免费在线视频| 亚洲性无码av在线| 亚洲AV伊人久久青青草原| 久久亚洲免费视频| 亚洲精品国产综合久久久久紧 | 中文字幕无码一区二区免费| 亚洲激情电影在线| 四虎永久免费地址在线观看| 成全动漫视频在线观看免费高清版下载|