Article View: cn.bbs.comp.lang.java
Article #19092Re: һ�����String�Ƚ��ٶȵķ���
From: Lejun
Date: Sat, 10 Jan 2004 10:20
Date: Sat, 10 Jan 2004 10:20
23 lines
1928 bytes
1928 bytes
�� �� reoal.bbs@freecity.cnzju.net (�ұ���������ѧ��18�����) �Ĵ������ᵽ: �� : �� ��: Re: һ�����String�Ƚ��ٶȵķ��� : ����վ: Ʈ��ˮ�Ƽ� (Sat Jan 10 16:41:08 2004) : ת��վ: SJTU!news.ccie.net.cn!Freecity : : A pool of strings, initially empty, is maintained privately by the class : String. : : When the intern method is invoked, if the pool already contains a string : equal to this String object as determined by the equals(Object) method, then ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ���ʱ����Ҫ�Ƚ�ô�� ����intern�ƺ���native�ķ������Ͳ�֪�������Щɶ�ˡ��� : the string from the pool is returned. Otherwise, this String object is added : to the pool and a reference to this String object is returned. : : It follows that for any two strings s and t, s.intern() == t.intern() is true : if and only if s.equals(t) is true. : -- [m[1;34m�� ��Դ:����ˮ˼Դ bbs.sjtu.edu.cn��[FROM: 221.137.68.76][m
Technical Details
Message-ID:
<4ACiRK$AaL@bbs.sjtu.edu.cn>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!sn-xit-09!supernews.com!newshosting.com!nx02.iad01.newshosting.com!feed2.newsreader.com!newsreader.com!maily.cic.tsinghua.edu.cn!news.ccie.net.cn!SJTUShow Full Headers
Complete Article Headers
X-Google-Language: Chinese,GB X-Google-Thread: f6cb0,5bd5248b5bc616b6 X-Google-Attributes: gidf6cb0,public X-Google-ArrivalTime: 2004-01-10 02:24:32 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!sn-xit-09!supernews.com!newshosting.com!nx02.iad01.newshosting.com!feed2.newsreader.com!newsreader.com!maily.cic.tsinghua.edu.cn!news.ccie.net.cn!SJTU From: lejun.bbs@bbs.sjtu.edu.cn (Lejun) Newsgroups: cn.bbs.comp.lang.java Subject: Re: һ�����String�Ƚ��ٶȵķ��� Date: 10 Jan 2004 10:20:19 GMT Organization: ��ˮ˼Դ Message-ID: <4ACiRK$AaL@bbs.sjtu.edu.cn> Mime-Version: 1.0 Content-Type: text/plain; charset="gb2312" Content-Transfer-Encoding: 8bit X-Filename: Java/M.1073729828.A