...
This commit is contained in:
@@ -1,14 +1,63 @@
|
||||
using System.Drawing;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.Generic;
|
||||
namespace AGVControl.Models
|
||||
{
|
||||
public class MapText
|
||||
{
|
||||
public Point Location { get; set; }
|
||||
public string Text { get; set; }
|
||||
private bool _dirty = true;
|
||||
private Point _location;
|
||||
private string _text;
|
||||
private Font _font;
|
||||
|
||||
public bool Dirty
|
||||
{
|
||||
get => _dirty;
|
||||
set => _dirty = value;
|
||||
}
|
||||
|
||||
public Point Location
|
||||
{
|
||||
get => _location;
|
||||
set
|
||||
{
|
||||
if (_location != value)
|
||||
{
|
||||
_location = value;
|
||||
_dirty = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public string Text
|
||||
{
|
||||
get => _text;
|
||||
set
|
||||
{
|
||||
if (_text != value)
|
||||
{
|
||||
_text = value;
|
||||
_dirty = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public Color TextColor { get; set; }
|
||||
public Color BackgroundColor { get; set; }
|
||||
public Font Font { get; set; }
|
||||
|
||||
public Font Font
|
||||
{
|
||||
get => _font;
|
||||
set
|
||||
{
|
||||
if (_font != value)
|
||||
{
|
||||
_font = value;
|
||||
_dirty = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public RectangleF Bounds { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -7,14 +7,24 @@ namespace AGVControl.Models
|
||||
public class RFIDLine
|
||||
{
|
||||
public Point StartPoint { get; set; }
|
||||
public Point EndPoint { get; set; }
|
||||
public uint StartRFID { get; set; }
|
||||
public uint EndRFID { get; set; }
|
||||
public bool IsBidirectional { get; set; } = true; // 양방향 이동 가능 여부
|
||||
public float Distance { get; set; } // 두 RFID 포인트 사이의 거리
|
||||
public Point EndPoint { get; set; }
|
||||
|
||||
public float Distance
|
||||
{
|
||||
get {
|
||||
float dx = StartPoint.X - EndPoint.X;
|
||||
float dy = StartPoint.Y - EndPoint.Y;
|
||||
return (float)Math.Sqrt(dx * dx + dy * dy); // double을 float로 명시적 캐스팅
|
||||
}
|
||||
}
|
||||
|
||||
public List<uint> ConnectedRFIDs { get; set; } = new List<uint>(); // 연결된 모든 RFID 값들
|
||||
public Dictionary<uint, uint> NextRFID { get; set; } = new Dictionary<uint, uint>(); // 각 RFID의 다음 RFID
|
||||
public Dictionary<uint, uint> PrevRFID { get; set; } = new Dictionary<uint, uint>(); // 각 RFID의 이전 RFID
|
||||
//public uint StartRFID { get; set; }
|
||||
//public uint EndRFID { get; set; }
|
||||
//public bool IsBidirectional { get; set; } = true; // 양방향 이동 가능 여부
|
||||
//public float Distance { get; set; } // 두 RFID 포인트 사이의 거리
|
||||
|
||||
//public List<uint> ConnectedRFIDs { get; set; } = new List<uint>(); // 연결된 모든 RFID 값들
|
||||
//public Dictionary<uint, uint> NextRFID { get; set; } = new Dictionary<uint, uint>(); // 각 RFID의 다음 RFID
|
||||
//public Dictionary<uint, uint> PrevRFID { get; set; } = new Dictionary<uint, uint>(); // 각 RFID의 이전 RFID
|
||||
}
|
||||
}
|
||||
@@ -9,5 +9,6 @@ namespace AGVControl.Models
|
||||
public uint RFIDValue { get; set; }
|
||||
public string NextRFID { get; set; } // 다음 RFID 포인트의 값
|
||||
public bool IsBidirectional { get; set; } // 양방향 연결 여부
|
||||
public RectangleF Bounds { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user