Class: Azure::Storage::Mgmt::V2019_04_01::Models::CorsRule
- Inherits:
-
Object
- Object
- Azure::Storage::Mgmt::V2019_04_01::Models::CorsRule
- Includes:
- MsRestAzure
- Defined in:
- lib/2019-04-01/generated/azure_mgmt_storage/models/cors_rule.rb
Overview
Specifies a CORS rule for the Blob service.
Instance Attribute Summary collapse
-
#allowed_headers ⇒ Array<String>
of headers allowed to be part of the cross-origin request.
-
#allowed_methods ⇒ Array<Enum>
of HTTP methods that are allowed to be executed by the origin.
-
#allowed_origins ⇒ Array<String>
of origin domains that will be allowed via CORS, or “*” to allow all domains.
-
#exposed_headers ⇒ Array<String>
of response headers to expose to CORS clients.
-
#max_age_in_seconds ⇒ Integer
of seconds that the client/browser should cache a preflight response.
Class Method Summary collapse
-
.mapper ⇒ Object
Mapper for CorsRule class as Ruby Hash.
Instance Attribute Details
#allowed_headers ⇒ Array<String>
of headers allowed to be part of the cross-origin request.
34 35 36 |
# File 'lib/2019-04-01/generated/azure_mgmt_storage/models/cors_rule.rb', line 34 def allowed_headers @allowed_headers end |
#allowed_methods ⇒ Array<Enum>
of HTTP methods that are allowed to be executed by the origin.
22 23 24 |
# File 'lib/2019-04-01/generated/azure_mgmt_storage/models/cors_rule.rb', line 22 def allowed_methods @allowed_methods end |
#allowed_origins ⇒ Array<String>
of origin domains that will be allowed via CORS, or “*” to allow all domains
18 19 20 |
# File 'lib/2019-04-01/generated/azure_mgmt_storage/models/cors_rule.rb', line 18 def allowed_origins @allowed_origins end |
#exposed_headers ⇒ Array<String>
of response headers to expose to CORS clients.
30 31 32 |
# File 'lib/2019-04-01/generated/azure_mgmt_storage/models/cors_rule.rb', line 30 def exposed_headers @exposed_headers end |
#max_age_in_seconds ⇒ Integer
of seconds that the client/browser should cache a preflight response.
26 27 28 |
# File 'lib/2019-04-01/generated/azure_mgmt_storage/models/cors_rule.rb', line 26 def max_age_in_seconds @max_age_in_seconds end |
Class Method Details
.mapper ⇒ Object
Mapper for CorsRule class as Ruby Hash. This will be used for serialization/deserialization.
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 |
# File 'lib/2019-04-01/generated/azure_mgmt_storage/models/cors_rule.rb', line 41 def self.mapper() { client_side_validation: true, required: false, serialized_name: 'CorsRule', type: { name: 'Composite', class_name: 'CorsRule', model_properties: { allowed_origins: { client_side_validation: true, required: true, serialized_name: 'allowedOrigins', type: { name: 'Sequence', element: { client_side_validation: true, required: false, serialized_name: 'StringElementType', type: { name: 'String' } } } }, allowed_methods: { client_side_validation: true, required: true, serialized_name: 'allowedMethods', type: { name: 'Sequence', element: { client_side_validation: true, required: false, serialized_name: 'enumElementType', type: { name: 'String' } } } }, max_age_in_seconds: { client_side_validation: true, required: true, serialized_name: 'maxAgeInSeconds', type: { name: 'Number' } }, exposed_headers: { client_side_validation: true, required: true, serialized_name: 'exposedHeaders', type: { name: 'Sequence', element: { client_side_validation: true, required: false, serialized_name: 'StringElementType', type: { name: 'String' } } } }, allowed_headers: { client_side_validation: true, required: true, serialized_name: 'allowedHeaders', type: { name: 'Sequence', element: { client_side_validation: true, required: false, serialized_name: 'StringElementType', type: { name: 'String' } } } } } } } end |