按字母顺序对多个ArrayList排序 [英] Sorting Multiple ArrayLists Alphabetically

查看:70
本文介绍了按字母顺序对多个ArrayList排序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨!

我有三个字符串数组列表,而"091:"字符串的一部分不在arraylist中,而是在列表框中显示它们时添加的.

I've got three arraylists of strings, and the "091: " part of the string is not part in the arraylist, thats added when I display them in the listboxes.

因此,基本上,我如何才能对列表进行排序,并确保英语中的nr 98项仍然等于日语和汉字中的nr 98?

So basically, how can I sort a list, and make sure that item nr 98 in english, still equals nr 98 in japanese and kanji?

推荐答案

Han,

对此我的第一反应是为什么不使用数据库?".

My first reaction to this is "why aren't you using a database?".

即使在内存中也可以做到(尽管您需要在保存数据方面进行思考),但是无论如何进行,这都是将所有内容保持在一起"的更好方法,尤其是一次您进行排序或过滤等.

Even an in-memory one would do (although you need to think in terms of saving the data), but no matter how you go about doing it, it's a better way to "keep everything together", and especially once you sort or filter, etc..

不是直接回答您的问题,但希望能引起大家的思考.

Not an answer to your question, directly, but hopefully food for thought.

祝您的项目好运. :)

Good luck with your project. :)


这篇关于按字母顺序对多个ArrayList排序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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