문제

I am really apologize. If its very basic thing in Android.

I am creating a Fragment for an Activity class and the same fragment i want to use in another activity. Is it possible to use same fragment class in different activity classes. Thanks for considering. Any kind of help will be really appreciated.

도움이 되었습니까?

해결책

Yes, that's possible. It's one of the strengths of the Fragment pattern. I'd just like to point out you can only use the same Fragment class - not the same Fragment instance.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top