`
文章列表
如果没有接触过命令式的调试器,看一下这个JDB Debugging Tutorial,举了一个例子,把调试相关的东西都介绍了一些,不过不是太详细,但是比较容易理解。然后还有个Part 2,又介绍了几个命令。读完以后应该就基本上会用jdb了,也对这个命令式的调试器有所了解了。这一篇'jdb' - The Java Debugger介绍地更深入一些,包括如何调试已经在运行的程序和调试多线程的程序。不过对于jdb的命令只是稍有解释,没有举例子说明。对于使用过gdb的朋友,可能理解起来会比较方便。我也只是把比较常用命令的作用在这里介绍一下吧: run 在jvm中以调试模式运行所调试的程序 cont ...
1. GTK的安装 #这将安装gcc/g++/gdb/make 等基本编程工具 sudo apt-get install build-essential #这将安装 libgtk2.0-dev libglib2.0-dev 等开发相关的库文件 sudo apt-get install gnome-core-devel #用于在编译GTK程序时自动找出头文件及库文件位置 sudo apt-get ins ...

scala保留字

abstract case catch class def do else extends false final finally for forSome if implicit import lazy match new null object override package private protected return sealed super this throw trait try true type val var while with yield _ : = => <- <: <% >: # @   (当java中使用到 ...

iphone alert window

// open a dialog with just an OK button UIActionSheet *actionSheet = [[UIActionSheet alloc] initWithTitle:@"Very Good!" delegate:nil cancelButtonTitle:nil destructiveButtonTitle:@"OK" otherButtonTitles:nil]; actionSheet.actionSheetStyle = UIActionSheetStyleDefault; [actionShe ...
减号表示一个函数、或者方法、或者消息的开始 括号可以认为是如何调用你刚才写的这个方法,通常在Objective-C里说“消息”。 同一个数组可以保存不同的对象 C用NULL,OC用nil Objective-C 有种叫做 id 的型别,它的运作有时候像是 void*,不过它却严格规定只能用在对象。 基本类别库 import NSObject.h;BOOL型为YES or NO #import vs #include:#import。#import 由 gcc 编译器支持。我并不建议使用 #include,#import 基本上跟 .h 档头尾的 #ifndef #define #en ...
[UIViewController _loadViewFromNibNamed:bundle:] loaded the "BlueView" nib but the view outlet was not set. 查书才知道,没有做nib文件到xxxViewControler程序的关联,特此记录下来: 1, 打开nib文件 2, 点击"File's Owner", 按command+4,设置Class为xxxViewControler 3, 按Control+"Files's Owner"或选中File‘s Own ...
error: 'for' loop initial declaration used outside C99 mode的解决方法 for(int i = 0;i<10;i++)这样写循环时可能会出现如题编译错误,解决方法有两种,如下: 1 将文件后缀名由".c"改为".cpp" 2 int i;    for(i=0;i<10;i++)
1.直接Build and run,找不到SDK 2.0 打开工程, 在菜单中选择Projects,  General标签中的最下面有一个 Base SDK for All Configurations (默认的是 iPhone Device 2.0),改成IOS2.0 2.再次build,出現Code Sign error: The identity 'iPhone Developer' doesn't match any valid certificate/private key pair in the default key 這是因为默认Build选择的是设备, 如果改成Sim ...
#coding=utf-8 list=[282435671,2000,9000035401,1,9000035701,2,252444730,3000,9000035601,2,9000035401,1,9000035701,2] mid=input("shu ru mu biao shu zi:") try: index=list.index(mid) if index==0: print None print list[index+1] elif index==len(list)-1: print list[index-1] ...
The require method is defined in standalone object, Predef.  Predef’s members are imported automatically into every Scala source file

python中的拖动源

#coding=utf-8 import wx class DragController(wx.Control): """Just a little control to handle dragging the text from a text control. We use a separate control so as to not interfere with the native drag-select functionality of the native text control.""" ...

scala unit

A result type of Unit indicates the function returns no interesting value. Scala’s Unit type is similar to Java’s void type, and in fact every void-returning method in Java is mapped to a Unit-returning method in Scala. Methods with the result type of Unit, therefore, are only executed for their si ...
一、问题的发现与提出   在Python类的方法(method)中,要调用父类的某个方法,在Python 2.2以前,通常的写法如代码段1: 代码段1: class A: def __init__(self): print "enter A" print "leave A" class B(A): def __init__(self): print "enter B" A.__init__(self) print "leave B" > ...
  哦啦 啦 , 哦耶耶
At the beginning of this chapter, we talked about how an instance is created: its class is sent the message alloc, which creates an instance of that class and returns a pointer to it, and that instance is sent the message init. The init message isn’t a special type of instance method, though; it is s ...
Global site tag (gtag.js) - Google Analytics