package Ġbr . com . dou glas ff il ho . spring kotlin crud . repository Ċ Ċ import Ġbr . com . dou glas ff il ho . spring kotlin crud . model . Customer Ċ import Ġorg . springframework . stereotype . Repository Ċ Ċ @ Repository Ċ class ĠCustomer Repository Ġ{ ĊĠĠĠ Ġprivate Ġval Ġcustomers : ĠList < Customer > Ġ= ĠlistOf ( ĊĠĠĠĠĠĠĠĠĠĠĠ ĠCustomer (" D ou glas ĠF ern an des ", Ġ" dou glas f . fil ho @ gmail . com ", Ġtrue ), ĊĠĠĠĠĠĠĠĠĠĠĠ ĠCustomer (" D ou glas ĠFil ho ", Ġ" dou glas ff il ho @ github . io ", Ġfalse ) ĊĠĠĠ Ġ) ĊĊĠĠĠ Ġfun ĠfindAll (): ĠList < Customer > Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġcustomers ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun ĠfindAll Active ( active : ĠBoolean ): ĠList < Customer > Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġcustomers . filter { Ġcustomer : ĠCustomer Ġ-> Ġcustomer . active Ġ== Ġactive Ġ} ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġfun ĠfindBy Email ( email : ĠString ): ĠCustomer ? Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġcustomers . find Ġ{ Ġcustomer : ĠCustomer Ġ-> Ġcustomer . email Ġ== Ġemail Ġ} ĊĠĠĠ Ġ} Ċ Ċ }