| Author |
How to create an array of arrayList
|
neha priya
Ranch Hand
Joined: Jul 03, 2010
Posts: 62
|
|
hello everyone,
i want to create an array of arrayList of type EventRow...i tried this
but it is giving the error
am unable to understand this error...please help me suggest me some way by which i can create an array of arrayList of type EventRow
thanks
|
 |
Campbell Ritchie
Sheriff
Joined: Oct 13, 2005
Posts: 32830
|
|
|
You can't. I think there is an explanation in the Java™ Tutorials, but I can't remember whether it is in this part or this part.
|
 |
akhter wahab
Ranch Hand
Joined: Mar 02, 2009
Posts: 151
|
|
list is dynamic you can't give its length.
|
Start Earning Online||Start Earning Using Java
|
 |
neha priya
Ranch Hand
Joined: Jul 03, 2010
Posts: 62
|
|
thanks for the replies...could you please suggest me some way through which i can have a substitute for array of arraylist of type EventRow?
thanks
|
 |
akhter wahab
Ranch Hand
Joined: Mar 02, 2009
Posts: 151
|
|
why you need substitute ?
|
 |
Prabhakar Reddy Bokka
Ranch Hand
Joined: Jul 26, 2005
Posts: 189
|
|
Java 5 does not permit the construction of generic arrays.
Go through the link below.
Generic arrays
|
SCJP 5, SCWCD 5
|
 |
neha priya
Ranch Hand
Joined: Jul 03, 2010
Posts: 62
|
|
@akhter wahab:thanks for replying..i need a substitute because my implementation demands that...
i am filtering out rows and putting them in an arraylist(say events)...now i am having a hashmap that is declared as
the Integer corresponds to 1st filter,2nd filter,3rd filter and List contains the corresponding filter rows..
so i needed to have an arraylist of type eventrow...i don't know if am able to explain my point clearly.
thanks
|
 |
akhter wahab
Ranch Hand
Joined: Mar 02, 2009
Posts: 151
|
|
|
read this will clear you alot webpage
|
 |
neha priya
Ranch Hand
Joined: Jul 03, 2010
Posts: 62
|
|
@akhter wahab:thanks for all your help...i somehow solved my problem without creating an array of arrayList
thanks
|
 |
 |
|
|
subject: How to create an array of arrayList
|
|
|