private Task DocumentConfiguration(IOwinContext context)
        {
            var document = GetResource("configuration.html");

            document = document.Replace("{path}", _configuration.Path);
            document = document.Replace("{enabled}", _configuration.Enabled.ToString());
            document = document.Replace("{requiredPermission}", _configuration.RequiredPermission ?? "<none>");
            document = document.Replace("{defaultFormat}", _configuration.DefaultFormat);

            var defaultConfiguration = new AnalysisReporterConfiguration();

            document = document.Replace("{path.default}", defaultConfiguration.Path);
            document = document.Replace("{enabled.default}", defaultConfiguration.Enabled.ToString());
            document = document.Replace("{requiredPermission.default}", defaultConfiguration.RequiredPermission ?? "<none>");
            document = document.Replace("{defaultFormat.default}", defaultConfiguration.DefaultFormat);

            context.Response.ContentType = "text/html";
            return(context.Response.WriteAsync(document));
        }
 void IConfigurable.Configure(IConfiguration configuration, string path)
 {
     _traceFilter.ConfigureWith(configuration);
     _configurationRegistration      = configuration.Register(
         path, cfg => _configuration = cfg, new AnalysisReporterConfiguration());
 }