using Prism.Mvvm; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace TeamAAS_VP.Models { public class ToolInfo : BindableBase { public Guid Id { get; set; } private int _Number; public int Number { get { return _Number; } set { SetProperty(ref _Number, value); } } private string _Name; public string Name { get { return _Name; } set { SetProperty(ref _Name, value); } } private double _OffsetX; public double OffsetX { get { return _OffsetX; } set { SetProperty(ref _OffsetX, value); } } private double _OffsetY; public double OffsetY { get { return _OffsetY; } set { SetProperty(ref _OffsetY, value); } } private double _OffsetU; public double OffsetU { get { return _OffsetU; } set { SetProperty(ref _OffsetU, value); } } private double _OffsetZ; public double OffsetZ { get { return _OffsetZ; } set { SetProperty(ref _OffsetZ, value); } } private RobotTool _Tool; public RobotTool Tool { get { return _Tool; } set { SetProperty(ref _Tool, value); } } private RPoint _Pick; public RPoint Pick { get { return _Pick; } set { SetProperty(ref _Pick, value); } } private RPoint _Place; public RPoint Place { get { return _Place; } set { SetProperty(ref _Place, value); } } private PickInfo _PickInfo; public PickInfo PickInfo { get { return _PickInfo; } set { SetProperty(ref _PickInfo, value); } } private bool _IsForward; /// /// 相机与机器人旋转方式相同 /// public bool IsForward { get { return _IsForward; } set { SetProperty(ref _IsForward, value); } } private string _Description; public string Description { get { return _Description; } set { SetProperty(ref _Description, value); } } public ToolInfo Copy() { ToolInfo newTool = new ToolInfo(); newTool.Id = this.Id; newTool.Description = this.Description; newTool.OffsetX = this.OffsetX; newTool.OffsetY = this.OffsetY; newTool.OffsetU = this.OffsetU; newTool.OffsetZ = this.OffsetZ; newTool.Tool = this.Tool?.Copy(); newTool.Pick = this.Pick.Clone(); newTool.Place = this.Place.Clone(); newTool.PickInfo = this.PickInfo.Clone(); newTool.IsForward = this.IsForward; return newTool; } } }