Exemplo n.º 1
0
        public Startup(IConfiguration configuration)
        {
            Configuration = configuration;

            var attributes = Assembly.GetExecutingAssembly().CustomAttributes;

            _swaggerDocVersion = ReflectionHelper.AttributeReader <AssemblyVersionAttribute>(attributes)
                                 ?? ReflectionHelper.AttributeReader <AssemblyFileVersionAttribute>(attributes);
            _swaggerDocTitle       = ReflectionHelper.AttributeReader <AssemblyTitleAttribute>(attributes);
            _swaggerDocDescription = ReflectionHelper.AttributeReader <AssemblyDescriptionAttribute>(attributes);
            _swaggerDocCompany     = ReflectionHelper.AttributeReader <AssemblyCompanyAttribute>(attributes);
            _swaggerDocCopyright   = ReflectionHelper.AttributeReader <AssemblyCopyrightAttribute>(attributes);
        }