Read file contents in j2me

安稳与你 提交于 2019-12-09 20:07:58

问题


I Have a file like shown below,

OrderNo   id          name        count   Format
1         AA1       sdflsdfsdfd     12      01
2         AB2       asdaewqrftr     13      02
3         AA3       aerefytrsu      12      01

I want to read this file and want to sort with orderNo. Please suggest me some way to read and sort.(in J2ME). Thanks...


回答1:


  • Create an object representing this
  • Read the file line by line ('\n' new line )
  • Sort them in memory and write them back.

Note:

  • Be careful about memory


来源:https://stackoverflow.com/questions/6069879/read-file-contents-in-j2me

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