implement

This commit is contained in:
2026-02-17 00:48:28 +01:00
parent 0119c7a737
commit 5c7909034f
57 changed files with 1676 additions and 114 deletions

View File

@@ -5,8 +5,8 @@ namespace AipsCore.Domain.Models.Shape.ValueObjects;
public record Position : AbstractValueObject
{
public int X { get; }
public int Y { get; }
public int X { get; set; }
public int Y { get; set; }
public Position(int x, int y)
{
@@ -20,4 +20,14 @@ public record Position : AbstractValueObject
];
}
public static Position operator -(Position position, Position otherPosition)
{
return new Position(position.X - otherPosition.X, position.Y - otherPosition.Y);
}
public static Position operator +(Position position, Position otherPosition)
{
return new Position(position.X + otherPosition.X, position.Y + otherPosition.Y);
}
};