Пример #1
0
        //Getters & setters

        /// <summary>
        /// Get the pos. null if undefined
        /// </summary>
        /// <returns></returns>
        public HGeo GetPos()
        {
            HGeo pos = null;

            try
            {
                pos = new HGeo(JObject.Parse(this["pos"].ToString()));
            }
            catch (Exception e)
            {
                Debug.WriteLine("{0} : Can not fetch the pos attribute", e.ToString());
            }
            return(pos);
        }
Пример #2
0
        /// <summary>
        /// Set the pos.
        /// </summary>
        /// <param name="pos"></param>

        public void SetPos(HGeo pos)
        {
            try
            {
                if (pos == null)
                {
                    Debug.WriteLine("{0} : The pos attribute can not be null!");
                }
                else
                {
                    this["pos"] = pos;
                }
            }
            catch (Exception e)
            {
                Debug.WriteLine("{0} : Can not update the pos attribute: {0}", e.ToString());
            }
        }