What is Contexts in Android ?. Application Context vs Activity Context

preview_player
Показать описание

# Application Context vs Activity Context.
# getContext() vs getApplicationContext.
# Singleton classes and Contexts.
# How to determine which context to use?.
Рекомендации по теме
Комментарии
Автор

Nice explanation thankyou so much 🙏🏼🙏🏼🙏🏼

someshsahu
Автор

i used getcontext to show ads in the current activity of the application (what ever activity it is) because get context will get the current activity and show what you want on it, i hope this help too

RetroBoxesShop
Автор

I always use Toast in Application Context. Is there a downside to that?

jeffluo