since this looks exactly like StepScope.Scopifier, might be a good candidate for refactoring