Java Doc for CustomHashtable.java in  » IDE-Eclipse » jface » org » eclipse » jface » viewers » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Eclipse » jface » org.eclipse.jface.viewers 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.eclipse.jface.viewers.CustomHashtable

CustomHashtable
final class CustomHashtable (Code)
CustomHashtable associates keys with values. Keys and values cannot be null. The size of the Hashtable is the number of key/value pairs it contains. The capacity is the number of key/value pairs the Hashtable can hold. The load factor is a float value which determines how full the Hashtable gets before expanding the capacity. If the load factor of the Hashtable is exceeded, the capacity is doubled.

CustomHashtable allows a custom comparator and hash code provider.



Field Summary
final public static  intDEFAULT_CAPACITY
     The default capacity used when not specified in the constructor.
transient  intelementCount
    
transient  HashMapEntry[]elementData
    
transient  intfirstSlot
    
transient  intlastSlot
    

Constructor Summary
public  CustomHashtable()
     Constructs a new Hashtable using the default capacity and load factor.
public  CustomHashtable(int capacity)
     Constructs a new Hashtable using the specified capacity and the default load factor.
public  CustomHashtable(IElementComparer comparer)
     Constructs a new hash table with the default capacity and the given element comparer.
public  CustomHashtable(int capacity, IElementComparer comparer)
     Constructs a new hash table with the given capacity and the given element comparer.
public  CustomHashtable(CustomHashtable table, IElementComparer comparer)
     Constructs a new hash table with enough capacity to hold all keys in the given hash table, then adds all key/value pairs in the given hash table to the new one, using the given element comparer.

Method Summary
public  booleancontainsKey(Object key)
     Answers if this Hashtable contains the specified object as a key of one of the key/value pairs.
public  Enumerationelements()
     Answers an Enumeration on the values of this Hashtable.
public  Objectget(Object key)
     Answers the value associated with the specified key in this Hashtable.
public  IElementComparergetComparer()
     Returns the element comparer used to compare keys and to obtain hash codes for keys, or null if no comparer has been provided.
public  Enumerationkeys()
     Answers an Enumeration on the keys of this Hashtable.
public  Objectput(Object key, Object value)
     Associate the specified value with the specified key in this Hashtable. If the key already exists, the old value is replaced.
public  Objectremove(Object key)
     Remove the key/value pair with the specified key from this Hashtable.
public  intsize()
     Answers the number of key/value pairs in this Hashtable.
public  StringtoString()
     Answers the string representation of this Hashtable.

Field Detail
DEFAULT_CAPACITY
final public static int DEFAULT_CAPACITY(Code)
The default capacity used when not specified in the constructor.



elementCount
transient int elementCount(Code)



elementData
transient HashMapEntry[] elementData(Code)



firstSlot
transient int firstSlot(Code)



lastSlot
transient int lastSlot(Code)




Constructor Detail
CustomHashtable
public CustomHashtable()(Code)
Constructs a new Hashtable using the default capacity and load factor.



CustomHashtable
public CustomHashtable(int capacity)(Code)
Constructs a new Hashtable using the specified capacity and the default load factor.
Parameters:
  capacity - the initial capacity



CustomHashtable
public CustomHashtable(IElementComparer comparer)(Code)
Constructs a new hash table with the default capacity and the given element comparer.
Parameters:
  comparer - the element comparer to use to compare keys and obtainhash codes for keys, or null to use the normal equals and hashCode methods



CustomHashtable
public CustomHashtable(int capacity, IElementComparer comparer)(Code)
Constructs a new hash table with the given capacity and the given element comparer.
Parameters:
  capacity - the maximum number of elements that can be added withoutrehashing
Parameters:
  comparer - the element comparer to use to compare keys and obtainhash codes for keys, or null to use the normal equals and hashCode methods



CustomHashtable
public CustomHashtable(CustomHashtable table, IElementComparer comparer)(Code)
Constructs a new hash table with enough capacity to hold all keys in the given hash table, then adds all key/value pairs in the given hash table to the new one, using the given element comparer.
Parameters:
  table - the original hash table to copy from
Parameters:
  comparer - the element comparer to use to compare keys and obtainhash codes for keys, or null to use the normal equals and hashCode methods




Method Detail
containsKey
public boolean containsKey(Object key)(Code)
Answers if this Hashtable contains the specified object as a key of one of the key/value pairs.
Parameters:
  key - the object to look for as a key in this Hashtable true if object is a key in this Hashtable, false otherwise



elements
public Enumeration elements()(Code)
Answers an Enumeration on the values of this Hashtable. The results of the Enumeration may be affected if the contents of this Hashtable are modified. an Enumeration of the values of this Hashtable



get
public Object get(Object key)(Code)
Answers the value associated with the specified key in this Hashtable.
Parameters:
  key - the key of the value returned the value associated with the specified key, null if the specified keydoes not exist



getComparer
public IElementComparer getComparer()(Code)
Returns the element comparer used to compare keys and to obtain hash codes for keys, or null if no comparer has been provided. the element comparer or null
since:
   3.2



keys
public Enumeration keys()(Code)
Answers an Enumeration on the keys of this Hashtable. The results of the Enumeration may be affected if the contents of this Hashtable are modified. an Enumeration of the keys of this Hashtable



put
public Object put(Object key, Object value)(Code)
Associate the specified value with the specified key in this Hashtable. If the key already exists, the old value is replaced. The key and value cannot be null.
Parameters:
  key - the key to add
Parameters:
  value - the value to add the old value associated with the specified key, null if the key didnot exist



remove
public Object remove(Object key)(Code)
Remove the key/value pair with the specified key from this Hashtable.
Parameters:
  key - the key to remove the value associated with the specified key, null if the specified keydid not exist



size
public int size()(Code)
Answers the number of key/value pairs in this Hashtable. the number of key/value pairs in this Hashtable



toString
public String toString()(Code)
Answers the string representation of this Hashtable. the string representation of this Hashtable



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.