How to create array of hash table with correct types
- From: jonbbbb <jon.berg@xxxxxxxxx>
- Date: Thu, 3 Jul 2008 16:38:21 -0700 (PDT)
Hi,
I want to create an array of 3 hash tables that has a string key and a
NodeAddress value.
I tried the following, which does not compile:
private Hashtable<String, NodeAddress>[] cache = {new
Hashtable<String, NodeAddress>(),new Hashtable<String,
NodeAddress>()};
private Hashtable<String, NodeAddress>[] cache = new Hashtable<String,
NodeAddress>()[3];
Any help on the syntax to get it to work would be great.
Thanks.
Jon.
.
- Follow-Ups:
- Re: How to create array of hash table with correct types
- From: Daniel Pitts
- Re: How to create array of hash table with correct types
- From: Roedy Green
- Re: How to create array of hash table with correct types
- Prev by Date: Re: display a TableModel as a JTable
- Next by Date: Re: How to create array of hash table with correct types
- Previous by thread: XML Modification
- Next by thread: Re: How to create array of hash table with correct types
- Index(es):
Relevant Pages
|