This commit is contained in:
Veljko Tosic
2026-02-12 09:51:09 +01:00
parent b0f5f38412
commit aa012d2b0c
11 changed files with 245 additions and 0 deletions

View File

@@ -38,4 +38,22 @@ public class Arrow : Shape
new Position(endPositionX, endPositionY),
new Thickness(borderThickness));
}
public static Arrow Create(
string whiteboardId,
string authorId,
int positionX, int positionY,
string color,
int endPositionX, int endPositionY,
int borderThickness)
{
return new Arrow(
ShapeId.Any(),
new WhiteboardId(whiteboardId),
new UserId(authorId),
new Position(positionX, positionY),
new Color(color),
new Position(endPositionX, endPositionY),
new Thickness(borderThickness));
}
}

View File

@@ -38,4 +38,22 @@ public class Line : Shape
new Position(endPositionX, endPositionY),
new Thickness(borderThickness));
}
public static Line Create(
string whiteboardId,
string authorId,
int positionX, int positionY,
string color,
int endPositionX, int endPositionY,
int borderThickness)
{
return new Line(
ShapeId.Any(),
new WhiteboardId(whiteboardId),
new UserId(authorId),
new Position(positionX, positionY),
new Color(color),
new Position(endPositionX, endPositionY),
new Thickness(borderThickness));
}
}

View File

@@ -39,4 +39,21 @@ public class TextShape : Shape
new TextShapeValue(textValue),
new TextShapeSize(textSize));
}
public static TextShape Create(
string whiteboardId,
string authorId,
int positionX, int positionY,
string color,
string textValue, int textSize)
{
return new TextShape(
ShapeId.Any(),
new WhiteboardId(whiteboardId),
new UserId(authorId),
new Position(positionX, positionY),
new Color(color),
new TextShapeValue(textValue),
new TextShapeSize(textSize));
}
}