Add project files.
This commit is contained in:
77
Gready_Poang.EntityLayer/EntityClasses/GameRound.cs
Normal file
77
Gready_Poang.EntityLayer/EntityClasses/GameRound.cs
Normal file
@ -0,0 +1,77 @@
|
||||
using Common.Library;
|
||||
using SQLite;
|
||||
|
||||
namespace GreadyPoang.EntityLayer;
|
||||
|
||||
|
||||
[Table("GameRound")]
|
||||
|
||||
public class GameRound : EntityBase
|
||||
{
|
||||
public GameRound()
|
||||
{
|
||||
_gameRoundId = 0;
|
||||
_gameRoundStartDate = DateTime.Now;
|
||||
_gameStatus = GamePointStatus.New;
|
||||
_gameRoundFinished = null;
|
||||
}
|
||||
|
||||
private int _gameRoundId;
|
||||
private DateTime _gameRoundStartDate;
|
||||
private GamePointStatus _gameStatus;
|
||||
private DateTime? _gameRoundFinished;
|
||||
|
||||
[Column("GameRoundFinished")]
|
||||
public DateTime? GameRoundFinished
|
||||
{
|
||||
get { return _gameRoundFinished; }
|
||||
set
|
||||
{
|
||||
_gameRoundFinished = value;
|
||||
RaisePropertyChanged(nameof(GameRoundFinished));
|
||||
}
|
||||
}
|
||||
|
||||
[Column("GameRoundStartDate")]
|
||||
public DateTime GameRoundStartDate
|
||||
{
|
||||
get { return _gameRoundStartDate; }
|
||||
set
|
||||
{
|
||||
_gameRoundStartDate = value;
|
||||
RaisePropertyChanged(nameof(GameRoundStartDate));
|
||||
}
|
||||
}
|
||||
|
||||
[Column("GameStatus")]
|
||||
public GamePointStatus GameStatus
|
||||
{
|
||||
get { return _gameStatus; }
|
||||
set
|
||||
{
|
||||
_gameStatus = value;
|
||||
RaisePropertyChanged(nameof(GameStatus));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
[PrimaryKey]
|
||||
[AutoIncrement]
|
||||
[Column("GameRoundId")]
|
||||
public int GameRoundId
|
||||
{
|
||||
get { return _gameRoundId; }
|
||||
set
|
||||
{
|
||||
_gameRoundId = value;
|
||||
RaisePropertyChanged(nameof(GameRoundId));
|
||||
}
|
||||
}
|
||||
|
||||
public string GameRoundStartDateString
|
||||
{
|
||||
get { return _gameRoundStartDate.ToString("yyyy-MM-dd"); }
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user