Calling category methods

I’ve import Kingfisher Swift POD which adds a custom category into UIImageView, so the Swift code is like this:

let url = URL(string: "url_of_your_image")
imageView.kf.setImage(with: url)

After generating bindings I’ve got UIImageViewExt.java (see .nbc attached), but I’m puzzled how to call setImageWithUrl from my Java code.

Also the Nat/J docs says that there should be a @CategoryClassMethod annotation, but generating bindings doesn’t have that.

Could you please advise what am I missing and how to make those custom categories work?

Kingfisher.nbc (411 Bytes)

Could you solve this? Thanks.

No, I removed dependency on Kingfisher

It is available as a static method of UIImageViewExt:

UIImageViewExt.sd_setImageWithURL(imageView, url);

1 Like