2019-11-08 21:00:59 +01:00
|
|
|
#ifndef ADDRESS_H
|
|
|
|
#define ADDRESS_H
|
|
|
|
|
|
|
|
#include <QString>
|
|
|
|
|
|
|
|
class Address
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
Address() {}
|
|
|
|
Address(const QString &street, const QString &city)
|
|
|
|
: _street(street), _city(city) {}
|
|
|
|
|
2021-05-12 21:58:46 +02:00
|
|
|
QString address() const;
|
2019-11-08 21:00:59 +01:00
|
|
|
|
|
|
|
void setStreet(const QString &street) {_street = street;}
|
|
|
|
void setCity(const QString &city) {_city = city;}
|
|
|
|
void setState(const QString &state) {_state = state;}
|
|
|
|
void setCountry(const QString &country) {_country = country;}
|
|
|
|
void setPostalCode(const QString &postalCode) {_postalCode = postalCode;}
|
|
|
|
|
2021-05-12 21:58:46 +02:00
|
|
|
bool isValid() const {return !_city.isEmpty();}
|
2019-11-08 21:00:59 +01:00
|
|
|
|
|
|
|
private:
|
|
|
|
QString _street;
|
|
|
|
QString _city;
|
|
|
|
QString _state;
|
|
|
|
QString _country;
|
|
|
|
QString _postalCode;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // ADDRESS_H
|