Ejemplo n.º 1
0
        public Thrift.Protocol.TBase Convert(Character.AbstractBusinessObject o)
        {
            if (null == o)
            {
                return(null);
            }
            CharMissionData data = o as CharMissionData;
            CharMissionInfo info = new CharMissionInfo();

            info.CharId = data.CharId;
            info.CharMissionInfoList = new List <MissionInfo>();
            for (int i = 0; i < data.MissionList.Count; ++i)
            {
                info.CharMissionInfoList.Add(DeepCopy(data.MissionList[i]));
            }
            return(info);
        }
Ejemplo n.º 2
0
        public Character.AbstractBusinessObject Convert(Thrift.Protocol.TBase o)
        {
            if (null == o)
            {
                return(null);
            }
            CharMissionInfo info        = o as CharMissionInfo;
            CharMissionData data        = new CharMissionData(info.CharId);
            var             missionList = new List <MissionInfo>();

            if (info.CharMissionInfoList != null)
            {
                for (int i = 0; i < info.CharMissionInfoList.Count; ++i)
                {
                    missionList.Add(DeepCopy(info.CharMissionInfoList[i]));
                }
            }
            data.MissionList = missionList;
            data.Init        = false;
            return(data);
        }