public List compareTo(List<Object> result)throws Exception{
Collections.sort(result,new Comparator<Object>(){
public int compare(Object arg0, Object arg1) {
if(arg0.getNumbe...
分类:
编程语言 时间:
2014-11-25 16:41:09
阅读次数:
170
NDK DEBUG方法
一、JNI单步调试,Debug As Android Native Apllication
二、借用NDK-STACK调试工具...
分类:
其他好文 时间:
2014-11-25 16:39:22
阅读次数:
160
Java集合框架的基本接口/类层次结构:
java.util.Collection [I]
+--java.util.List [I]
+--java.util.ArrayList [C]
+--java.util.LinkedList [C]
+--java.util.Vector [C]
+--java.util.Stack [C]
+--jav...
分类:
编程语言 时间:
2014-11-25 14:29:29
阅读次数:
215
前几天在编写一个自定义控件的时候,出现了这个这个异常:
Caused by: java.lang.UnsupportedOperationException: Can't convert to integer: type=0x3
然后定位到代码中的时候,发现是自定义控件中引用资源的时候报的错误,代码片段如下:
int iconId = mTypedArray.getInteger...
分类:
编程语言 时间:
2014-11-25 12:49:05
阅读次数:
181
leetcode Min StackDesign a stack that supports push, pop, top, and retrieving the minimum element in constant time.push(x) -- Push element x onto stac...
分类:
其他好文 时间:
2014-11-25 12:31:30
阅读次数:
129
MyEclipse 打开后有时候莫名的在server窗口里抛出“Could not create the view: An unexpected exception was thrown”错误,解决办法:打开myeclipse所在的wordspace文件夹,在下面子文件夹.metadata\.plu...
分类:
系统相关 时间:
2014-11-25 12:27:01
阅读次数:
205
有些情况程序员认为是异常,JVM看来却是正常的,比如年龄是负数;所以,在这种情况下,我们就需要自己手动创建并抛出异常,这就需要用到throw了。
Exception e = new Exception("Age Exception");//创建异常对象
throw e;//抛出异常
程序员自己创建并抛出的对象必须通过throws或try{}、catch{}进行相应的处理。
如果异常被抛到顶...
分类:
编程语言 时间:
2014-11-25 09:20:32
阅读次数:
162
问题 & 答案1.怎样交换一个字符串中的两个字段?Q:问题描述:怎样交换 foo 和 bar 的位置?String word1 = "bar";String word2 = "foo";String story = "Once upon a time, there was a foo and a b...
分类:
编程语言 时间:
2014-11-25 00:05:46
阅读次数:
194
本文是在学习中的总结,欢迎转载但请注明出处:http://blog.csdn.net/pistolove/article/details/41450987
本文是在学习中的总结,欢迎转载但请注明出处:http://blog.csdn.net/pistolove/article/details/41450987
通过本文你能学到如下知识:
(1)对数据结构中栈的理解,特别是Stack类中的peek()方法和pop()方法的区别。
(2)理解解题思路,提高思考问题的能力。
Given a string co...
分类:
编程语言 时间:
2014-11-24 22:40:46
阅读次数:
257
今天下午将远程数据库中数据导出然后导入到本地数据库,部署的项目连接本地数据库后jboss启动后编译报如下错误:
严重: Exception sending context initialized event to listener instance of class com.dicpsi.mis.contextListener.ContextListener
org.spri...
分类:
数据库 时间:
2014-11-24 22:31:48
阅读次数:
318