コード例 #1
0
        public CorsResourceSettings ForAllResources()
        {
            var settings = new CorsFluentSettings(this);

            settings.SetResources(null);
            return(new CorsResourceSettings(settings));
        }
コード例 #2
0
        public CorsFluentSettings ForAllOrigins()
        {
            var settings = new CorsFluentSettings(this);

            settings.SetResources(null);
            settings.SetOrigins(null);
            return(settings);
        }
コード例 #3
0
        public CorsResourceSettings ForResources(params string[] resources)
        {
            if (resources == null || resources.Length == 0)
            {
                throw new ArgumentException("Resources is null or empty.");
            }
            var settings = new CorsFluentSettings(this);

            settings.SetResources(resources);
            return(new CorsResourceSettings(settings));
        }
コード例 #4
0
        public CorsFluentSettings ForOrigins(params string[] origins)
        {
            if (origins == null || origins.Length == 0)
            {
                throw new ArgumentException("origins is null or empty.");
            }
            var settings = new CorsFluentSettings(this);

            settings.SetResources(null);
            settings.SetOrigins(origins);
            return(settings);
        }
コード例 #5
0
 public CorsFluentSettings ForAllOrigins()
 {
     var settings = new CorsFluentSettings(this);
     settings.SetResources(null);
     settings.SetOrigins(null);
     return settings;
 }
コード例 #6
0
 public CorsFluentSettings ForOrigins(params string[] origins)
 {
     if (origins == null || origins.Length == 0)
     {
         throw new ArgumentException("origins is null or empty.");
     }
     var settings = new CorsFluentSettings(this);
     settings.SetResources(null);
     settings.SetOrigins(origins);
     return settings;
 }
コード例 #7
0
 public CorsResourceSettings ForAllResources()
 {
     var settings = new CorsFluentSettings(this);
     settings.SetResources(null);
     return new CorsResourceSettings(settings);
 }
コード例 #8
0
 public CorsResourceSettings ForResources(params string[] resources)
 {
     if (resources == null || resources.Length == 0)
     {
         throw new ArgumentException("Resources is null or empty.");
     }
     var settings = new CorsFluentSettings(this);
     settings.SetResources(resources);
     return new CorsResourceSettings(settings);
 }
コード例 #9
0
 internal CorsResourceSettings(CorsFluentSettings settings)
 {
     this.settings = settings;
 }
コード例 #10
0
 internal CorsResourceSettings(CorsFluentSettings settings)
 {
     this.settings = settings;
 }