Hi
I have been reading the latest JDC tech tip newsletter and i came across the following line:
Set sethash = new Hashset();
I'm assuming an object of class Set implements the Hashset interface but why not use
Set sethash = new Set();
Instead? What are the advantages (if any ) are there in creating a reference to an object in this way? I've seen this quite often but could never understand why its done.
I've always wondered about this.
Thanks
Kola
I have been reading the latest JDC tech tip newsletter and i came across the following line:
Set sethash = new Hashset();
I'm assuming an object of class Set implements the Hashset interface but why not use
Set sethash = new Set();
Instead? What are the advantages (if any ) are there in creating a reference to an object in this way? I've seen this quite often but could never understand why its done.
I've always wondered about this.
Thanks
Kola