开发者

Will the "generified" version of JTree (TreeModel, TreeNode, ...) be in JDK7?

I found out recently that JList (finally!) was "generified" in JDK7.

Why JTree and related classes/interfaces 开发者_开发知识库are not changed the same?

It would be a huge improvement. Casting Object is going on one's nerves.

NOTE: The javadoc had not yet been updated, see here and here.


There was someone making proposals on the swing-dev mailing list. I don't think it is complete yet.

My understanding of why it hasn't been generified yet is:

  • The API does not fit generics very well (exposing implementation and arrays, for instance).
  • Across GUI code, generification brings surprisingly little benefit considered.
  • Engineers at Oracle have more business-relevant priorities.
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜