package Ġcom . to g gl . domain . loading Ċ Ċ import Ġcom . to g gl . common . feature . extensions . mutate Without Effects Ċ import Ġcom . to g gl . architecture . Dispatcher Provider Ċ import Ġcom . to g gl . architecture . core . Effect Ċ import Ġcom . to g gl . architecture . core . Reducer Ċ import Ġcom . to g gl . architecture . core . Mutable Value Ċ import Ġcom . to g gl . architecture . extensions . effects Ċ import Ġcom . to g gl . repository . interfaces . Client Repository Ċ import Ġcom . to g gl . repository . interfaces . Project Repository Ċ import Ġcom . to g gl . repository . interfaces . Tag Repository Ċ import Ġcom . to g gl . repository . interfaces . Task Repository Ċ import Ġcom . to g gl . repository . interfaces . Time Entry Repository Ċ import Ġcom . to g gl . repository . interfaces . Workspace Repository Ċ import Ġjavax . inject . Inject Ċ import Ġjavax . inject . Singleton Ċ Ċ @ Singleton Ċ class ĠLoading Reducer Ġ@ Inject Ġconstructor ( ĊĠĠĠ Ġprivate Ġval Ġproject Repository : ĠProject Repository , ĊĠĠĠ Ġprivate Ġval Ġclient Repository : ĠClient Repository , ĊĠĠĠ Ġprivate Ġval Ġtime Entry Repository : ĠTime Entry Repository , ĊĠĠĠ Ġprivate Ġval Ġworkspace Repository : ĠWorkspace Repository , ĊĠĠĠ Ġprivate Ġval Ġtags Repository : ĠTag Repository , ĊĠĠĠ Ġprivate Ġval Ġtask Repository : ĠTask Repository , ĊĠĠĠ Ġprivate Ġval Ġdispatcher Provider : ĠDispatcher Provider Ċ ) Ġ: ĠRed ucer < Loading State , ĠLoading Action > Ġ{ ĊĊĠĠĠ Ġoverride Ġfun Ġreduce ( ĊĠĠĠĠĠĠĠ Ġstate : ĠMutable Value < Loading State >, ĊĠĠĠĠĠĠĠ Ġaction : ĠLoading Action ĊĠĠĠ Ġ): ĠList < Effect < Loading Action >> Ġ= ĊĠĠĠĠĠĠĠ Ġwhen Ġ( action ) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ ĠLoading Action . Start Loading Ġ-> Ġeffects ( ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠLoad Work spaces Effect ( workspace Repository , Ġdispatcher Provider ), ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠLoad Projects Effect ( project Repository , Ġdispatcher Provider ), ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠLoad Clients Effect ( client Repository , Ġdispatcher Provider ), ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠLoad Tags Effect ( tags Repository , Ġdispatcher Provider ), ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠLoad Tasks Effect ( task Repository , Ġdispatcher Provider ), ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠLoad Time Entries Effect ( time Entry Repository , Ġdispatcher Provider ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠLoading Action . Time Entries Loaded Ġ-> Ġstate . mutate Without Effects Ġ{ Ġcopy ( time Entries Ġ= Ġaction . time Entries ) Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠLoading Action . Work spaces Loaded Ġ-> Ġstate . mutate Without Effects Ġ{ Ġcopy ( workspaces Ġ= Ġaction . workspaces ) Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠLoading Action . Projects Loaded Ġ-> Ġstate . mutate Without Effects Ġ{ Ġcopy ( projects Ġ= Ġaction . projects ) Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠLoading Action . Clients Loaded Ġ-> Ġstate . mutate Without Effects Ġ{ Ġcopy ( clients Ġ= Ġaction . clients ) Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠLoading Action . Tags Loaded Ġ-> Ġstate . mutate Without Effects Ġ{ Ġcopy ( tags Ġ= Ġaction . tags ) Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠLoading Action . Tasks Loaded Ġ-> Ġstate . mutate Without Effects Ġ{ Ġcopy ( tasks Ġ= Ġaction . tasks ) Ġ} ĊĠĠĠĠĠĠĠ Ġ} Ċ }