现在位置: 首页 > jjchinaipu发表的所有文章
  • 08月
  • 23日
移动开发 ⁄ 共 1056字 评论关闭
1. 确保设备已经插入USB插口。 2. 命令行执行 system_profiler SPUSBDataType    找到相应android机器的Vendor ID。 3.将vendor id的值写入 .android/adb_usb.ini文件 4.执行adb kill-server  adb start-server adb devices 如果能看到设备信息为 xxxxxx device ,那就成功了。 如果状态是unrecognized ,则需要打开android设备,勾选确认对话框。 5.打开eclipse ddms应该可以看到设备了。 打开android device chooser看看有没有设备。 如果没有,打开设备的usb debugging选项,来回勾选几次就可以了。 system_profiler SPU......
阅读全文
  • 06月
  • 06日
操作系统 ⁄ 共 6949字 评论关闭
程序1:检测接口的 inet_addr,netmask,broad_addr程序2:检查接口的物理连接是否正常程序3:更简单一点测试物理连接程序4:调节音量***************************程序1****************************************#include <stdio.h>#include <string.h>#include <stdlib.h>#include <errno.h>#include <unistd.h>#include <sys/types.h>#include <sys/socket.h>#include <netinet/in.h>#include <arpa/inet.h>#include <sys/ioctl.h>#include <net/if.h>static v......
阅读全文
Lightbox 虽然 Lightbox 非常具体站点,但是我想指出 Lightbox 技术在当今许多站点中都发挥了很大的作用。lightbox 是用户界面技术与一些 Ajax 技术的结合体。Web 页面的例子如 图 10 所示。 图 10. Lightbox JS 主页 如果单击某个图像,那么整个页面会变暗,同时一个方框出现在页面中间,显示放大后的所选图片。图 11 显示这个功能。 图 11. 单击图像后 lightbox 出现 这种技术具有很多优势。它可以把用户的注意力从页面的其他区域到转移选择的图片。因为用户可以单击 Close 返回正常的浏览页面,因此这种技术可以为用户显示很多......
阅读全文
  • 05月
  • 12日
综合 ⁄ 共 1203字 评论关闭
1、nil和null从字面意思来理解比较简单,nil是一个对象,而NULL是一个值,我的理解为nil是将对象设置为空,而null是将基本类型设置为空的,个人感觉有点像属性当中,基本类型分配为assign NSString类型一般分配copy,而对象一般用retain。而且我们对于nil调用方法,不会产生crash或者抛出异常。 看一段 nil -> Null-pointer to objective- c object NIL -> Null-pointer to objective- c class null-> null pointer to primitive type or absence of data. 看一下用法 NSURL *url = nil; Class  class = Nil; int *poin......
阅读全文
  • 04月
  • 25日
综合 ⁄ 共 1843字 评论关闭
Dark Parth http://acm.hdu.edu.cn/showproblem.php?pid=3933 Problem Description In the dark path, the single figure is walking difficultly in the listless rainfall. No one knows his real destination. ‘Young, have you ever tasted the loneliness walking in dark path; have you ever run about madly just to avoid the pain in the deep heart?' After BiYao's death, XiaoFan changed to GuiLi .Running in such darkness, leaving the rain wet out his clothes, leaving the darkness cover up his eyes, ......
阅读全文
  • 03月
  • 22日
综合 ⁄ 共 2388字 评论关闭
Python模块subprocess小记   在熟悉了Qt的QProcess以后,再回头来看python的subprocess总算不觉得像以前那么恐怖了。 和QProcess一样,subprocess的目标是启动一个新subprocess.Popen的进程并与之进行通讯。 这个模块主要就提供一个类Popen: class subprocess.Popen( args, bufsize=0, executable=None, stdin=None, stdout=None, stderr=None, preexec_fn=None, close_fds=False, shell=False, cwd=None, env=None, universal_newlin......
阅读全文
  • 03月
  • 16日
综合 ⁄ 共 1975字 评论关闭
软件开发的成败更多的是在于人,而不是技术。当从大学毕业时,我以为,只有精通了各种技术才能成为一名伟大的程序员,以为人件管理技术是经理们的专属领地。但事实却给我好好的上了一堂课。经常我能听到有人说人件管理技术是学不到的,是一种天份,对这种观点我不敢苟同。 没有人能生来就带有某种技能,我们都是通过观察和模仿(我们的偶像)来学习。你也许通过读书得到了这方面的一些知识,但是,我记得一句老话,我十几岁时读过的一本书的封面上印着它:“生活从书本中学不来,只能靠自己去感受。” 如果你感觉在处理人际交往方面......
阅读全文
  • 02月
  • 15日
综合 ⁄ 共 801字 评论关闭
有些查询不便在数据库中进行,那么就可以在datatable中执行。 Datatable dt=new Datatable();   dt.Columns.Add("ID", typeof(string));  //创建列   dt.Columns.Add("创建时间", typeof(string));//创建列  dt.Rows[l]["ID"] = "1";                                      //添加值   dt.Rows[l]["创建时间"] = "2012-06-05";      //添加值 Datatable newdt=new Datatable();   newdt = dt.Clone(); // 克隆dt 的结构,包括所有 dt 架构和约束,并无数据;                 DataRow[] rows = dt.Select(strWhere); // 从dt 中查......
阅读全文
请看:  java 实现视频转换通用工具类:获取视频元数据信息(一) 1.自动判断格式并调用相应的转换工具,默认方法 /** * 自动判断格式并调用相应的转换工具,默认方法 * @param srcVideoPath * @param tarVideoPath * @return */ public static boolean videoConver(String srcVideoPath,String tarVideoPath){ boolean boo = true; if(StringUtils.isNotEmpty(srcVideoPath) && StringUtils.isNotEmpty(tarVideoPath)){ srcVideoPath = BaseCommonUtil.replaceFliePath......
阅读全文
  • 01月
  • 25日
综合 ⁄ 共 576字 评论关闭
先安装brew,brew是一个包管理工具,有了它我们就可以很方便的安装xctool了,brew安装命令如下: curl -LsSf http://github.com/mxcl/homebrew/tarball/master | sudo tar xvz -C/usr/local --strip 1 下面我们来通过brew安装xctool: sudo brew update sudo brew install xctool (前面加sudo是为了防止没有权限) 搞定 此时运行xctool命令: ERROR: Missing the required -scheme argument.      表示xctool安装成功。 运行xctool(示例): 1.终端使用cp命令,进入工程目录 2.在终端bash执行:xctool -scheme testOClintNew ar......
阅读全文
  • 01月
  • 09日
综合 ⁄ 共 4072字 评论关闭
ClipDrawable 是一个挺好看的一个图片Drawable,操作起来也算比较简单。下面先把代码贴上来,通过例子进行说明。 main.xml文件的内容: [html] view plaincopyprint? <?xml version="1.0" encoding="utf-8"?>   <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"       android:layout_width="fill_parent"       android:layout_height="fill_parent"       android:orientation="vertical" >          <ImageView            android:id="@+id/image"           android:layout_w......
阅读全文
  • 12月
  • 24日
综合 ⁄ 共 2270字 评论关闭
GSMCallTracker本质上是一个Handler。 GSMCallTracker是Android的通话管理层。GSMCallTracker建立了ConnectionList 来管理现行的通话连接,并向上层提供电话调用接口。 在GSMCallTracker中维护着通话列表:connections。顺序记录了正连接上的通话,这些通话包括:ACTIVE,DIALING,ALERTING,HOLDING,INCOMING,WAITING 等状态的连接。GSMCallTracker 将这些连接分为了三类别进行管理: RingingCall: INCOMING ,WAITING ForegourndCall: ACTIVE, DIALING ,ALERTING BackgroundCall: HOLDING 上层函数通过getRingCall(),getForegr......
阅读全文