checkpoint
This commit is contained in:
@@ -1,27 +1,11 @@
|
||||
using Gameboard.ShogiUI.Sockets.ServiceModels.Types;
|
||||
using Shogi.Domain;
|
||||
|
||||
namespace Gameboard.ShogiUI.Sockets.Repositories.CouchModels
|
||||
{
|
||||
public class Piece
|
||||
{
|
||||
public bool IsPromoted { get; set; }
|
||||
public WhichPerspective Owner { get; set; }
|
||||
public WhichPiece WhichPiece { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Default constructor and setters are for deserialization.
|
||||
/// </summary>
|
||||
public Piece()
|
||||
{
|
||||
}
|
||||
|
||||
public Piece(Models.Piece piece)
|
||||
{
|
||||
IsPromoted = piece.IsPromoted;
|
||||
Owner = piece.Owner;
|
||||
WhichPiece = piece.WhichPiece;
|
||||
}
|
||||
|
||||
public Models.Piece ToDomainModel() => new(WhichPiece, Owner, IsPromoted);
|
||||
}
|
||||
public class Piece
|
||||
{
|
||||
public bool IsPromoted { get; set; }
|
||||
public WhichPlayer Owner { get; set; }
|
||||
public WhichPiece WhichPiece { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user