class StepVisitor implements PageVisitor {

    @Override
    public void visit(final AllScenariosPageCollection allScenariosPageCollection) throws CluecumberPluginException {
        AllStepsPageCollection allStepsPageCollection = new AllStepsPageCollection(
                allScenariosPageCollection.getReports(), propertyManager.getCustomPageTitle()
        );

        // All steps page
        fileIO.writeContentToFile(
                allStepsPageRenderer.getRenderedContent(
                        allStepsPageCollection,
                        templateEngine.getTemplate(ALL_STEPS)
                ),
                propertyManager.getGeneratedHtmlReportDirectory() + "/" + PluginSettings.PAGES_DIRECTORY + "/" +
                        PluginSettings.STEP_SUMMARY_PAGE_PATH + PluginSettings.HTML_FILE_EXTENSION);

        // Scenarios by step pages
        for (Step step : allStepsPageCollection.getSteps()) {
            fileIO.writeContentToFile(
                    allScenariosPageRenderer.getRenderedContentByStepFilter(
                            allScenariosPageCollection, templateEngine.getTemplate(ALL_SCENARIOS), step),
                    propertyManager.getGeneratedHtmlReportDirectory() + "/" +
                            PluginSettings.PAGES_DIRECTORY + PluginSettings.STEP_SCENARIO_PAGE_FRAGMENT +
                            step.getUrlFriendlyName() + PluginSettings.HTML_FILE_EXTENSION);
        }
    }

    @Inject public  StepVisitor(
            final FileIO fileIO,
            final TemplateEngine templateEngine,
            final PropertyManager propertyManager,
            final AllStepsPageRenderer allStepsPageRenderer,
            final AllScenariosPageRenderer allScenariosPageRenderer
    );

}