Android - getTargetFragment and setTargetFragment - What are they used for

前端 未结 3 420
夕颜
夕颜 2020-11-29 06:06

I tried searching but i\'m still a little lost. I usually do fragment to fragment communication through an Activity via interfaces or a BroadcastReceiver

3条回答
  •  无人及你
    2020-11-29 06:21

    From what I was able to take away from reading the docs was that these methods are another way of accessing data from another Fragment. Here is a sample project that I wrote that demonstrates a single use case for using these methods. I'm sure there are more use cases though...

提交回复
热议问题