// ĠCopyright Ġ 2 0 0 0 - 2 0 2 1 ĠJetBrains Ġs . r . o . Ġand Ġcontributors . ĠUse Ġof Ġthis Ġsource Ġcode Ġis Ġgoverned Ġby Ġthe ĠApache Ġ 2 . 0 Ġlicense Ġthat Ġcan Ġbe Ġfound Ġin Ġthe ĠLICENSE Ġfile . Ċ Ċ package Ġorg . jetbrains . kotlin . idea . refactor ing . member Info Ċ Ċ import Ġcom . intellij . psi . Psi Member Ċ import Ġcom . intellij . refactor ing . class Members . Member Dependency Graph Ċ import Ġcom . intellij . refactor ing . class Members . Member Info Base Ċ import Ġcom . intellij . refactor ing . util . class Members . Interface Member Dependency Graph Ċ import Ġorg . jetbrains . kotlin . as Java . to Light Class Ċ import Ġorg . jetbrains . kotlin . as Java . un wrapped Ċ import Ġorg . jetbrains . kotlin . psi . Kt Class Or Object Ċ import Ġorg . jetbrains . kotlin . psi . Kt Named Declaration Ċ Ċ class ĠKotlin Interface Member Dependency Graph < T Ġ: ĠK t Named Declaration , ĠM Ġ: ĠMember Info Base < T >>( ĊĠĠĠ Ġklass : ĠK t Class Or Object Ċ ) Ġ: ĠMember Dependency Graph < T , ĠM > Ġ{ ĊĠĠĠ Ġprivate Ġval Ġdelegate Graph Ġ= ĠInterface Member Dependency Graph < Psi Member , ĠMember Info Base < Psi Member >>( klass . to Light Class ()) ĊĊĠĠĠ Ġoverride Ġfun Ġmember Changed ( member Info : ĠM ) Ġ{ ĊĠĠĠĠĠĠĠ Ġdelegate Graph . member Changed ( member Info . to Java Member Info () Ġ?: Ġreturn ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Suppress (" UN CHECK ED _ CAST ") ĊĠĠĠ Ġoverride Ġfun Ġget Dependent () Ġ= Ġdelegate Graph . dependent ĊĠĠĠĠĠĠĠ Ġ. as Sequence () ĊĠĠĠĠĠĠĠ Ġ. map NotNull Ġ{ Ġit . un wrapped Ġ} ĊĠĠĠĠĠĠĠ Ġ. filter Is Instance To ( Linked HashSet < Kt Named Declaration >()) Ġas ĠSet < T > ĊĊĠĠĠ Ġ@ Suppress (" UN CHECK ED _ CAST ") ĊĠĠĠ Ġoverride Ġfun Ġget Dependencies Of ( member : ĠT ): ĠSet < T > Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġpsi Member Ġ= Ġlight Element For Member Info ( member ) Ġ?: Ġreturn Ġempty Set () ĊĠĠĠĠĠĠĠ Ġval Ġpsi Member Dependencies Ġ= Ġdelegate Graph . get Dependencies Of ( psi Member ) Ġ?: Ġreturn Ġempty Set () ĊĠĠĠĠĠĠĠ Ġreturn Ġpsi Member Dependencies ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. as Sequence () ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. map NotNull Ġ{ Ġit . un wrapped Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. filter Is Instance To ( Linked HashSet < Kt Named Declaration >()) Ġas ĠSet < T > ĊĠĠĠ Ġ} Ċ } Ċ