public PatcherLogDecorator( IProfileNameVm profileNameProvider, IPatcherNameVm patcherNameVm) { _logger = Observable.CombineLatest( profileNameProvider.WhenAnyValue(x => x.Name), patcherNameVm.WhenAnyValue(x => x.Name), (profile, patcher) => Log.Logger .ForContext(FunnelNames.Patcher, patcher) .ForContext(FunnelNames.Profile, profile)) .ToGuiProperty(this, nameof(Logger), Log.Logger .ForContext(FunnelNames.Patcher, patcherNameVm.Name) .ForContext(FunnelNames.Profile, profileNameProvider.Name), deferSubscription: true); }
public ProfileLogDecorator(IProfileNameVm nameProvider) { _logger = nameProvider.WhenAnyValue(x => x.Name) .Select(x => Log.Logger.ForContext(FunnelNames.Profile, x)) .ToGuiProperty(this, nameof(Logger), Log.Logger.ForContext(FunnelNames.Profile, nameProvider.Name), deferSubscription: true); }