Class: MicrosoftGraph::Models::CountryNamedLocation
- Inherits:
-
NamedLocation
- Object
- Entity
- NamedLocation
- MicrosoftGraph::Models::CountryNamedLocation
- Includes:
- MicrosoftKiotaAbstractions::Parsable
- Defined in:
- lib/models/country_named_location.rb
Class Method Summary collapse
-
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value.
Instance Method Summary collapse
-
#countries_and_regions ⇒ Object
Gets the countriesAndRegions property value.
-
#countries_and_regions=(value) ⇒ Object
Sets the countriesAndRegions property value.
-
#country_lookup_method ⇒ Object
Gets the countryLookupMethod property value.
-
#country_lookup_method=(value) ⇒ Object
Sets the countryLookupMethod property value.
-
#get_field_deserializers ⇒ Object
The deserialization information for the current model.
-
#include_unknown_countries_and_regions ⇒ Object
Gets the includeUnknownCountriesAndRegions property value.
-
#include_unknown_countries_and_regions=(value) ⇒ Object
Sets the includeUnknownCountriesAndRegions property value.
-
#initialize ⇒ Object
constructor
Instantiates a new countryNamedLocation and sets the default values.
-
#serialize(writer) ⇒ Object
Serializes information the current object.
Methods inherited from NamedLocation
#created_date_time, #created_date_time=, #display_name, #display_name=, #modified_date_time, #modified_date_time=
Methods inherited from Entity
#additional_data, #additional_data=, #id, #id=, #odata_type, #odata_type=
Constructor Details
#initialize ⇒ Object
Instantiates a new countryNamedLocation and sets the default values.
22 23 24 |
# File 'lib/models/country_named_location.rb', line 22 def initialize() super end |
Class Method Details
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value
60 61 62 63 |
# File 'lib/models/country_named_location.rb', line 60 def self.create_from_discriminator_value(parse_node) raise StandardError, 'parse_node cannot be null' if parse_node.nil? return CountryNamedLocation.new end |
Instance Method Details
#countries_and_regions ⇒ Object
Gets the countriesAndRegions property value. List of countries and/or regions in two-letter format specified by ISO 3166-2. Required.
29 30 31 |
# File 'lib/models/country_named_location.rb', line 29 def countries_and_regions return @countries_and_regions end |
#countries_and_regions=(value) ⇒ Object
Sets the countriesAndRegions property value. List of countries and/or regions in two-letter format specified by ISO 3166-2. Required.
37 38 39 |
# File 'lib/models/country_named_location.rb', line 37 def countries_and_regions=(value) @countries_and_regions = value end |
#country_lookup_method ⇒ Object
Gets the countryLookupMethod property value. Determines what method is used to decide which country the user is located in. Possible values are clientIpAddress(default) and authenticatorAppGps. Note: authenticatorAppGps is not yet supported in the Microsoft Cloud for US Government.
44 45 46 |
# File 'lib/models/country_named_location.rb', line 44 def country_lookup_method return @country_lookup_method end |
#country_lookup_method=(value) ⇒ Object
Sets the countryLookupMethod property value. Determines what method is used to decide which country the user is located in. Possible values are clientIpAddress(default) and authenticatorAppGps. Note: authenticatorAppGps is not yet supported in the Microsoft Cloud for US Government.
52 53 54 |
# File 'lib/models/country_named_location.rb', line 52 def country_lookup_method=(value) @country_lookup_method = value end |
#get_field_deserializers ⇒ Object
The deserialization information for the current model
68 69 70 71 72 73 74 |
# File 'lib/models/country_named_location.rb', line 68 def get_field_deserializers() return super.merge({ "countriesAndRegions" => lambda {|n| @countries_and_regions = n.get_collection_of_primitive_values(String) }, "countryLookupMethod" => lambda {|n| @country_lookup_method = n.get_enum_value(MicrosoftGraph::Models::CountryLookupMethodType) }, "includeUnknownCountriesAndRegions" => lambda {|n| @include_unknown_countries_and_regions = n.get_boolean_value() }, }) end |
#include_unknown_countries_and_regions ⇒ Object
Gets the includeUnknownCountriesAndRegions property value. true if IP addresses that don’t map to a country or region should be included in the named location. Optional. Default value is false.
79 80 81 |
# File 'lib/models/country_named_location.rb', line 79 def include_unknown_countries_and_regions return @include_unknown_countries_and_regions end |
#include_unknown_countries_and_regions=(value) ⇒ Object
Sets the includeUnknownCountriesAndRegions property value. true if IP addresses that don’t map to a country or region should be included in the named location. Optional. Default value is false.
87 88 89 |
# File 'lib/models/country_named_location.rb', line 87 def include_unknown_countries_and_regions=(value) @include_unknown_countries_and_regions = value end |
#serialize(writer) ⇒ Object
Serializes information the current object
95 96 97 98 99 100 101 |
# File 'lib/models/country_named_location.rb', line 95 def serialize(writer) raise StandardError, 'writer cannot be null' if writer.nil? super writer.write_collection_of_primitive_values("countriesAndRegions", @countries_and_regions) writer.write_enum_value("countryLookupMethod", @country_lookup_method) writer.write_boolean_value("includeUnknownCountriesAndRegions", @include_unknown_countries_and_regions) end |