public static IValidatableServiceCollection AddApiCoreAuthorizationServices(
            this IValidatableServiceCollection services)
        {
            services.AddTransient <IAuthorizationHandler, RegionPermissionAuthorizationHandler>();
            services.AddTransient <IAuthorizationHandler, EventPermissionAuthorizationHandler>();
            services.AddTransient <IAuthorizationHandler, RegionOperationAuthorizationHandler>();
            services.AddTransient <IAuthorizationHandler, RegionRoleAuthorizationHandler>();
            services.AddTransient <IRegionPermissionResolver, RegionPermissionResolver>();
            services.AddTransient <IEventPermissionResolver, EventPermissionResolver>();

            services.AddRequirement <IAuthorizationService>();
            services.AddRequirement <IRegionRolesAccessor>();

            return(services);
        }
 public static void AddRequirement <TService>(this IValidatableServiceCollection services)
 {
     services.AddRequirement(typeof(TService));
 }