コード例 #1
0
ファイル: VesselService.cs プロジェクト: ChiBaoNguyen/Test3
        public void CreateVessel(VesselViewModel vessel)
        {
            var vesselInsert = Mapper.Map <VesselViewModel, Vessel_M>(vessel);

            _vesselRepository.Add(vesselInsert);
            SaveVessel();
        }
コード例 #2
0
        private void OnAdd(AddObjectMessage message)
        {
            var path             = new Path(4, new CircularMotion(0, 50, new Angle(0), new Angle(Math.PI / 10), BaseConstants.EscortSpeed, Vector.Zero));
            var selectableObject = new SelectableObject(m_Id.Id, message.Name, path);

            m_Objects.Add(selectableObject);

            m_VesselRepository.Add(new Vessel(selectableObject));
        }
コード例 #3
0
        public void Add(Vessel vessel)
        {
            vesselRespository.Add(vessel);

            loggerService.Log($"Vessel added {vessel.VesselId}");
        }
コード例 #4
0
 public void Add(Vessel vessel)
 {
     _repository.Add(vessel);
     _logger.Log($"Vessel added {vessel.VesselId}");
 }