package Ġcom . bill board . movies . utils Ċ Ċ import Ġandroid . content . Context Ċ import Ġandroid . net . Connectivity Manager Ċ import Ġandroid . net . Network Info Ċ Ċ object ĠNetwork Utils Ġ{ ĊĠĠĠ Ġfun Ġis Network Connected ( context : ĠContext ): ĠBoolean Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġcm Ġ= Ġcontext . getSystem Service ( Context . CONNECT IVITY _ SERVICE ) Ġas ĠConnect ivity Manager ĊĠĠĠĠĠĠĠ Ġvar Ġactive Network : ĠNetwork Info ? Ġ= Ġnull ĊĠĠĠĠĠĠĠ Ġactive Network Ġ= Ġcm . active Network Info ĊĠĠĠĠĠĠĠ Ġreturn Ġactive Network Ġ!= Ġnull Ġ&& Ġactive Network . isConnected Or Connecting ĊĠĠĠ Ġ} Ċ } Ċ