package Ġcom . co dy lab . food ie . core . extension Ċ Ċ import Ġandroid . Manifest Ċ import Ġandroid . content . Context Ċ import Ġandroid . support . v 4 . app . Fragment Activity Ċ import Ġandroid . widget . Toast Ċ import Ġcom . t br uy elle . rx permissions 2 . Rx Permissions Ċ import Ġio . reactivex . Observable Ċ Ċ fun ĠFragment Activity . request Permission ( permission : ĠString ): ĠObservable < Boolean > Ġ{ ĊĠĠĠ Ġreturn ĠRx Permissions ( this ). request ( permission ) Ċ } Ċ Ċ fun ĠFragment Activity . request Location Permission (): ĠObservable < Boolean > Ġ{ ĊĠĠĠ Ġreturn Ġthis . request Permission ( Manifest . permission . ACCESS _ F INE _ LOCATION ) Ċ } Ċ Ċ fun ĠContext . show Toast ( message : ĠString ) Ġ{ ĊĠĠĠ ĠToast . makeText ( this , Ġmessage , ĠToast . LENGTH _ SHORT ). show () Ċ } Ċ Ċ fun ĠContext . show Error ( throwable : ĠThrowable ) Ġ{ ĊĠĠĠ ĠToast . makeText ( this , Ġthrowable . toString (), ĠToast . LENGTH _ LONG ). show () Ċ } Ċ Ċ fun ĠContext . show Error ( message : ĠString ) Ġ{ ĊĠĠĠ ĠToast . makeText ( this , Ġmessage , ĠToast . LENGTH _ LONG ). show () Ċ } Ċ