package Ġcom . we alth front . mage ll an . navigation Ċ Ċ import Ġandroid . util . Log Ċ import Ġcom . we alth front . mage ll an . init . should Log Debug Info Ċ import Ġjavax . inject . Inject Ċ import Ġjavax . inject . Singleton Ċ Ċ @ Singleton Ċ public Ġclass ĠLogging Navig able Listener Ġ@ Inject Ġconstructor ( private Ġval Ġnavigation Tra verser : ĠNavigation Tra verser ) Ġ: ĠNavig able Listener Ġ{ ĊĊĠ Ġoverride Ġfun Ġon Navig able Shown ( navig able : ĠNavig able Compat ) Ġ{ ĊĠĠĠ Ġif Ġ( should Log Debug Info ()) Ġ{ ĊĠĠĠĠĠ ĠLog . d ( this :: class . java . simple Name , Ġ" Shown : Ġ${ navig able . java Class . simple Name }") ĊĠĠĠ Ġ} ĊĠ Ġ} ĊĊĠ Ġoverride Ġfun Ġon Navig able Hidden ( navig able : ĠNavig able Compat ) Ġ{ ĊĠĠĠ Ġif Ġ( should Log Debug Info ()) Ġ{ ĊĠĠĠĠĠ ĠLog . d ( this :: class . java . simple Name , Ġ" Hidden : Ġ${ navig able . java Class . simple Name }") ĊĠĠĠ Ġ} ĊĠ Ġ} ĊĊĠ Ġoverride Ġfun Ġafter Navigation () Ġ{ ĊĠĠĠ Ġnavigation Tra verser . log Global Back Stack () ĊĠ Ġ} Ċ } Ċ