亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? inthashtable.java

?? 圖像文件分析
?? JAVA
字號:
// IntHashtable - a Hashtable that uses ints as the keys//// This is 90% based on JavaSoft's java.util.Hashtable.//// Visit the ACME Labs Java page for up-to-date versions of this and other// fine Java utilities: http://www.acme.com/java/package Acme;import java.util.*;/// A Hashtable that uses ints as the keys.// <P>// Use just like java.util.Hashtable, except that the keys must be ints.// This is much faster than creating a new Integer for each access.// <P>// <A HREF="/resources/classes/Acme/IntHashtable.java">Fetch the software.</A><BR>// <A HREF="/resources/classes/Acme.tar.gz">Fetch the entire Acme package.</A>// <P>// @see java.util.Hashtablepublic class IntHashtable extends Dictionary implements Cloneable    {    /// The hash table data.    private IntHashtableEntry table[];    /// The total number of entries in the hash table.    private int count;    /// Rehashes the table when count exceeds this threshold.    private int threshold;    /// The load factor for the hashtable.    private float loadFactor;    /// Constructs a new, empty hashtable with the specified initial     // capacity and the specified load factor.    // @param initialCapacity the initial number of buckets    // @param loadFactor a number between 0.0 and 1.0, it defines    //		the threshold for rehashing the hashtable into    //		a bigger one.    // @exception IllegalArgumentException If the initial capacity    // is less than or equal to zero.    // @exception IllegalArgumentException If the load factor is    // less than or equal to zero.    public IntHashtable( int initialCapacity, float loadFactor )	{	if ( initialCapacity <= 0 || loadFactor <= 0.0 )	    throw new IllegalArgumentException();	this.loadFactor = loadFactor;	table = new IntHashtableEntry[initialCapacity];	threshold = (int) ( initialCapacity * loadFactor );	}    /// Constructs a new, empty hashtable with the specified initial     // capacity.    // @param initialCapacity the initial number of buckets    public IntHashtable( int initialCapacity )	{	this( initialCapacity, 0.75f );	}    /// Constructs a new, empty hashtable. A default capacity and load factor    // is used. Note that the hashtable will automatically grow when it gets    // full.    public IntHashtable()	{	this( 101, 0.75f );	}    /// Returns the number of elements contained in the hashtable.     public int size()	{	return count;	}    /// Returns true if the hashtable contains no elements.    public boolean isEmpty()	{	return count == 0;	}    /// Returns an enumeration of the hashtable's keys.    // @see IntHashtable#elements    public synchronized Enumeration keys()	{	return new IntHashtableEnumerator( table, true );	}    /// Returns an enumeration of the elements. Use the Enumeration methods     // on the returned object to fetch the elements sequentially.    // @see IntHashtable#keys    public synchronized Enumeration elements()	{	return new IntHashtableEnumerator( table, false );	}    /// Returns true if the specified object is an element of the hashtable.    // This operation is more expensive than the containsKey() method.    // @param value the value that we are looking for    // @exception NullPointerException If the value being searched     // for is equal to null.    // @see IntHashtable#containsKey    public synchronized boolean contains( Object value )	{	if ( value == null )	    throw new NullPointerException();	IntHashtableEntry tab[] = table;	for ( int i = tab.length ; i-- > 0 ; )	    {	    for ( IntHashtableEntry e = tab[i] ; e != null ; e = e.next )		{		if ( e.value.equals( value ) )		    return true;		}	    }	return false;	}    /// Returns true if the collection contains an element for the key.    // @param key the key that we are looking for    // @see IntHashtable#contains    public synchronized boolean containsKey( int key )	{	IntHashtableEntry tab[] = table;	int hash = key;	int index = ( hash & 0x7FFFFFFF ) % tab.length;	for ( IntHashtableEntry e = tab[index] ; e != null ; e = e.next )	    {	    if ( e.hash == hash && e.key == key )		return true;	    }	return false;	}    /// Gets the object associated with the specified key in the     // hashtable.    // @param key the specified key    // @returns the element for the key or null if the key    // 		is not defined in the hash table.    // @see IntHashtable#put    public synchronized Object get( int key )	{	IntHashtableEntry tab[] = table;	int hash = key;	int index = ( hash & 0x7FFFFFFF ) % tab.length;	for ( IntHashtableEntry e = tab[index] ; e != null ; e = e.next )	    {	    if ( e.hash == hash && e.key == key )		return e.value;	    }	return null;	}    /// A get method that takes an Object, for compatibility with    // java.util.Dictionary.  The Object must be an Integer.    public Object get( Object okey )	{	if ( ! ( okey instanceof Integer ) )	    throw new InternalError( "key is not an Integer" );	Integer ikey = (Integer) okey;	int key = ikey.intValue();	return get( key );	}    /// Rehashes the content of the table into a bigger table.    // This method is called automatically when the hashtable's    // size exceeds the threshold.    protected void rehash()	{	int oldCapacity = table.length;	IntHashtableEntry oldTable[] = table;	int newCapacity = oldCapacity * 2 + 1;	IntHashtableEntry newTable[] = new IntHashtableEntry[newCapacity];	threshold = (int) ( newCapacity * loadFactor );	table = newTable;	for ( int i = oldCapacity ; i-- > 0 ; )	    {	    for ( IntHashtableEntry old = oldTable[i] ; old != null ; )		{		IntHashtableEntry e = old;		old = old.next;		int index = ( e.hash & 0x7FFFFFFF ) % newCapacity;		e.next = newTable[index];		newTable[index] = e;		}	    }	}    /// Puts the specified element into the hashtable, using the specified    // key.  The element may be retrieved by doing a get() with the same key.    // The key and the element cannot be null.     // @param key the specified key in the hashtable    // @param value the specified element    // @exception NullPointerException If the value of the element     // is equal to null.    // @see IntHashtable#get    // @return the old value of the key, or null if it did not have one.    public synchronized Object put( int key, Object value )	{	// Make sure the value is not null.	if ( value == null )	    throw new NullPointerException();	// Makes sure the key is not already in the hashtable.	IntHashtableEntry tab[] = table;	int hash = key;	int index = ( hash & 0x7FFFFFFF ) % tab.length;	for ( IntHashtableEntry e = tab[index] ; e != null ; e = e.next )	    {	    if ( e.hash == hash && e.key == key )		{		Object old = e.value;		e.value = value;		return old;		}	    }	if ( count >= threshold )	    {	    // Rehash the table if the threshold is exceeded.	    rehash();	    return put( key, value );	    } 	// Creates the new entry.	IntHashtableEntry e = new IntHashtableEntry();	e.hash = hash;	e.key = key;	e.value = value;	e.next = tab[index];	tab[index] = e;	++count;	return null;	}    /// A put method that takes an Object, for compatibility with    // java.util.Dictionary.  The Object must be an Integer.    public Object put( Object okey, Object value )	{	if ( ! ( okey instanceof Integer ) )	    throw new InternalError( "key is not an Integer" );	Integer ikey = (Integer) okey;	int key = ikey.intValue();	return put( key, value );	}    /// Removes the element corresponding to the key. Does nothing if the    // key is not present.    // @param key the key that needs to be removed    // @return the value of key, or null if the key was not found.    public synchronized Object remove( int key )	{	IntHashtableEntry tab[] = table;	int hash = key;	int index = ( hash & 0x7FFFFFFF ) % tab.length;	for ( IntHashtableEntry e = tab[index], prev = null ; e != null ; prev = e, e = e.next )	    {	    if ( e.hash == hash && e.key == key )		{		if ( prev != null )		    prev.next = e.next;		else		    tab[index] = e.next;		--count;		return e.value;		}	    }	return null;	}    /// A remove method that takes an Object, for compatibility with    // java.util.Dictionary.  The Object must be an Integer.    public Object remove( Object okey )	{	if ( ! ( okey instanceof Integer ) )	    throw new InternalError( "key is not an Integer" );	Integer ikey = (Integer) okey;	int key = ikey.intValue();	return remove( key );	}    /// Clears the hash table so that it has no more elements in it.    public synchronized void clear()	{	IntHashtableEntry tab[] = table;	for ( int index = tab.length; --index >= 0; )	    tab[index] = null;	count = 0;	}    /// Creates a clone of the hashtable. A shallow copy is made,    // the keys and elements themselves are NOT cloned. This is a    // relatively expensive operation.    public synchronized Object clone()	{	try	    {	    IntHashtable t = (IntHashtable) super.clone();	    t.table = new IntHashtableEntry[table.length];	    for ( int i = table.length ; i-- > 0 ; )		t.table[i] = ( table[i] != null ) ?		    (IntHashtableEntry) table[i].clone() : null;	    return t;	    }	catch ( CloneNotSupportedException e)	    {	    // This shouldn't happen, since we are Cloneable.	    throw new InternalError();	    }	}    /// Converts to a rather lengthy String.    public synchronized String toString()	{	int max = size() - 1;	StringBuffer buf = new StringBuffer();	Enumeration k = keys();	Enumeration e = elements();	buf.append( "{" );	for ( int i = 0; i <= max; ++i )	    {	    String s1 = k.nextElement().toString();	    String s2 = e.nextElement().toString();	    buf.append( s1 + "=" + s2 );	    if ( i < max )		buf.append( ", " );	    }	buf.append( "}" );	return buf.toString();	}    }class IntHashtableEntry    {    int hash;    int key;    Object value;    IntHashtableEntry next;    protected Object clone()	{	IntHashtableEntry entry = new IntHashtableEntry();	entry.hash = hash;	entry.key = key;	entry.value = value;	entry.next = ( next != null ) ? (IntHashtableEntry) next.clone() : null;	return entry;	}    }class IntHashtableEnumerator implements Enumeration    {    boolean keys;    int index;    IntHashtableEntry table[];    IntHashtableEntry entry;    IntHashtableEnumerator( IntHashtableEntry table[], boolean keys )	{	this.table = table;	this.keys = keys;	this.index = table.length;	}	    public boolean hasMoreElements()	{	if ( entry != null )	    return true;	while ( index-- > 0 )	    if ( ( entry = table[index] ) != null )		return true;	return false;	}    public Object nextElement()	{	if ( entry == null )	    while ( ( index-- > 0 ) && ( ( entry = table[index] ) == null ) )		;	if ( entry != null )	    {	    IntHashtableEntry e = entry;	    entry = e.next;	    return keys ? new Integer( e.key ) : e.value;	    }	throw new NoSuchElementException( "IntHashtableEnumerator" );	}    }

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲一区免费观看| 欧美无砖砖区免费| 欧美日韩一区二区欧美激情| 国产色产综合产在线视频| 亚洲一区在线电影| 成人免费视频免费观看| 欧美一级久久久| 一区二区三区在线视频免费| 国产精品一二二区| 欧美日韩久久一区| 亚洲影院免费观看| 波多野结衣中文字幕一区二区三区 | 中文av一区特黄| 美女脱光内衣内裤视频久久网站| 色综合久久久久| 国产女主播一区| 国产美女精品在线| 日韩欧美国产三级| 天天色 色综合| 欧亚一区二区三区| 一区二区三区国产精品| 北条麻妃一区二区三区| 久久久久99精品国产片| 国产精品一区二区果冻传媒| 欧美成人女星排名| 国产综合色在线| 久久久综合九色合综国产精品| 久久国产精品99久久久久久老狼| 91精品国产色综合久久ai换脸 | 中文字幕永久在线不卡| 成人一区二区三区视频| 久久久不卡网国产精品一区| 国产乱码精品一区二区三区av| 欧美电视剧在线观看完整版| 久久97超碰国产精品超碰| 26uuu精品一区二区三区四区在线| 老司机免费视频一区二区三区| 日韩午夜三级在线| 国内精品伊人久久久久av影院| 2023国产精品| 成人性生交大片免费 | 久久精品亚洲麻豆av一区二区| 国产精品77777| 国产精品视频在线看| 色婷婷激情一区二区三区| 亚洲影院久久精品| 日韩欧美电影在线| 国产精品456露脸| 日韩一区欧美小说| 3751色影院一区二区三区| 麻豆精品视频在线| 中文字幕免费观看一区| 91电影在线观看| 久久精工是国产品牌吗| 日本一区二区三区国色天香| 91麻豆国产在线观看| 亚洲自拍偷拍麻豆| 日韩精品一区二区三区四区 | 国产风韵犹存在线视精品| 国产欧美日韩激情| 欧美伦理电影网| 国产真实乱对白精彩久久| 亚洲日本成人在线观看| 欧美日韩国产bt| 国产999精品久久| 图片区小说区区亚洲影院| 久久久99精品久久| 911国产精品| 91一区二区在线| 毛片不卡一区二区| 亚洲日本丝袜连裤袜办公室| 日韩片之四级片| 日本久久一区二区| 国产成人免费在线观看不卡| 亚洲一二三专区| 中文字幕制服丝袜一区二区三区 | 国产一区二区三区免费| 亚洲一区二区三区爽爽爽爽爽 | 国产成人免费在线| 偷窥少妇高潮呻吟av久久免费| 欧美国产欧美亚州国产日韩mv天天看完整 | 国产成人综合亚洲91猫咪| 亚洲一区二区五区| 国产精品国产三级国产普通话蜜臀| 欧美一区二区福利在线| 欧美综合天天夜夜久久| 不卡av在线网| 国产精品1024久久| 精品无人区卡一卡二卡三乱码免费卡| 亚洲欧美另类久久久精品| 国产欧美日产一区| 久久人人爽爽爽人久久久| 日韩欧美一区二区久久婷婷| 欧美日韩视频第一区| 一本大道久久精品懂色aⅴ| 国产精品白丝av| 国产做a爰片久久毛片| 免费人成在线不卡| 水野朝阳av一区二区三区| 一区二区三区91| 亚洲精品免费电影| 中文字幕一区二区三区不卡在线 | 色综合久久综合网97色综合| 日本亚洲免费观看| 亚洲天堂久久久久久久| 国产亚洲精品bt天堂精选| 日韩精品在线网站| 日韩三级中文字幕| 欧美一区二区三区四区五区 | 欧美日韩在线精品一区二区三区激情| 成人av在线资源网站| 国产成人激情av| 国产大片一区二区| 懂色av一区二区三区蜜臀| 国产成a人无v码亚洲福利| 成人开心网精品视频| 99re亚洲国产精品| 91福利在线免费观看| 欧美日韩国产成人在线免费| 制服丝袜亚洲色图| 日韩一区二区三区av| 久久亚洲欧美国产精品乐播| 久久先锋影音av| 亚洲天堂网中文字| 亚洲一级片在线观看| 日本午夜一区二区| 国产精品一区二区三区网站| 国产91在线观看| 色哟哟国产精品| 91精品国产色综合久久不卡电影| 日韩欧美色电影| 日本一区二区三区视频视频| 亚洲天堂精品视频| 天天操天天综合网| 国产麻豆视频一区| 99久久婷婷国产综合精品| 欧美性一二三区| 亚洲精品在线观| 中文字幕在线不卡一区| 亚洲成人精品在线观看| 久久机这里只有精品| 成人免费精品视频| 欧美色图天堂网| 精品91自产拍在线观看一区| 中文字幕色av一区二区三区| 亚洲国产视频一区二区| 老司机免费视频一区二区三区| jvid福利写真一区二区三区| 欧美在线观看视频在线| 欧美精品一区二区精品网| 亚洲欧美日韩人成在线播放| 日韩国产一二三区| 99精品桃花视频在线观看| 日韩精品一区二区三区中文不卡 | 国产午夜精品理论片a级大结局| 成人免费视频在线观看| 蜜臀精品久久久久久蜜臀| 欧美日韩国产小视频在线观看| 欧美一区二区三区免费观看视频| 国产精品色噜噜| 久久99在线观看| 色天使久久综合网天天| 久久精品亚洲精品国产欧美kt∨ | 亚洲已满18点击进入久久| 久久国产麻豆精品| 欧美性色黄大片手机版| 国产精品女主播在线观看| 日本午夜精品一区二区三区电影| 不卡av在线网| 久久久久久夜精品精品免费| 亚洲成人av中文| www.欧美.com| 久久蜜桃av一区精品变态类天堂| 午夜欧美在线一二页| 99国产精品久久久久久久久久久 | 精品国产乱码久久| 亚洲国产精品欧美一二99| aaa亚洲精品| 国产免费成人在线视频| 精品午夜久久福利影院| 亚洲国产精品高清| 国产激情视频一区二区在线观看| 日韩一区二区在线观看| 性做久久久久久久免费看| 91国偷自产一区二区开放时间| 国产精品美女一区二区在线观看| 国产一区二区久久| 精品国产91亚洲一区二区三区婷婷| 日韩国产在线一| 91精品婷婷国产综合久久竹菊| 亚洲一区二区在线免费观看视频| 日本道免费精品一区二区三区| 中文字幕日本乱码精品影院| 成人av综合在线| 亚洲欧美色一区| 色嗨嗨av一区二区三区| 一区二区三区免费在线观看| 色8久久人人97超碰香蕉987| 夜夜爽夜夜爽精品视频| 欧美日韩精品一区二区三区|