示例#1
0
 public ThaiAddress(ThaiAddress iValue)
 {
     Changwat   = iValue.Changwat;
     Amphoe     = iValue.Amphoe;
     Tambon     = iValue.Tambon;
     Muban      = iValue.Muban;
     PostalCode = iValue.PostalCode;
     Street     = iValue.Street;
     PlainValue = iValue.PlainValue;
 }
示例#2
0
 public ThaiAddress(ThaiAddress iValue)
 {
     Changwat = iValue.Changwat;
     Amphoe = iValue.Amphoe;
     Tambon = iValue.Tambon;
     Muban = iValue.Muban;
     PostalCode = iValue.PostalCode;
     Street = iValue.Street;
     PlainValue = iValue.PlainValue;
 }
示例#3
0
        internal static ThaiAddress Load(XmlNode iNode)
        {
            ThaiAddress RetVal = null;

            if (iNode != null && iNode.Name.Equals("address"))
            {
                RetVal = new ThaiAddress();
                RetVal.ReadFromXml(iNode);
            }
            return(RetVal);
        }
示例#4
0
        internal static EntityOffice Load(XmlNode iNode)
        {
            EntityOffice RetVal = null;

            if (iNode != null && iNode.Name.Equals("office"))
            {
                RetVal = new EntityOffice();

                string s = TambonHelper.GetAttributeOptionalString(iNode, "type");
                if (!String.IsNullOrEmpty(s))
                {
                    RetVal.Type = (OfficeType)Enum.Parse(typeof(OfficeType), s);
                }
                if (iNode.HasChildNodes)
                {
                    foreach (XmlNode lChildNode in iNode.ChildNodes)
                    {
                        if (lChildNode.Name == "officials")
                        {
                            EntityLeaderList lOfficials = EntityLeaderList.Load(lChildNode);
                            RetVal.OfficialsList = lOfficials;
                        }
                        if (lChildNode.Name == "url")
                        {
                            RetVal.Websites.Add(new Uri(lChildNode.InnerText));
                        }
                        if (lChildNode.Name == "address")
                        {
                            RetVal.Address = ThaiAddress.Load(lChildNode);
                        }
                        if (lChildNode.Name == "geo:Point")
                        {
                            RetVal.Location = GeoPoint.Load(lChildNode);
                        }
                    }
                }
            }
            return(RetVal);
        }
示例#5
0
 /// <summary>
 /// Creates a new instance of Office.
 /// </summary>
 public Office() {
     this.areaField = new Area();
     this.areacoverageField = new List<LocalGovernmentCoverageEntity>();
     this.historyField = new HistoryList();
     this.oldlocationsField = new List<OldLocation>();
     this.councilField = new CouncilList();
     this.officialsField = new OfficialList();
     this.socialwebField = new SocialWebLinkEntry();
     this.urlField = new List<MyUri>();
     this.addressField = new ThaiAddress();
     this.dolaField = new LocalAdministrationData();
     this.symbolsField = new Symbols();
 }
示例#6
0
 /// <summary>
 /// Creates a new instance of OldLocation.
 /// </summary>
 public OldLocation() {
     this.addressField = new ThaiAddress();
 }
示例#7
0
        internal static ThaiAddress Load(XmlNode iNode)
        {
            ThaiAddress RetVal = null;

            if (iNode != null && iNode.Name.Equals("address"))
            {
                RetVal = new ThaiAddress();
                RetVal.ReadFromXml(iNode);
            }
            return RetVal;
        }