Class: AtlasEngine::AddressImporter::Validation::FieldValidations::City
- Inherits:
-
Object
- Object
- AtlasEngine::AddressImporter::Validation::FieldValidations::City
- Extended by:
- T::Helpers, T::Sig
- Includes:
- Interface
- Defined in:
- app/models/atlas_engine/address_importer/validation/field_validations/city.rb
Instance Method Summary collapse
-
#initialize(address:, allow_partial_zip: false) ⇒ City
constructor
A new instance of City.
- #validation_errors ⇒ Object
Constructor Details
#initialize(address:, allow_partial_zip: false) ⇒ City
Returns a new instance of City.
19 20 21 22 |
# File 'app/models/atlas_engine/address_importer/validation/field_validations/city.rb', line 19 def initialize(address:, allow_partial_zip: false) @city = address.city @errors = [] end |
Instance Method Details
#validation_errors ⇒ Object
25 26 27 28 29 |
# File 'app/models/atlas_engine/address_importer/validation/field_validations/city.rb', line 25 def validation_errors clear_errors validate errors end |