Public View GetView (int position, View Convertview, final viewgroup parent) three parameters meaning

Source: Internet
Author: User

Recently saw someone asked the meaning of these three parameters, in fact, help has been very detailed introduction of these three parameters, it seems to be good to learn English, or even explain can not understand.

 /**
* Get A View that displays the data on the specified position in the data set. You can either
* Create a View manually or inflate it from an XML layout file. When the View is inflated, the
* Parent View (GridView, ListView ...) would apply default layout parameters unless you use
* {@link android.view.layoutinflater#inflate (int, Android.view.ViewGroup, Boolean)}
* To specify a root view and to prevent attachment to the root.
     * 
* @param position the position of the item within the adapter ' s data set of the item whose view
* we want.
* @param convertview The old view to reuse, if possible. Note:you should check that the This view
* is non-null and of an appropriate type before using. If It isn't possible to convert
* This method can create a new view of the correct data, which is view to display.
* @param parent The parent that this view would eventually be attached to
* @return A View corresponding to the data at the specified position.
     */

Public View GetView (int position, View Convertview, final viewgroup parent) three parameters meaning

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.