Class DomainViewHolder


  • public class DomainViewHolder
    extends androidx.recyclerview.widget.RecyclerView.ViewHolder
    The View Holder for the list of domains Contains all the views to be displayed on each list item
    • Field Summary

      Fields 
      Modifier and Type Field Description
      android.widget.ImageView mImageView  
      SDKCheckedTextView mName  
      • Fields inherited from class androidx.recyclerview.widget.RecyclerView.ViewHolder

        itemView
    • Constructor Summary

      Constructors 
      Constructor Description
      DomainViewHolder​(android.view.View itemView)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void bind​(java.lang.String domainName, boolean isSelected, boolean isUserAdded)
      Bind data on this views using passed values
      void setPlaceHolder​(int placeHolder)
      Set the placeholder resource in the avatar view
      void showImage​(java.lang.String preferenceImageUrl)
      Update the image based on the given url passed
      • 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

      • mImageView

        public android.widget.ImageView mImageView
    • Constructor Detail

      • DomainViewHolder

        public DomainViewHolder​(android.view.View itemView)
    • Method Detail

      • bind

        public void bind​(java.lang.String domainName,
                         boolean isSelected,
                         boolean isUserAdded)
        Bind data on this views using passed values
        Parameters:
        domainName - name of the domain
        isSelected - true if checked, else false
        isUserAdded - true if user us added, else false
      • showImage

        public void showImage​(java.lang.String preferenceImageUrl)
        Update the image based on the given url passed
        Parameters:
        preferenceImageUrl - url to use in the image
      • setPlaceHolder

        public void setPlaceHolder​(@DrawableRes
                                   int placeHolder)
        Set the placeholder resource in the avatar view
        Parameters:
        placeHolder - DrawableRes id of the place holder resource