Hashtable. Name history. Why not HashTable?

时光怂恿深爱的人放手 提交于 2019-12-07 18:23:49

问题


we know:

ArrayList;
LinkedList;
TreeMap

and other... and all names in CamelCase format, but why Hashtable, not HashTable?

it is unprincipled question, just wondering :)


回答1:


Hashtable was created in Java v1. The consistent naming conventions for collections were established later, in Java2, when the other classes were published as part of the brand new Java Collection Framework.

Which btw made Hashtable obsolete, so it should not be used in new code.




回答2:


It's a typo. Same as Cloneable (should be Clonable). Or Referer (should be Referrer)



来源:https://stackoverflow.com/questions/3966983/hashtable-name-history-why-not-hashtable

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!