获取哈希码 [英] getting the hash code

查看:212
本文介绍了获取哈希码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我的问题是我正在显示包含月份的jsp页面作为下拉按钮,在那里我可以选择月份并单击搜索.结果页面应显示特定选定月份数据的饼图和条形图.在所有月份中,它都使用相同的哈希码,因此无论我选择什么,条形图和饼图在所有月份中都保持不变.

谁能帮帮我.提前感谢

Hi,

My problem is i am dispplaying the jsp page which contains the month as drop down button there i can select the month and click on search.The resulting page should display the pie chart and bar chart for the particular selected month data.Here the problem is it is taking the same hash code for all the months so the bar chart and pie chart remains same for all the months whatever i selected.

Can any one help me.Thanks in advance

推荐答案

猜想您有一个对象,然后根据哈希码搜索图像.
您必须确保使用与其他对象相同的哈希码存储图像.如果您不覆盖哈希码,那么它将是堆中的内存地址,每个实例都不同.
As a guess you have an object and you search for an image based on the hash code.
You must make sure that the image is stored with the same hash code as the other object. If you are not overriding the hash code then it will be the memory address in the heap, different for EVERY instance.


这篇关于获取哈希码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆