摘要:一、基础知识
1、super(参数):调用基类中的某一个构造函数(应该为构造函数中的第一条语句)
2、this(参数):调用本类中另一种形成的构造函数(应该为构造函数中的第一条语句)
3、super: 它引用当前对象的直接父类中的成员(用来访问直接父类中被隐藏的父类中成员数据或函数,基类与派生类中有相同成员定义时)
如:super.变量名super.成员函数据名(实参)
4、this:它......
摘要:线性表,链表等是常用的数据结构,在进行java开发时,jdk已经为我们提供了一系列相应的类来实现基本的数据结构。这些类均在java.util包中。
collection ├list │├linkedlist │├arraylist │└vector │ └stack └set
map ├hashtable ├hashmap └weakhashmap collection接口
collec......
使用StopWatch类输出时间戳上一页 ...this.starttime = -1; 【程序编程相关:
思科和微软合作 拟推出全新通信解决方案】 【推荐阅读:
思科圆梦数字家庭市场 一相情愿?】this.stoptime = -1; 【扩展信息:
电盈购网通宽带留悬案 田溯宁可能为操盘手】 } /** * split the time. */ public void split() { this.stoptime = system.currenttimemillis(); } /** * remove a split. */ public void unsplit() { this.stoptime = -1; } /** * get the time on the stopwatch. this is either the * time between start and latest split, between start and stop, * or the time between the start and the moment this method is called. */ public long gettime() { if(stoptime != -1) { return (system.currenttimemillis() - this.starttime); } else { ...
下一页 摘要:索引同简单数据类型的定义一样,java虚拟机(jvm)还定义了索引(reference)这种数据类型。索引类型可以“引用”变量,由于java没有明确地定义指针类型,所以索引类型可以被认为就是指向实际值或者指向变量所代表的实际值的指针。一个对象可以被多于一个以上的索引所“指”。jvm从不直接对对象寻址而是操作对象的索引。索引类型分成三种,它们是:类(class)、接口(interface)和数组(a......