一、普通1、private String[] method =
null;ArrayAdapter methodAdapter = new
ArrayAdapter(this,android.R.layout.simple_spinner_item, method);methodSpinner =
...
分类:
其他好文 时间:
2014-05-07 18:32:48
阅读次数:
274
一. 什么是Native Method 简单地讲,一个Native
Method就是一个java调用非java代码的接口。一个Native
Method是这样一个java的方法:该方法的实现由非java语言实现,比如C。这个特征并非java所特有,很多其它的编程语言都有这一机制,比如在C++中,你可...
分类:
编程语言 时间:
2014-05-07 10:38:32
阅读次数:
373
### 背景
银时跟我讲,想从 Netty3迁移到Netty4 。
问其原因是因为 Netty3在容器里会报错,错误堆栈:
java.io.IOException: 无法立即完成一个非阻止性套接字操作。
at sun.nio.ch.SocketDispatcher.close0(Native Method)
at sun.nio.ch.SocketDisp...
分类:
其他好文 时间:
2014-05-07 06:30:21
阅读次数:
425
1. 制作Debian Live USB。
2. 安装grub-pc
3. 挂载/和/boot
4. grub-install
5. mount --bind ...
......
Description
Squares and rectangles fascinated the famous Dutch painter Piet Mondriaan. One night, after producing the drawings in his 'toilet series' (where he had to use his toilet paper to draw on,...
分类:
其他好文 时间:
2014-05-07 05:16:29
阅读次数:
385
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)类型错误...
分类:
数据库 时间:
2014-05-07 05:15:51
阅读次数:
332
I make a connection through SSH and then I type:
# x0vncserver --PasswordFile=/home/hello/.vnc/passwd
x0vncserver: unable to open display ""
~ImageCleanup called
the reason is :
...
分类:
其他好文 时间:
2014-05-07 04:23:43
阅读次数:
581
【题目】
原文:
1.4 Write a method to decide if two strings are anagrams or not.
译文:
写一个函数判断两个字符串是否是变位词。
【分析】
变位词(anagrams)指的是组成两个单词的字符相同,但位置不同的单词。比如说, abbcd和abcdb就是一对变位词。该题目有两种思路:
【思路一】
由于变位词只是字...
分类:
其他好文 时间:
2014-05-06 23:17:56
阅读次数:
383
如果我们在 Objective C 中向一个对象发送它无法处理的消息,会出现什么情况呢?我们知道发送消息是通过
objc_send(id, SEL, ...) 来实现的,它会首先在对象的类对象的 cache,method list 以及父类对象的 cache, method list 中依次查找 SEL 对应的 IMP;这个是需要对类对象的结构熟悉,不清楚的可以参考我的下一篇文章《object...
分类:
其他好文 时间:
2014-05-06 21:24:33
阅读次数:
450
public class StringHandleExampleActivity extends
Activity { /** Called when the activity is first created. */ private TextView
textView; ...
分类:
移动开发 时间:
2014-05-06 14:39:57
阅读次数:
350