Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8705017
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T03:15:00+00:00 2026-06-13T03:15:00+00:00

The question arises from the way I have created a file explorer functionality for

  • 0

The question arises from the way I have created a file explorer functionality for an application (my first).

Can some of you please help me know which of the following below mentioned approaches is better vis-à-vis performance.

Case I – There is an approach which advises to override the getView() method. Like the one given here.

Case II – I used a different one where I have a custom method (not getView) in my adapter class with

  1. HashMap for each row of the listview.
  2. ArrayList> which holds each of the HashMaps from (a)
  3. SimpleAdapter(Context , List> , int , String[] , int[])

(I must say I have to do extra iterations to sort the list folder/file wise and then alphabetically within folders and files. I went the long way sorting, did not use comparator)

My code is close to as given here

Case III* OR, is there any thing better than the above two approaches?

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T03:15:02+00:00Added an answer on June 13, 2026 at 3:15 am

    Personally I would create my own adapter and override the getView method. The reason is that you will get much better flexibility and control over what you can do with the class. For instance, if you change your data structures that you back the data with it will be easy to handle. You could eventually want to do some sort of algorithm where you rely on caching the contents of a folder for a period of time and doing so will be more difficult with a SimpleAdapter.
    A SimpleAdapter saves you a few lines of code that you’d need to write in getView but overall I don’t think it’s going to really help you that much. There are certain things that you should make sure to do though to make your listview fast, such as using viewholders.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

The question arises from the reply . How can I change the storing from
We need to translate some of our UI to English, and the question arises:
Question in title pretty much sums it up. I have some resource object defined
Here's the question first: Is this possible? I'm taking my inspiration from Joe Wrobel's
The question arises from the need to reuse a code for different types of
This question arises from this question . One saying is that if a language
A question arised when I was programming a recursive function in Haskell; Can any
I have a question which is described below: What problems would arise for testing
G'day, Edit: While this question covers a situation that can arise in programming a
Question context: let say that there is some really important row in config/locales/en.yml that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.