Question: I am new to springboot application development. I tried and was able to develop a simple springboot app to connect to a couchbase server and perform crud operations on its buckets. Now, my requirement is to not connect to an already created bucket in the couchbase server but to create a new bucket and store some documents in it through my spring boot app. I am using annotation based configuration to specify the connection configuration by extending AbstractCouchbase repository and implementing its methods.

Answer: 
it's so easy like define viewbinding in fragment or activity

```
class PlayersListAdapter(
    var items: ArrayList<MatchPlayer>
) :
    RecyclerView.Adapter<TeamPlayersListAdapter.MatchSubstitutionHolder>() {

    override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): MatchSubstitutionHolder {

        val binding= ItemTeamPlayerBinding.inflate(LayoutInflater.from(parent.context),parent,false)

        return MatchSubstitutionHolder(binding)
    }

    override fun onBindViewHolder(viewHolder: MatchSubstitutionHolder, position: Int) {

        viewHolder.binding.lblPlayerName.text = "name"

    }

    class MatchSubstitutionHolder(val binding: ItemTeamPlayerBinding) : RecyclerView.ViewHolder(binding.root)

    override fun getItemCount(): Int {
        return items.size

    }}

```
I think this is best for you

```
class PlayersListAdapter(var items: ArrayList<MatchPlayer>) :
    RecyclerView.Adapter<TeamPlayersListAdapter.MatchSubstitutionHolder>() {

    override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): MatchSubstitutionHolder {
        val binding = ItemTeamPlayerBinding.inflate(LayoutInflater.from(parent.context), parent, false)
        return MatchSubstitutionHolder(binding)
    }

    override fun getItemCount(): Int {
        return items.size
    }

    override fun onBindViewHolder(viewHolder: MatchSubstitutionHolder, position: Int) {
        viewHolder.bind(position)
    }

    class MatchSubstitutionHolder(val binding: ItemTeamPlayerBinding) : RecyclerView.ViewHolder(binding.root) {
        fun bind(position: Int) {
            val matchPlayer = items[position]
            binding.lblPlayerName.text = "name"
        }
    }
}

```