why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- From: www <www@xxxxxxxxxx>
- Date: Fri, 19 Oct 2007 15:10:48 -0400
Hi,
I saw in many places that people use:
Map m= new HashMap();
or
List l = new ArrayList();
I *rarely* see people do:
HashMap m= new HashMap();
or
ArrayList l = new ArrayList();
Is any specific reason for such a practice?
I noticed Map does not have clone(), but HashMap does.
.
- Follow-Ups:
- Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- From: www
- Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- From: Zig
- Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- From: Roedy Green
- Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- From: Wayne
- Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- From: Jim Korman
- Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- From: Mark Space
- Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- From: Richard Reynolds
- Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- Prev by Date: Struts call renders JSP, but doesn't execute Action class when doing this (short circuit)
- Next by Date: Re: Command-line arg
- Previous by thread: Struts call renders JSP, but doesn't execute Action class when doing this (short circuit)
- Next by thread: Re: why people use "Map m= new HashMap()" or "List l = new ArrayList()"?
- Index(es):
Relevant Pages
|