uk.co.ribot.easyadapter
Class ActivityViewHolder

java.lang.Object
  extended by uk.co.ribot.easyadapter.ActivityViewHolder

public abstract class ActivityViewHolder
extends Object

Extend this class if you want to hold the views of an Activity. Annotate the view fields with ViewId i.e @ViewId(R.id.textView1). It will look for the viewId's in the Activity's layout and assign the views to the annotated fields of the subclass.

You must call android.app.Activity#setContentView(int) in the Activity before instantiating any subclass of ActivityViewHolder.


Constructor Summary
ActivityViewHolder(Activity activity)
          Constructs a ActivityViewHolder using an activity
 
Method Summary
 Activity getActivity()
          Gets the activity that was used to construct this ActivityViewHolder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ActivityViewHolder

public ActivityViewHolder(Activity activity)
Constructs a ActivityViewHolder using an activity

Parameters:
activity - the Activity where the held views reside
Method Detail

getActivity

public Activity getActivity()
Gets the activity that was used to construct this ActivityViewHolder

Returns:
the Activity that was set with #ActivityViewHolder(android.app.Activity)