Class RecipeAdapter.ViewHolder

  • Enclosing class:
    RecipeAdapter

    public static class RecipeAdapter.ViewHolder
    extends androidx.recyclerview.widget.RecyclerView.ViewHolder
    Holds the views for the recipes
    • Field Summary

      Fields 
      Modifier and Type Field Description
      android.widget.TextView category  
      android.widget.TextView description  
      android.widget.TextView prepTime  
      android.widget.ImageView recipeImg  
      android.widget.TextView recipeTitleTextView  
      android.widget.TextView servings  
      android.view.View view  
      • Fields inherited from class androidx.recyclerview.widget.RecyclerView.ViewHolder

        itemView
    • Constructor Summary

      Constructors 
      Constructor Description
      ViewHolder​(android.view.View itemView)
      Creates a new ViewHolder
    • Method Summary

      • Methods inherited from class androidx.recyclerview.widget.RecyclerView.ViewHolder

        getAdapterPosition, getItemId, getItemViewType, getLayoutPosition, getOldPosition, getPosition, isRecyclable, setIsRecyclable, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • recipeTitleTextView

        public android.widget.TextView recipeTitleTextView
      • prepTime

        public android.widget.TextView prepTime
      • description

        public android.widget.TextView description
      • category

        public android.widget.TextView category
      • servings

        public android.widget.TextView servings
      • recipeImg

        public android.widget.ImageView recipeImg
      • view

        public android.view.View view
    • Constructor Detail

      • ViewHolder

        public ViewHolder​(@NonNull
                          android.view.View itemView)
        Creates a new ViewHolder
        Parameters:
        itemView - the view to be used for each item in the ViewHolder