Cannot resolve method 'with' in 'Builder'

35 Views Asked by At

I want to implement native ads in my recyclerView with the help https://github.com/saitawngpha/NativeAds-RecyclerView but when i add

       AdmobNativeAdAdapter admobNativeAdAdapter=AdmobNativeAdAdapter.Builder
  .with(
      "ca-app-pub-3940256099942544/2247696110",//Create a native ad id from admob console
      myAdapter,//The adapter you would normally set to your recyClerView
      "medium"//Set it with "small","medium" or "custom"
      )
.adItemIterval(2)//native ad repeating interval in the recyclerview
.build();

recyclerView.setAdapter(admobNativeAdAdapter);//set your RecyclerView adapter with the admobNativeAdAdapter but i getting error No candidates found for method call AdmobNativeAdAdapter.Builder .with

0

There are 0 best solutions below