Back to project page favouritetv.
The source code is released under:
Copyright (c) 2011 Andr? Prata<andreprata@ua.pt> Eriksson Monteiro<eriksson.monteiro@ua.pt> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associat...
If you think the Android project favouritetv listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package pt.ua.code.favouritetv.gui; //from w w w . ja va 2s . c om import pt.ua.code.favouritetv.R; import android.view.View; import android.widget.ImageView; import android.widget.RatingBar; import android.widget.TextView; public class ViewCache { private View baseView; private TextView textView; private ImageView imageView; private RatingBar rating; public ViewCache(View baseView) { this.baseView = baseView; } public TextView getTextView() { if (textView == null) { textView = (TextView) baseView.findViewById(R.id.idTextView); } return textView; } public ImageView getImageView() { if (imageView == null) { imageView = (ImageView) baseView.findViewById(R.id.idImageView); } return imageView; } public RatingBar getRating() { if (rating == null) { rating = (RatingBar) baseView.findViewById(R.id.ratingfavourite); } return rating; } public View getBaseView() { return baseView; } }