aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Tango.DAL.Observables/Entities/Address.cs
blob: ad1786feda5954436a4e7976ada340668738783a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
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
<
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using Tango.DAL.Remote.DB;

namespace Tango.DAL.Observables
{
    [EntityFieldName("ADDRESSES")]
    public partial class Address : ObservableEntity<ADDRESS>
    {

        private String _addressstring;
        /// <summary>
        /// Gets or sets the address address string.
        /// </summary>
        [EntityFieldName("ADDRESS_STRING")]
        public String AddressString
        {
            get 
            {
                return _addressstring; 
            }

            set 
            {
                _addressstring = value; RaisePropertyChanged(nameof(AddressString)); 
            }

        }

        private String _locality;
        /// <summary>
        /// Gets or sets the address locality.
        /// </summary>
        [EntityFieldName("LOCALITY")]
        public String Locality
        {
            get 
            {
                return _locality; 
            }

            set 
            {
                _locality = value; RaisePropertyChanged(nameof(Locality)); 
            }

        }

        private String _country;
        /// <summary>
        /// Gets or sets the address country.
        /// </summary>
        [EntityFieldName("COUNTRY")]
        public String Country
        {
            get 
            {
                return _country; 
            }

            set 
            {
                _country = value; RaisePropertyChanged(nameof(Country)); 
            }

        }

        private String _city;
        /// <summary>
        /// Gets or sets the address city.
        /// </summary>
        [EntityFieldName("CITY")]
        public String City
        {
            get 
            {
                return _city; 
            }

            set 
            {
                _city = value; RaisePropertyChanged(nameof(City)); 
            }

        }

        private String _state;
        /// <summary>
        /// Gets or sets the address state.
        /// </summary>
        [EntityFieldName("STATE")]
        public String State
        {
            get 
            {
                return _state; 
            }

            set 
            {
                _state = value; RaisePropertyChanged(nameof(State)); 
            }

        }

        private String _countrycode;
        /// <summary>
        /// Gets or sets the address country code.
        /// </summary>
        [EntityFieldName("COUNTRY_CODE")]
        public String CountryCode
        {
            get 
            {
                return _countrycode; 
            }

            set 
            {
                _countrycode = value; RaisePropertyChanged(nameof(CountryCode)); 
            }

        }

        private String _postalcode;
        /// <summary>
        /// Gets or sets the address postal code.
        /// </summary>
        [EntityFieldName("POSTAL_CODE")]
        public String PostalCode
        {
            get 
            {
                return _postalcode; 
            }

            set 
            {
                _postalcode = value; RaisePropertyChanged(nameof(PostalCode)); 
            }

        }

        private ObservableCollection<Organization> _organizations;
        /// <summary>
        /// Gets or sets the address organizations.
        /// </summary>
        [EntityFieldName("ORGANIZATIONS")]
        public ObservableCollection<Organization> Organizations
        {
            get 
            {
                return _organizations; 
            }

            set 
            {
                _organizations = value; RaisePropertyChanged(nameof(Organizations)); 
            }

        }

        private ObservableCollection<User> _users;
        /// <summary>
        /// Gets or sets the address users.
        /// </summary>
        [EntityFieldName("USERS")]
        public ObservableCollection<User> Users
        {
            get 
            {
                return _users; 
            }

            set 
            {
                _users = value; RaisePropertyChanged(nameof(Users)); 
            }

        }

        /// <summary>
        /// Initializes a new instance of the <see cref="Address" /> class.
        /// </summary>
        public Address() : base()
        {
            Init();
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="Address" /> class.
        /// </summary>
        /// <param name="entity">The entity.</param>
        public Address(ADDRESS entity) : base(entity)
        {
            Init();
            MapEntityToObservable(entity, this);
        }

        /// <summary>
        /// Initialize complex types.
        /// </summary>
        private void Init()
        {

            Organizations = new ObservableCollection<Organization>();

            Users = new ObservableCollection<User>();

        }
    }
}