javaµÚ9Ìì´úÂ루¼¯ºÏÀࣩ
/**********Customer .java begin***********/
import java.util.HashSet;
import java.util.Set;
/**
* Èç¹ûÁ½¸öCustomer¶ÔÏónamaÊôÐÔºÍageÊôÐÔÏàͬ£¬ÄÇôÕâÁ½¸öCustomer¶ÔÏóÏàµÈ¡£
* @author Administrator
*
*/
public class Customer {
private String name;
private int age;
public String getName() {
return name;
}
public int getAge() {
return age;
}
public void setName(String name) {
this.name = name;
}
public void setAge(int age) {
this.age = age;
}
public Customer(String name, int age) {
super();
this.name = name;
this.age = age;
}
public Customer(){}
/**
* Èç¹ûCustomerÀา¸ÇÁËObjectÀàÖеÄequals·½·¨£¬µ«Ã»Óи²¸ÇObjectÖеÄHashCode·½·¨£¬
* ¾Í»áµ¼Öµ±Customer1.equals.(Customer2)Ϊtrueʱ£¬¶øCustomer1ºÍCustomer2µÄ¹þ
* Ï£Âë²»Ò»¶¨Ò»Ñù£¬¾Í»áʹHashSetÎÞ·¨¹¤×÷¡£
*/
@Override
public boolean equals(Object obj) {
if((obj instanceof Customer)){
Customer other=(Customer) obj;
if(this.name.equals(other.getName()) && this.age==other.getAge()) {
return true;
}
}
return false;
}
/**
* ΪÁ˱£Ö¤HashSetµÄÕý³£¹¤×÷£¬Èç¹ûCustomerÀา¸ÇÁËequals·½·¨£¬Í¬Ê±Ò²Ó¦¸ÃÈ¥¸²¸ÇhashCode
* ·½·¨£¬²¢ÇÒ±£Ö¤Á½¸öÏàµÈ¶ÔÏóµÄ¹þÏ£ÂëÒ²ÊÇÒ»Ñù¡£
*/
// @Override
public int hashCode() {
int result;
result=(name==null?0:name.hashCode());
result=result+age;
return result;
}
public static void main(String args[]){
Set set=new HashSet();
&nb
Ïà¹ØÎĵµ£º
תÌù..............
Java»ù´¡·½Ãæ:
0¡¢×÷ÓÃÓòpublic,private,protected,ÒÔ¼°²»Ð´Ê±µÄÇø±ð
´ð£ºÇø±ðÈçÏ£º
×÷ÓÃÓò µ±Ç°Àà ͬһpackage ×ÓËïÀà ÆäËûpackage
public √ √ √ √
protected √ √ √ ×
friendly √ √ × ×
private √ &t ......
Ò»Ö±¶¼¸Ðµ½ºÜÃÔ㣬¶ÔÓÚÓïÑÔµÄÑ¡Ôñ£¬ÒòΪ»¹ÊDzËÄñµÄÔÒò£¬ÎÞ·¨¿´Í¸ÀïÃæµÄÖÖÖÖ¹Øϵ£¬Ò»Ö±ÔÚ¾À½áÆäÖС£Æäʵ×Ô¼ºÒ²Ã÷°×“´óµÀÖÁ¼ò”£¬µ«»¹ÊÇ°´ÄͲ»×¡¿ñÏëµÄ˼Ð÷£¬ÌرðÊǵ±´Ó¹«Ë¾³ö²î»ØÀ´Ö®ºó£¬¼¸Ì춼ûÓÐ×öʲôÊÂÇé¡£
¶ÔCÓÐÒ»ÖÖÆ«ºÃ£¬ËùÒÔÒ»Ö±ÔÚÐÄÀï¾ÍÓеãÅųâjava¡£ËäÈ»javaÖÐÒ²ÓкܶණÎ÷Ҫѧ£¬µ«ÊÇDZÒâʶÀïÃæ¶ÔÕ ......
×òÌ죬ÎÒµÄÅóÓÑÇë½ÌÎÒÕýÔò±í´ïʽ¡£ÎÒÒ²ºÃ¾ÃûÓÐд¹ýÕýÔò±í´ïʽÁË£¬×òÌì¸ÕºÃ¿´ÁËÏÂÈçÅôÍø´´Ê¼ÈËÑîÖпÆÀÏʦ¹ØÓÚÕýÔò±í´ïʽµÄ½²½â¡£Ê¹ÎÒ¼ÓÉîÁËÕýÔò±í´ïʽµÄÓ¡Ïñ¡£ÏÖÎÒ°ÑËû×ܽáÏ£º
Ðí¶àÓïÑÔ£¬°üÀ¨Perl¡¢PHP¡¢Python¡¢JavaScriptºÍJScript£¬¶¼Ö§³ÖÓÃÕýÔò ......
´óѧJAVAʵÑéÎå
ÕâÒ»´ÎµÄʵÑé×öµÄ²»ÂúÒ⣬¿ÒÇë¸÷λÅúÆÀ£¬¿ÒÇë¸÷λÌṩ·½·¨¼°½¨Òé
µÚÒ»¸öʵÑé
Ö¸¶¨²»Í¬ÐÒéµÄURLµØÖ·£¬»ñµÃ×ÊÔ´ÎļþµÄÄÚÈݺÍÊôÐÔ
URLStudy.java
package first;
import java.awt.FileDialog;
import java.awt.Font;
import java.awt.TextArea;
import java.io.FileWriter ......
http://blog.ixpub.net/html/36/16577236-371599.html
06Äê11Ô£¬Sun¹«Ë¾¸ß²ã¹ÙÔ±Ðû²¼£º±à³ÌÓïÑÔJava¿ª·ÅÔ´Â룬²¢ÇÒ×ñÊØGPL¹æÔò£¬²©µÃһƬºÃÆÀ¡£¾¹ý°ëÄêµÄ²»Ð¸Å¬Á¦£¬SunÖÕÓڰѾßÓÐ 600¶àÍòÐеÄJavaÔ´´úÂ루ָJDKÈí¼þ°ü£©ÕûÀí£¨ÇåÀí£©Íê±Ï£¬¼ÓÒÔ¹«²¼£¬Ê¹Java±äΪÍêÈ«¿ÉÓã¨fully buildable£©µÄ¿ªÔ´±à³ÌÓïÑÔ¡£07Äê5ÔÂ8È ......