public Lens <TParent, TProperty> Compose <TParent>(Lens <TParent, TEntity> otherLens) { return(new Lens <TParent, TProperty>((pe, p) => otherLens.Set(pe, Set(otherLens.Get(pe), p)), pe => Get(otherLens.Get(pe)))); }
public Lens <TEntity, TChildProperty> AndThen <TChildProperty>(Lens <TProperty, TChildProperty> otherLens) { return(new Lens <TEntity, TChildProperty>((e, cpv) => Set(e, otherLens.Set(_accessor(e), cpv)), e => otherLens.Get(_accessor(e)))); }